git 设置代理、取消代理、查看代理

  • Post author:
  • Post category:其他


git设置和取消代理的作用

当我们访问GitHub的时候一般都会使用梯子,所以往上推代码的时候也是需要梯子,没有梯子推送成功概率很低,一般都会报错超时,所以设置梯子提高访问成功率

取消代理是因为,访问Gitee的时候不需要梯子,所以要取消代理

1.

设置代理

git config --global http.proxy  'http://127.0.0.1:9083' 
git config --global https.proxy 'http://127.0.0.1:9083'

2.

取消代理

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

3.

查看代理

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

4.拓展知识

git helper -a // 查看全部git子命令



版权声明:本文为weixin_50726818原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。