Nvm: Install error: Profile not found. Tried ~/.bashrc, ~/.bash_profile, ~/.zshrc, and ~/.profile.

Created on 15 Jun 2018  路  3Comments  路  Source: nvm-sh/nvm

  • Operating system and version: OSX High Sierra 10.13.5 (17F77)

  • nvm debug output:
    nvm: command not found


  • nvm ls output:


  • How did you install nvm? (e.g. install script in readme, Homebrew):
    curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash

  • What steps did you perform?
    curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.11/install.sh | bash

  • What happened?
=> nvm is already installed in /Users/dillon/.nvm, trying to update using git
=> => Compressing and cleaning up git repository

=> Profile not found. Tried ~/.bashrc, ~/.bash_profile, ~/.zshrc, and ~/.profile.
=> Create one of them and run this script again
   OR
=> Append the following lines to the correct file yourself:

export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"  # This loads nvm

=> Close and reopen your terminal to start using nvm or run the following to use it now:

export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"  # This loads nvm
  • What did you expect to happen?
    install nvm
  • Is there anything in any of your profile files (.bashrc, .bash_profile, .zshrc, etc) that modifies the PATH?
    I just factory reset my macbook, installed xcode, accepted xcode terms, installed brew, and then tried to install nvm. echo $PATH returns /usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
  • If you are having installation issues, or getting "N/A", what does curl -I --compressed -v https://nodejs.org/dist/ print out?
    ...* Connection #0 to host nodejs.org left intact

Mac OS installing nvm profile detection

Most helpful comment

I ran touch ~/.bash_profile and things seem to be working. Is that the right thing to do?

All 3 comments

I ran touch ~/.bash_profile and things seem to be working. Is that the right thing to do?

Just read this. It fixed my problem.

Note: On OS X, if you get nvm: command not found after running the install script, one of the following might be the reason:-

your system may not have a [.bash_profile file] where the command is set up. Simply create one with touch ~/.bash_profile and run the install script again
you might need to restart your terminal instance. Try opening a new tab/window in your terminal and retry.

@dillon, I did the same 馃憞馃徑 and it worked. Thanks!

I ran touch ~/.bash_profile and things seem to be working. Is that the right thing to do?

Was this page helpful?
0 / 5 - 0 ratings