A stunning, visually satisfying CLI tool to instantly scan your hard drive, locate heavy
node_modulesfolders, and safely destroy them to reclaim gigabytes of disk space.
(A beautiful, interactive CLI built with
@clack/prompts)
As developers, we spin up dozens of experimental projects. Each npm install brings in hundreds of megabytes of node_modules. Very quickly, your hard drive fills up with gigabytes of unused dependencies from projects you haven't touched in 8 months.
blackhole makes cleaning your disk actually fun.
- ✨ Zero configuration required. Just aim it at a folder.
- 🚀 Blazing Fast. Powered by
fast-glob, it recursively scans massive directories without hanging. - 📊 Intelligent Mass Calculation. It calculates exactly how much space each folder takes up.
- 🛡️ Interactive Multi-select. You choose exactly which folders get destroyed using a clean, beautiful CLI interface (powered by
@clack/prompts). - 🔥 Satisfying Destruction. Permanently wipes gigabytes from your drive in seconds.
Simply run this command and pass the root directory you want to scan:
npx @dinakars777/blackhole ~/ProjectsFor the best experience, install it globally so you can use the short command anytime:
npm install -g @dinakars777/blackhole
# Now you can just use:
blackhole ~/Projects
blackhole .- It initiates a highly optimized recursive glob search through the target directory looking for
node_modules. - It pauses to calculate the exact size in bytes of everything inside those folders.
- It presents you with a sorted interactive checklist (largest folders first).
- You press
Spaceto toggle folders for deletion. - Press
Enterto confirm. - It displays the total space you will reclaim (e.g.,
4.2 GB) and asks for one final confirmation. - Upon typing
y, those folders are forcefully and recursively deleted from your disk.
Pull requests are welcome!
git clone https://github.com/dinakars777/blackhole.git
cd blackhole
npm install
npm run dev ~/TestDirectoryMIT