Update commands for command nvm in bash

- change mode for command for install nvm in home
- insert command for bash completion
This commit is contained in:
Lucas Augusto 2019-03-24 15:55:24 -03:00 committed by GitHub
parent ff77ac17af
commit 8bf44bc687
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -61,8 +61,9 @@ wget -qO- https://raw.githubusercontent.com/creationix/nvm/v0.34.0/install.sh |
<sub>**Note:** If the environment variable `$XDG_CONFIG_HOME` is present, it will place the `nvm` files there.</sub>
```sh
export NVM_DIR="${XDG_CONFIG_HOME/:-$HOME/.}nvm"
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # this loads nvm bash_completion
```
**Note:** You can add `--no-use` to the end of the above script (...`nvm.sh --no-use`) to postpone using `nvm` until you manually [`use`](#usage) it.