0%

NPM代理设置

设置代理

1
2
npm config set proxy http://<username>:<password>@<proxy-server-url>:<port>
npm config set https-proxy http://<username>:<password>@<proxy-server-url>:<port>

取消代理

任选一个方法取消代理, 如果一个方法不行, 尝试另外一个.

1
2
3
4
5
6
7
8
9
10
11
# way 1
npm config delete http-proxy
npm config delete https-proxy

# way 2
npm config rm proxy
npm config rm https-proxy

# way 3
set HTTP_PROXY=null
set HTTPS_PROXY=null