【问题标题】:NodeJS NPM issueNodeJS NPM 问题
【发布时间】:2016-07-30 15:11:41
【问题描述】:

我无法从 npm 安装任何包。

npm ERR! Windows_NT 6.3.9600
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "-g" "ionic"
npm ERR! node v6.3.1
npm ERR! npm  v3.10.3
npm ERR! code ECONNRESET

npm ERR! network tunneling socket could not be established, cause=connect ECONNREFUSED 127.0.0.1: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 settings.
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!     E:\myApps\mobileApp\shym\npm-debug.log

npm config 获取代理 -> null

npm config 获取 https-proxy -> null

npm config get registery -> registry = "https://registry.npmjs.org/"

【问题讨论】:

标签: javascript node.js npm npm-install


【解决方案1】:

您必须在代理之后才能安装依赖项,您必须配置 npm 以连接到您的代理

npm config set proxy http://proxy.example.com:3000
npm config set https-proxy https://proxy.example.com:3000`

在您的终端中。

【讨论】:

    猜你喜欢
    • 2013-04-27
    • 1970-01-01
    • 2015-01-04
    • 1970-01-01
    • 2017-04-13
    • 2019-08-11
    • 2022-01-25
    • 1970-01-01
    • 2016-03-06
    相关资源
    最近更新 更多