Please enable Javascript to view the contents

使用nvm进行node版本管理

 ·  ☕ 1 分钟 · 👀... 阅读

使用nvm进行node版本管理

安装nvm

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
# 安装
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.35.2/install.sh | bash
# 默认会写.zshrc

### .zshrc nvm start 
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
### .zshrc nvm end

source .zshrc

nvm install node # "node" is an alias for the latest version
分享

ysicing
作者
ysicing
云原生爱好者


目录