Skip to content

Instantly share code, notes, and snippets.

@brndnsmth
Created September 10, 2023 19:26
Show Gist options
  • Save brndnsmth/0bb7bd415adbe4dbb70bdbdbed30ccc6 to your computer and use it in GitHub Desktop.
Save brndnsmth/0bb7bd415adbe4dbb70bdbdbed30ccc6 to your computer and use it in GitHub Desktop.
Useful NVM commands / cheatsheet
// check version
node -v || node --version
// list locally installed versions of node
nvm ls
// list available versions of node
nvm ls-remote
// list latest versions of node
nvm ls-remote | grep -i "latest"
// install specific version of node
nvm install 18.16.1
// set default version of node
nvm alias default 18.16.1
// switch version of node
nvm use 20.5.1
// switch to latest LTS version
nvm use --lts
// install latest LTS version of node (Long Term Support)
nvm install --lts
// install latest stable version of node
nvm install stable
// install latest NPM release only
nvm install-latest-npm
// uninstall a specific version
nvm uninstall 18.16.1
// uninstall the latest LTS release
nvm uninstall --lts
// verify versions
node -v
npm -v
nvm -v
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment