2014-03-03 114 views
0

,同時試圖做的亭子上安裝node.js的命令PROMT即時得到以下錯誤錯誤而安裝涼亭包

bower check-new  Checking for new versions of the project dependencies.. 
bower ECMDERR  Failed to execute "git ls-remote --tags --heads [email protected]:XXXXX/XXXX", exit 

Additional error details: 
ssh: connect to host github.com port 22: Bad file number 
fatal: Could not read from remote repository. 

Please make sure you have the correct access rights 
and the repository exists. 

有人能幫幫我嗎?

注意:我在公司網絡上。

回答

1

嗯,我知道它有點晚了,但是這並獲得成功對我來說。

打開.bowerrc文件並設置代理配置。

"proxy":"http://xx.xx.xx.xx:8080", 
"https-proxy":"http://xx.xx.xx.xx:8080" 

,然後做一個運行涼亭安裝命令

希望它能幫助!

+0

我有一個類似的問題,我仍然無法解決它。 當你設置代理設置時,你用某個東西替換「x」還是把它放在那裏? –

+0

這裏的x代表ip地址..例如你的代理ip地址是192.168.1.2你需要設置npm配置爲 「proxy」:「http://192.168.1.2:8080」, 「https-代理「:」http://192.168.1.2:8080「 –

+0

謝謝! 其實我通過從.gitconfig文件中刪除一些行來解決這個問題。 –

2

此問題可能是由於您的公司網絡引起的,它們可能會阻塞某些端口。 嘗試使用的https代替ssh

這是如何改變: git config --global url."https://".insteadOf git://

+0

我已經做到了。我仍然得到相同的錯誤 –