Created
December 25, 2022 17:44
-
-
Save MatiasPujado/34cc31d040e53c39ed4e169e4abb51f4 to your computer and use it in GitHub Desktop.
NVM list of commands
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Install a specific version number | |
nvm install 8.0.0 | |
// Install the latest LTS version | |
nvm install --lts | |
// Use the latest available 8.0.x release | |
nvm use 8.0 | |
// Use the latest LTS version | |
nvm use --lts | |
// Run app.js using node 6.10.3 | |
nvm run 6.10.3 app.js | |
// Run node app.js with the PATH pointing to node 4.8.3 | |
nvm exec 4.8.3 node app.js | |
// Set default node version on a shell | |
nvm alias default 8.1.0 | |
// Always default to the latest available node version on a shell | |
nvm alias default node | |
// Install the latest available version | |
nvm install node | |
// Use the latest version | |
nvm use node | |
// Set text colors to cyan, green, bold yellow, magenta, and white | |
nvm set-colors cgYmW | |
// check version | |
node -v || node --version | |
// list installed versions of node (via nvm) | |
nvm ls | |
// set default version of node | |
nvm alias default 6.9.2 | |
// to list available remote versions of node (via nvm) | |
nvm ls-remote | |
nvm ls-remote | grep -i 'latest' | |
or all versions starting with v18 | |
nvm ls-remote | grep -i 'v18' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment