标题设置代理:
git config --global http.proxy http://127.0.0.1:1080
git config --global https.proxy https://127.0.0.1:1080
或者
git config --global http.proxy socks5://127.0.0.1:1080
git config --global https.proxy socks5://127.0.0.1:1080
标题查看代理:
git config --global --get http.proxy
git config --global --get https.proxy
标题取消代理:
git config --global --unset http.proxy
git config --global --unset https.proxy
标题针对docker容器的代理配置:
在创建(run)容器的时候,加上 --net=host 这个选项,就可以实现容器内外共享网络,然后再在容器内部配置git,就可以实现容器内代理了