Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add nvm rm as an alias for nvm uninstall #3236

Open
bbrk24 opened this issue Nov 23, 2023 · 4 comments
Open

Add nvm rm as an alias for nvm uninstall #3236

bbrk24 opened this issue Nov 23, 2023 · 4 comments
Labels
feature requests I want a new feature in nvm!

Comments

@bbrk24
Copy link
Contributor

bbrk24 commented Nov 23, 2023

Here's an excerpt from my bash history:

nvm i v20.10
nvm rm v20.9.0
nvm uninstall v20.9.0

npm rm is a synonym for npm uninstall, so naturally I try the same thing for nvm. Every single time, it barfs out a help string and I have to re-run the command with the full name. It would be more convenient if that alias existed.

@ljharb
Copy link
Member

ljharb commented Nov 23, 2023

It'd be easy to add, but I'm not sure a destructive action is something that should be more convenient.

@ljharb ljharb added the feature requests I want a new feature in nvm! label Nov 23, 2023
@bbrk24
Copy link
Contributor Author

bbrk24 commented Nov 23, 2023

Updating a minor version within the same major version is a common action for me (I like to keep up to date with my node installs), so maybe this is a bit of an XY problem. Perhaps instead there should be a command for "replace 20.9 with 20.10".

@ljharb
Copy link
Member

ljharb commented Nov 23, 2023

Yeah, that's a bit more motivated an ask - I do that too (for patch versions; i keep every node minor on my machine forever). Currently i run nvm install X --reinstall-packages-from=X and then i manually nvm uninstall $previousX. Perhaps something like nvm migrate X Y, or something else?

@bbrk24
Copy link
Contributor Author

bbrk24 commented Nov 23, 2023

Yeah, nvm migrate could work. I'd also expect that to update aliases as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature requests I want a new feature in nvm!
Projects
None yet
Development

No branches or pull requests

2 participants