当你想去克隆一个别人github上的repository时,发现系统不让你动,提示你防火墙禁止对git://的访问,这时候就只能用https://来访问repository。

再次就是当你npm install时候,如果是从git上面下载依赖,那么很容易报下面的错误:

silly pacote range manifest for regenerator-runtime@^0.10.5 fetched in 1ms
silly resolveWithNewModule regenerator-runtime@0.10.5 checking installable status
silly fetchPackageMetaData error for eve@git://github.com/adobe-webplatform/eve.git#eef80ed Error while executing:
silly fetchPackageMetaData D:\Program Files\Git\cmd\git.EXE ls-remote -h -t git://github.com/adobe-webplatform/eve.git
silly fetchPackageMetaData
silly fetchPackageMetaData fatal: unable to look up github.com (port 9418) (应锟矫筹拷锟斤拷没锟叫碉拷锟斤拷 WSAStartup锟斤拷锟斤拷锟斤拷 WSAStartup 失锟杰★拷 )
silly fetchPackageMetaData
silly fetchPackageMetaData exited with error code: 128

所以我们设置Github,使用https:// 来替换 git://

操作如下,执行下方代码::
git config --global url."https://".insteadOf git://

如果还是不行请继续执行清除缓存:
npm cache clear

一顿操作之后,你的.gitconfig中会多出一行参数设置:

   [url "https://"]   
       insteadOf = git://

设置之后,就可以以后不管你在终端进行clone,使用git://,或者http://去访问别人的repository,两种方式都会默认变成http://的形式进行连接并正常的工作了。