simpler version of shelljs
npm install nautsimpler 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-p
- mkdir
- Always behaves like is set-R
- cp
- You can pass or -r or -a to as the first argument to copy a directory instead of a file.to
- mv
- touch
- cat
- exec
- $ (command substitution simulator)
- echo
- You can use and .toEnd` like in shelljs