Last active
March 2, 2022 23:43
-
-
Save punit5658/88ea0b2b2b703c7f0d00cb6b1055b553 to your computer and use it in GitHub Desktop.
Node manager through NVM
This file contains hidden or 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
Remove Node | |
brew uninstall --ignore-dependencies node | |
brew uninstall --force node | |
Update brew and install NVM | |
brew update | |
brew install nvm | |
Next, create a directory for NVM. | |
mkdir ~/.nvm | |
Now add these lines to ~/.bash_profile ( or ~/.zshrc for macOS Catalina or later) | |
export NVM_DIR=~/.nvm | |
source $(brew --prefix nvm)/nvm.sh | |
Now either quit and reopen your Terminal, or run | |
source ~/.bash_profile | |
Echoing $NVM_DIR should now return your NVM directory | |
echo $NVM_DIR | |
To see what Node versions are available to install run: | |
nvm ls-remote | |
For me, I just needed the latest point release of Node version 11 so I ran | |
nvm install 11 | |
After installing you can verify what is installed with | |
nvm ls | |
If you have multiple versions and you want to specify which version you would like to use, simply use: | |
nvm use 11 | |
####### | |
####### NVM using fish | |
https://github.com/jorgebucaran/nvm.fish | |
https://github.com/jorgebucaran/fisher extension | |
####### | |
###### Install omf theme | |
https://github.com/oh-my-fish/oh-my-fish | |
omf install nvm |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment