Jos*_*eph 5 proxy http-proxy node.js bower bower-install
我有一个使用Visual Studio 2015 IDE开发的Cordova应用程序.为了管理库和依赖项,我尝试使用NuGet.但看起来,NuGet无法管理客户端脚本,即CSS.所以我探索了BOWER.我使用命令安装了bower npm installl -g bower,现在我可以访问所有Bower命令.
当我尝试添加像jQuery和jQuery Mobile这样的依赖项时,它会尝试获取并失败.它给出的错误是,
PATH=.\node_modules\.bin;C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External;%PATH%;C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\git
"C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\Web Tools\External\Bower.cmd" install --force-latest
bower retry Request to https://bower.herokuapp.com/packages/jquery-mobile failed with ECONNRESET, retrying in 1.5s
bower retry Request to https://bower.herokuapp.com/packages/jQuery failed with ECONNRESET, retrying in 1.4s
bower retry Request to https://bower.herokuapp.com/packages/jQuery failed with ECONNRESET, retrying in 3.0s
bower retry Request to https://bower.herokuapp.com/packages/jquery-mobile failed with ECONNRESET, retrying in 3.1s
bower retry Request to https://bower.herokuapp.com/packages/jQuery failed with ECONNRESET, retrying in 4.8s
bower retry Request to https://bower.herokuapp.com/packages/jquery-mobile failed with ECONNRESET, retrying in 7.0s
bower retry Request to https://bower.herokuapp.com/packages/jQuery failed with ECONNRESET, retrying in 9.7s
bower retry Request to https://bower.herokuapp.com/packages/jquery-mobile failed with ECONNRESET, retrying in 8.5s
bower retry Request to https://bower.herokuapp.com/packages/jQuery failed with ECONNRESET, retrying in 26.5s
bower retry Request to https://bower.herokuapp.com/packages/jquery-mobile failed with ECONNRESET, retrying in 25.6s
bower jQuery#* ECONNRESET Request to https://bower.herokuapp.com/packages/jQuery failed: tunneling socket could not be established, cause=connect ETIMEDOUT
====Executing command 'npm install'====
npm WARN package.json WellnessAdvisor@1.0.0 No description
npm WARN package.json WellnessAdvisor@1.0.0 No repository field.
npm WARN package.json WellnessAdvisor@1.0.0 No README data
====npm command completed with exit code 0====
Run Code Online (Sandbox Code Playgroud)
我浏览了,据说我必须设置代理,
http_proxy = http://<user>:<password>@<your company proxy>:<port>
https_proxy= http://<user>:<password>@<your company proxy>:<port>
Run Code Online (Sandbox Code Playgroud)
或创建一个名为.bowerrc的文件,并放置代码以克服代理.
{
"directory": "library",
"registry": "http://bower.herokuapp.com",
"proxy":"http://<USERNAME>:<PASSWORD>@<PROXY_IP>:<PROXY_PORT>/",
"https-proxy":"http://<USERNAME>:<PASSWORD>@<PROXY_IP>:<PROXY_PORT>/"
}
Run Code Online (Sandbox Code Playgroud)
但没有任何效果.现在我尝试使用没有代理的开放网络,我收到同样的错误.我错过了任何基本步骤吗?
我也尝试从命令提示符窗口.得到同样的错误.
您是否已尝试通过执行以下命令将 git 协议从 https 更改为 git:
git config --global url."git://".insteadOf https://
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
2498 次 |
| 最近记录: |