On Mac, I started by homebrew to install NVM, as follows:
Install NVM
After the installation is complete, enter the NVM list at the command line and notice that the following prompt appears:
what?!! I did not install the NVM.
Try a lot of scenarios, only one seems to be OK, after you open terminal, run the following code:
Export nvm_dir=~/--prefix NVM)/nvm. SH
You can run the NVM command on this open terminal page.
But, such a good trouble, we just have to open a new terminal will have to run as above code.
How to solve it? The reason for tracing the problem is that the brew installs the NVM itself bug, in the. nvm file, the following red box files are missing:
No words.
Since the brew itself is a problem, we have to go another way and install the NVM in one of the following ways:
curl-o-https://raw.githubusercontent.com/creationix/nvm/v0.33.2/install.sh | bash
Of course, an appeal order is executed, provided that the previously installed NVM is uninstalled using the Brew Uninstall NVM command.
Restarting or opening a new terminal execution NVM is OK.
Of course, the CD ~/.NVM to see all the files inside, nvm.sh will have.
If you are running NVM locally or command not found, check to see if the. bash_profile file is included, as follows:
ls grep . bash_profile
--Of course I do now.
If this file exists, it still prompts NVM command not found, then you can execute the The first command below opens the hidden file to view the contents of the. Bash_profile:
-If the file does not exist, see a new. bash_profile file
Write Killall // Show hidden files Write Killall // do not show hidden files
Normal. Bash_profile content is as follows:
SOURCE ~/. bashrcexport nvm_dir="$HOME/.nvm""$NVM _dir/ nvm.sh""$NVM _dir/nvm.sh ""$NVM _dir/ Bash_completion""$NVM _dir/bash_completion" # this loads NVM bash_completion
If not, copy and paste the content into your. bash_profile file to be OK.
[1]. NVM--node version Manager
episode, MD sister just bought Iphone7 was stolen, the mood is really bad, draw a circle curse their family!!!
Install NVM on Mac machine The Pit--NVM command not found