npm安装

npm&&NVM安装

nvm安装

NVM_DIR="/root/.nvm"
NODE_VERSION=17.9.0
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.37.2/install.sh | bash \
&& [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" \
&& [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" \
&& nvm -v \
&& nvm install ${NODE_VERSION} \
&& nvm use ${NODE_VERSION} \
&& npm -g install yarn \
&& npm config set registry https://registry.npm.taobao.org \
&& yarn config set registry https://registry.npm.taobao.org
npm config ls -l

npm config set prefix "D:\jdk\npm"

npm config set registry "https://registry.npm.taobao.org/"
posted @ 2023-04-03 10:53  edclol  阅读(51)  评论(0编辑  收藏  举报