[github]——git clone时遇到的错误

错误1:fatal: unable to access … Received HTTP code 503 from proxy after CONNECT

尝试解决1:
参考了:Received HTTP code 503 from proxy after CONNECT,尝试取消代理啥的,但我看我的.gitconfig里面本来就没有代理的.

git clone https://github.com/... --config http.proxy= --config http.
sslVerify=false

所以结果还是失败了,报出了下面的错误:

错误2:fatal: unable to access … gnutls_handshake() failed: The TLS connection was non-properly terminated.

尝试解决2:
参考了:Git gnutls_handshake() failed解决办法,尝试把https改成了http,然后又报出了错误1…

git clone http://github.com/...

最终解决

于是我想着把尝试解决1和2结合起来或许能行:

git clone http://github.com/... --config http.proxy= --config http.
sslVerify=false

成功了…

warning: redirecting to https://github.com/.../
remote: Enumerating objects: 597, done.
remote: Counting objects: 100% (597/597), done.
remote: Compressing objects: 100% (307/307), done.
remote: Total 597 (delta 321), reused 524 (delta 248), pack-reused 0
Receiving objects: 100% (597/597), 13.19 MiB | 6.13 MiB/s, done.
Resolving deltas: 100% (321/321), done.

参考:

Received HTTP code 503 from proxy after CONNECT
Git gnutls_handshake() failed解决办法

你可能感兴趣的:(github之家)