Hi Andrej,
a very helpful tool! Good idea.
A typo: the localfilename option character "-O" needs to be uppercase.
"-o" specifies the logfile:
system(wget, " ", cvsfilename, " -O ", localfilename, " -o ",
logfilename),
where logfilename can be "null".
Regards
Volker
Am Montag, den 02.11.2009, 12:03 +0100 schrieb Andrej Vodopivec:
> Here is a simple function to get files from the maxima cvs. We assume
> that wget is installed somewhere and use viewvc gateway to sourceforge
> cvs.
>
> /* http link */
> viewvc: "http://maxima.cvs.sourceforge.net/viewvc/*checkout*/maxima/maxima/"$
>
> /* where to put the file */
> cvsfiles: "/Users/andrej/Desktop/cvs/"$
>
> /* wget program */
> wget: "wget"$
>
> fetch_from_cvs(filename) := block(
> [cvsfilename: concat(viewvc, filename),
> localfilename: concat(cvsfiles, filename)],
> ?ensure\-directories\-exist(localfilename),
> system(wget, " ", cvsfilename, " -o ", localfilename),
> localfilename)$
>
> fetch_from_cvs("share/contrib/to_poly_solver.mac")$
>
> will download to_poly_solver.mac from and return the path to the
> downloaded file.
>
> If we are serious about updating files from cvs this could be a very
> simple option. fetch_from_cvs could also be used for some more
> complicated scheme if we need it. We should also include wget with the
> windows binary but this is not a problem.
>
> Andrej
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima