GitHub time out问题解决

环境:WIN10,使用了 梯-子,开着 梯-子进行pull origin master,结果报错:

fatal: unable to access 'https://github.com/xxx.git/': Failed to connect to github.com port 443: Timed out

解决方案

  1. 配置 git 的代理

git config --global http.proxy "127.0.0.1:1080"
git config --global https.proxy "127.0.0.1:1080"

这里,梯 子 要始终开着

  1. 使用 https 方式 clone

git clone https://github.com/xxx.git

注意:这里必须使用 https 方式, ssh 方式即使配置了 git 的代理也不好使。。

后续

后来GitHub又能访问了...
我们开 梯- 子,然后出现了如下错误:

fatal: unable to access 'https://github.com/FengGuanxi/HDU-Experience.git/': Failed to connect to 127.0.0.1 port 1080: Connection refused

于是我还得改回去,那么取消代理的命令是:

git config --global --unset http.proxy
git config --global --unset https.proxy

然后就OK了

参考链接

git clone Timed out 解决
git 设置和取消代理

支付宝红包码,你领红包我赚赏金;土豪请任意收钱码打赏

你可能感兴趣的:(GitHub time out问题解决)