
Security News
NVD Quietly Sweeps 100K+ CVEs Into a “Deferred” Black Hole
NVD now marks all pre-2018 CVEs as "Deferred," signaling it will no longer enrich older vulnerabilities, further eroding trust in its data.
Sync and async versions of rm -r
, handling both files and directories (something astonishingly missing from fs
).
var remove = require('remove');
// Asynchronous
remove('/home/esr', function(err){
if (err) console.error(err);
else console.log('success!');
});
// Synchronous
try {
remove.removeSync('/home/esr');
console.log('success!');
} catch (err) {
console.error(err);
}
Via npm:
npm install remove
Or if you want to hack on the source:
git clone https://github.com/dsc/node-remove.git
cd node-remove
npm link
Asynchronously and recursively remove files and/or directories.
false
Boolean — Log all errors and print each path just before it's removed.false
Boolean — If true, remove the supplied paths sequentially, such that an unsuppressed error would short-circuit further deletes.false
Boolean — If false, halt as soon as possible after an error occurs and invoke the callback. When operating in sequential
mode, this implies an error removing the first of several paths would halt before touching the rest. If set, ignoreErrors
overrides ignoreMissing
.false
Boolean — Whether to treat missing paths as errors.Synchronously and recursively remove files and/or directories.
false
Boolean — Log all errors and print each path just before it's removed.false
Boolean — If false, halt as soon as possible after an error occurs and invoke the callback. This implies an error removing the first of several paths would halt before touching the rest. If set, ignoreErrors
overrides ignoreMissing
.false
Boolean — Whether to treat missing paths as errors.Find a bug or want to contribute? Open a ticket on github. You're also welcome to send me email at dsc@less.ly.
FAQs
Sync and async rm -r.
The npm package remove receives a total of 60,353 weekly downloads. As such, remove popularity was classified as popular.
We found that remove demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
NVD now marks all pre-2018 CVEs as "Deferred," signaling it will no longer enrich older vulnerabilities, further eroding trust in its data.
Research
Security News
Lazarus-linked threat actors expand their npm malware campaign with new RAT loaders, hex obfuscation, and over 5,600 downloads across 11 packages.
Security News
Safari 18.4 adds support for Iterator Helpers and two other TC39 JavaScript features, bringing full cross-browser coverage to key parts of the ECMAScript spec.