npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

@huangjunsen/vault-cli

v0.2.0

Published

macOS vault CLI: hide/unhide directories with .noindex and manage encrypted sparsebundles

Readme

Vault CLI (macOS)

Goal: Make selected directories fully disappear from common macOS searchers (Spotlight/mdfind/uTools/VSCode/find/grep) and not show in Finder when hidden, with a simple Node.js CLI.

Two modes:

  • rename_noindex: Rename folder to ..noindex to disable Spotlight indexing and hide from Finder.
  • sparsebundle: Attach/detach an encrypted .sparsebundle image via hdiutil, optionally with -nobrowse and Spotlight disabled while mounted.

Install / Run

  • Local dev: node bin/vault.js --help
  • Global (recommended for users): npm install -g vault-cli, then use vault-cli

Publish & Global Install

  • Publish (scoped, public): npm publish
  • Install globally: npm install -g @huangjunsen/vault-cli
  • Use: vault-cli (alias: vault)

Config Option A (no-config, pass paths directly):

  • Hide by path: vault-cli off /abs/path/A /abs/path/B --dry-run
  • Restore by path: vault-cli on /abs/path/A /abs/path/B

Option B (config file): use an array of folder paths (rename_noindex by default). Create ~/.vaultconfig.json

[ "/Users/you/Projects/Company", "/Users/you/Private" ]

Add paths to existing config

  • Append paths: vault-cli add /abs/path/C /abs/path/D
  • Works with array config or object config (appends targets[] with rename_noindex).

Edit config

  • Open default config (auto-create if missing): vault-cli config --edit
  • Open custom path (auto-create if missing): vault-cli config --edit --config /custom/path.json

Commands

  • vault-cli add <absPath...>
  • vault-cli config --edit
  • vault-cli on <target...|--all|--group > [--dry-run]: Show folder(s) or attach sparsebundle(s)
  • vault-cli off <target...|--all|--group > [--dry-run]: Hide folder(s) or detach sparsebundle(s)
  • vault-cli status [<target...>|--all|--group ]: Show state
  • vault-cli targets: List configured target names
  • vault-cli sweep [--full-index]: Clear QuickLook cache and Recent Documents; with --full-index also rebuild Spotlight (expensive)

Why this works

  • Finder visibility: A leading dot (.) hides items in Finder; detached volumes do not appear anywhere.
  • Spotlight indexing: Folders ending with .noindex are excluded; unmounted images are not indexed at all. When mounted, you can also disable Spotlight for the mountpoint.
  • Grep/find/mdfind/uTools/VSCode: With the folder renamed to .*.noindex it won’t be in the index, and most tools skip dotfolders by default; detached sparsebundles expose no plaintext files.

Operational notes

  • rename_noindex is fast and reversible (atomic rename within same parent folder).
  • sparsebundle offers encryption and complete off-state invisibility; attach uses your interactive password prompt (stdin), nothing is stored.
  • sweep: By default clears QuickLook caches and Recent Documents. --full-index triggers mdutil -E / which is system-wide and slow.

Examples

  • Hide: vault off company
  • Show: vault on company
  • Mount: vault on vault
  • Detach: vault off vault
  • Status: vault status

Safety

  • This CLI targets macOS only. It runs hdiutil, mdutil, qlmanage under your user.
  • Avoid using --full-index unless you truly need to guarantee Spotlight has purged past traces.