dnode
is a CLI tool to search and delete any node_module
folders.
There are three ways to install the binary
Open your terminal and type in
go install github.com/akshaybabloo/dnode@latest
git clone github.com/akshaybabloo/dnode.git
cd dnode
go install
You can download OS dependent binary from the releases page.
There are two commands available
Lists all node_module
folders in the current directory tree recursively.
Example
> dnode list
PATH | DIRECTORY SIZE
-----------------------------------------+-----------------
./gollahalli.com/node_modules | 33 MB
./keertana.gollahalli.com/node_modules | 34 MB
-----------------------------------------+-----------------
TOTAL | 67 MB
-----------------------------------------+-----------------
Deletes all node_module
folders in the current directory tree recursively.
> dnode delete
Deleted ./gollahalli.com/node_modules
Deleted ./keertana.gollahalli.com/node_modules
67 MB freed