Reputation: 9636
I am trying to install node.js on mac running macOS Sierra using nvm but after installing nvm when I try to run
nvm install node
it says Version 'node' not found - try nvm ls-remote to browse available versions.
when I run nvm ls-remote
I only get list of io.js and not node.
does nvm now support the node installation or just only io.js? Please help me figure it out or should I just go with the standard package installer.
Upvotes: 1
Views: 2029
Reputation: 2753
I am suspecting you don't have the nvm script in your startup files. Hope this helps. First make sure you have a base Node.js version installed.
brew install node
This will get you the latest stable Node.js version. You can now proceed to installing NVM
using either curl or wget
. Also remember to add the scripts to your ~/.zshrc
file assuming you're using zsh
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm
To install Node.js version after successfully setting up NVM
nvm install v6.9.1
If all fails you can also use N: Node Version Manager
Upvotes: 1