simpler version of shelljs
const naut = require("naut");
naut.ls().forEach(file => {
naut.mv(file, file + ".bak");
});
require("naut/global");
ls().forEach(file => {
mv(file, file + ".bak");
});
- ls
- pwd
- cd
- rm
- Always behaves like
-rf
is set
- Always behaves like
- mkdir
- Always behaves like
-p
is set
- Always behaves like
- cp
- You can pass
-R
or-r
or-a
to as the first argument to copy a directory instead of a file
- You can pass
- mv
- touch
- cat
- exec
- $ (command substitution simulator)
- echo
- You can use
.to
and.toEnd
like in shelljs
- You can use