【问题标题】:yo jhipster : Failed to connect to "git://github.com"哟 jhipster :无法连接到“git://github.com”
【发布时间】:2016-12-12 09:18:02
【问题描述】:

我正在尝试使用 JHipster(和 Windows 10)创建一个新项目,但收到以下警告消息:

WARNING! Failed to connect to "git://github.com"

其余的创建进展顺利,但后来项目无法运行,因为它缺少来自 github 的组件。

我配置了我的代理,下一行工作

git ls-remote http://github.com/angular/angular-phonecat.git

【问题讨论】:

    标签: git github yeoman jhipster


    【解决方案1】:

    经过一番研究,我发现了 rff-doctor (https://github.com/rakuten-frontend/rff-doctor) 并诊断出这个:

    × Failed to connect to "git://github.com".
     Error: Command failed: git ls-remote git://github.com/octocat/Spoon-Knife.git HEAD
     1. Check the Internet connection.
     2. If you are using HTTP proxy, try this command:
          $ git config --global url."https://".insteadOf git://
    

    我运行了命令并且下一个连接正常。

    【讨论】:

    • 优秀!!拯救了我的一天!顺便说一句,在某些环境中,可能还需要git config http.proxy <proxy-URL>
    • 该死的,我太早乐观了。出于某种奇怪的原因,rff-doctor 仍然报告“无法连接到 git://github.com”,即使在同一终端窗口中运行 git ls-remote git://github.com/octocat/Spoon-Knife.git 给了我 d0dd1f61b33d64e29d8bc1372a94ef6a2fee76a9 HEAD。运行 jhipster 也会出现同样的错误。任何想法如何解决它?
    • 这是由于通过代理的响应时间过长。也可以在这里查看:github.com/jhipster/generator-jhipster/issues/…
    猜你喜欢
    • 2013-10-21
    • 2017-05-13
    • 1970-01-01
    • 2013-04-16
    • 2013-04-24
    • 1970-01-01
    • 2019-03-14
    • 1970-01-01
    • 2021-04-26
    相关资源
    最近更新 更多