我刚刚安装了Windows 10,Visual Studio Community 2015和Git for Windows。我还安装了最新的Bitbucket和GitHub扩展。
在Visual Studio中,我克隆了我的Bitbucket.com托管的存储库,并成功执行了这些操作:
$ git --version
git version 2.19.2.windows.1
$ git pull
Already up to date.
但是当我试图从另一个存储库中提取时,我收到了这个错误:
$ git pull git://github.com/aegif/CmisSync.git
fatal: unable to lookup github.com (port 9418) (Either the application has not called WSAStartup, or WSAStartup failed. )
我能ping通github.com。
我该如何调查并解决问题?
对于那些无法编辑URL的人,将git降级到以前的版本似乎有效。
这似乎与git版本2.19.2.windows.1
有关
一个低技术的解决方法是用URL中的git://
替换https://
。
然后命令顺利进行。
警告:
这是早期版本的Git for Windows中的已知错误。
升级/安装版本大于2.20.0.
您可以使用命令$ git --version
检查当前安装的版本
我发现还有一个解决方案,即导航到.git
文件夹,更改
[remote "origin"]
url = git://github.com/yourUsername/yourRepo.git
至
[remote "origin"]
url = https://github.com/yourUsername/yourRepo.git
如果不想降级git客户端,修复问题