Maxima equivalent of ls



Edwin Woollett <woollett at charter.net> writes:

> I have put your definition into directory.lisp
> and the rest of the code into ls.mac.
>
> Despite the Lisp version dependence of directory,
> this code at least gives beginning string programmers
> a starting point to test what happens with their lisp
> version.

This functionality is built into the cl-fad library,
which I have patched to work with gcl. Here is an
example from the Maxima-CAS code base:

(%i1) :lisp (defmfun $ls (directory) (append '((mlist simp)) (cl-fad:list-directory directory)))

$LS

(%i2) ls(".");
(%o2) [/home/work/maxima/sandbox/git/maxima-git/.cvsignore,
/home/work/maxima/sandbox/git/maxima-git/.git/,
...

-- 
Leo Butler                 l_butler at users.sourceforge.net
SDF Public Access UNIX System -   http://sdf.lonestar.org