nvm-sh / nvm

Node Version Manager - POSIX-compliant bash script to manage multiple active node.js versions
MIT License
79.91k stars 8k forks source link

Recommend to autoremove #1881

Open BridgeAR opened 6 years ago

BridgeAR commented 6 years ago

I suggest to add a feature similar to autoremove from apt-get.

On install of a new version it could suggest to run autoremove. When doing so it should ask what Node.js versions should be removed e.g., all but the latest of each major; all but the latest; all but versions below the current default.

Besides that it would be great to also add a option to the installer to auto remove the last minor / patch version on installing a newer version.

ljharb commented 6 years ago

This has been requested before; see https://github.com/creationix/nvm/issues/1091#issuecomment-218282456. I don’t think this is the primary use case for nvm; and it wouldn’t match my own, where i always keep every minor forever.