create directory in OS independent way

6 views
Skip to first unread message

Ralf Hemmecke

unread,
May 15, 2024, 5:32:07 PM5/15/24
to fricas-devel
For a given fn of type FileName I cannot simply say

fh := open(fn, "output")

if the folder directory(fn) does not yet exist.
I haven't found any other way than using

systemCommand("system mkdir -p " directory fn)$MoreSystemCommands

. Is there a more OS-independent way to create a directory?

Ralf

Waldek Hebisch

unread,
May 15, 2024, 6:02:09 PM5/15/24
to fricas...@googlegroups.com
There is a Lisp helper function 'makedir'. Use like:

makedir("foo.dir")$Lisp

ATM there is no Spad wrapper for this.

--
Waldek Hebisch
Reply all
Reply to author
Forward
0 new messages