
Security News
Crates.io Users Targeted by Phishing Emails
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
Remove the empty branches of a directory tree, optionally up to (but not including) a specified base directory. Optionally nukes the leaf directory.
var logger = require("npmlog");
var vacuum = require("fs-vacuum");
var options = {
base : "/path/to/my/tree/root",
purge : true,
log : logger.silly.bind(logger, "myCleanup")
};
/* Assuming there are no other files or directories in "out", "to", or "my",
* the final path will just be "/path/to/my/tree/root".
*/
vacuum("/path/to/my/tree/root/out/to/my/files", options, function (error) {
if (error) console.error("Unable to cleanly vacuum:", error.message);
});
directory
{String} Leaf node to remove. Must be a directory, symlink, or file.options
{Object}
base
{String} No directories at or above this level of the filesystem will be removed.purge
{Boolean} If set, nuke the whole leaf directory, including its contents.log
{Function} A logging function that takes npmlog
-compatible argument lists.callback
{Function} Function to call once vacuuming is complete.
error
{Error} What went wrong along the way, if anything.FAQs
recursively remove empty directories -- to a point
The npm package fs-vacuum receives a total of 156,846 weekly downloads. As such, fs-vacuum popularity was classified as popular.
We found that fs-vacuum demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
Product
Socket now lets you customize pull request alert headers, helping security teams share clear guidance right in PRs to speed reviews and reduce back-and-forth.
Product
Socket's Rust support is moving to Beta: all users can scan Cargo projects and generate SBOMs, including Cargo.toml-only crates, with Rust-aware supply chain checks.