pantry/projects/github.com/nvm-sh/nvm/README.md
Andrew 217aa7f764
github.com/nvm-sh/nvm (#3681)
* new file:   projects/github.com/nvm-sh/nvm/package.yml

* wip

* dir...

* sure... curl on linux
2023-10-16 15:09:43 -04:00

836 B

Configuring NVM on Linux and Darwin

For Linux

Insert the following lines into your ~/.profile file:

[ -s "$NVM_DIR/libexec/nvm.sh" ] && \. "$NVM_DIR/libexec/nvm.sh"  # Loads nvm
[ -s "$NVM_DIR/etc/bash_completion.d/nvm" ] && \. "$NVM_DIR/etc/bash_completion.d/nvm"  # Loads nvm bash_completion

Execute source ~/.profile to apply the changes or simply restart your terminal.

For Darwin (macOS)

Insert the following lines into your ~/.zshrc file:

[ -s "$NVM_DIR/libexec/nvm.sh" ] && \. "$NVM_DIR/libexec/nvm.sh"  # Loads nvm
[ -s "$NVM_DIR/etc/bash_completion.d/nvm" ] && \. "$NVM_DIR/etc/bash_completion.d/nvm"  # Loads nvm bash_completion

Execute source ~/.zshrc to apply the changes or simply restart your terminal.

Now you can use nvm in your terminal to manage Node.js versions.