git clone github上的项目时出现报错“Proxy CONNECT aborted”解决方法
git clone时报错fatal: unable to access ‘https://github.com/xxx’: Proxy CONNECT aborted怎么办?在我们git clone 项目连接时会出现报错Timed out的情况,这个时候我们就会配置 git 的代理,网上的教程一般是:git config --global http.proxy "127.0.0.1:1080"gi
·
git clone时报错fatal: unable to access ‘https://github.com/xxx’: Proxy CONNECT aborted怎么办?
在我们 git clone 项目链接 时会出现报错Timed out的情况,这个时候我们就会配置 git 的代理,网上的教程一般是:
git config --global http.proxy "127.0.0.1:1080"
git config --global https.proxy "127.0.0.1:1080"
但是,这种方法不一定适合每个人,如果不适用,就会出现如题“Proxy CONNECT aborted”的错误,那么正确的设置代理的方法如下:
1.打开浏览器,查看代理的“选项”
2.查看所用代理的代理协议和端口
3.按照代理协议和端口设置代理,比如我的代理协议是socks5,端口是10808
git config --global http.proxy "socks:127.0.0.1:10808"
git config --global https.proxy "socks:127.0.0.1:10808"
4.设置好了就可以成功git clone了
更多推荐
已为社区贡献1条内容
所有评论(0)