mirror of
https://github.com/janet-lang/janet
synced 2025-01-23 05:36:52 +00:00
Make rmrf stronger.
This commit is contained in:
parent
de977819ce
commit
2fafe2b5d1
@ -4030,10 +4030,11 @@
|
||||
"rm -rf in janet"
|
||||
[x]
|
||||
(case (os/stat x :mode)
|
||||
:file (os/rm x)
|
||||
nil nil
|
||||
:directory (do
|
||||
(each y (os/dir x) (rmrf (string x "/" y)))
|
||||
(os/rmdir x)))
|
||||
(os/rmdir x))
|
||||
(os/rm x))
|
||||
nil)
|
||||
|
||||
(defn- copyfile
|
||||
|
Loading…
Reference in New Issue
Block a user