REDROOM
PHP 8.2.30
Path:
Logout
Edit File
Size: 1.86 KB
Close
/opt/alt/alt-nodejs19/root/lib/node_modules/npm/node_modules/rimraf/bin.js
Text
Base64
#!/opt/alt/alt-nodejs19/root/usr/bin/node const rimraf = require('./') const path = require('path') const isRoot = arg => /^(\/|[a-zA-Z]:\\)$/.test(path.resolve(arg)) const filterOutRoot = arg => { const ok = preserveRoot === false || !isRoot(arg) if (!ok) { console.error(`refusing to remove ${arg}`) console.error('Set --no-preserve-root to allow this') } return ok } let help = false let dashdash = false let noglob = false let preserveRoot = true const args = process.argv.slice(2).filter(arg => { if (dashdash) return !!arg else if (arg === '--') dashdash = true else if (arg === '--no-glob' || arg === '-G') noglob = true else if (arg === '--glob' || arg === '-g') noglob = false else if (arg.match(/^(-+|\/)(h(elp)?|\?)$/)) help = true else if (arg === '--preserve-root') preserveRoot = true else if (arg === '--no-preserve-root') preserveRoot = false else return !!arg }).filter(arg => !preserveRoot || filterOutRoot(arg)) const go = n => { if (n >= args.length) return const options = noglob ? { glob: false } : {} rimraf(args[n], options, er => { if (er) throw er go(n+1) }) } if (help || args.length === 0) { // If they didn't ask for help, then this is not a "success" const log = help ? console.log : console.error log('Usage: rimraf <path> [<path> ...]') log('') log(' Deletes all files and folders at "path" recursively.') log('') log('Options:') log('') log(' -h, --help Display this usage info') log(' -G, --no-glob Do not expand glob patterns in arguments') log(' -g, --glob Expand glob patterns in arguments (default)') log(' --preserve-root Do not remove \'/\' (default)') log(' --no-preserve-root Do not treat \'/\' specially') log(' -- Stop parsing flags') process.exit(help ? 0 : 1) } else go(0)
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 1 × Files: 5
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
node_modules
DIR
-
drwxr-xr-x
2024-03-03 22:54:11
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
bin.js
1.86 KB
lrwxr-xr-x
2023-12-06 18:07:51
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
LICENSE
765 B
lrw-r--r--
2023-12-06 18:07:51
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
package.json
729 B
lrw-r--r--
2023-12-06 18:07:51
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
README.md
3.52 KB
lrw-r--r--
2023-12-06 18:07:51
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
rimraf.js
8.66 KB
lrw-r--r--
2023-12-06 18:07:51
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).