【发布时间】:2019-09-10 20:23:52
【问题描述】:
我正在尝试通过 npm 安装 angular-cli。我安装了最新版本的 Nodejs 和 git。我不在任何代理服务器后面(通过netsh winhttp show proxy 以及通过 Internet Explorer LAN 设置验证它)并且我的互联网连接没有问题。当我尝试运行时
npm install -g angular-cli 然后我得到以下错误
C:\Windows\system32>npm install -g angular-cli
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\
node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "angular-cli"
npm ERR! node v7.3.0
npm ERR! npm v3.10.10
npm ERR! code ETIMEDOUT
npm ERR! errno ETIMEDOUT
npm ERR! syscall connect
npm ERR! network connect ETIMEDOUT 151.101.192.162:80
npm ERR! network This is most likely not a problem with npm itself
npm ERR! network and is related to network connectivity.
npm ERR! network In most cases you are behind a proxy or have bad network settin
gs.
npm ERR! network
npm ERR! network If you are behind a proxy, please make sure that the
npm ERR! network 'proxy' config is set properly. See: 'npm help config'
npm ERR! Please include the following file with any support request:
npm ERR! C:\Windows\system32\npm-debug.log
我尝试通过npm cache clean清理缓存,还尝试将注册表更改为http:\ via
npm config set registry http://registry.npmjs.org/
我也尝试卸载 nodejs 并重新安装它,但它不起作用。我遇到了同样的错误。任何想法。
【问题讨论】:
标签: angularjs node.js npm angular-cli npm-install