搜 索

Git 设置代理,一篇全,加快上传下载 Github 的代码

  • 1.6k阅读
  • 2020年12月04日
  • 0评论

设置 http 或 https 代理(提前搭好梯子):

git config --global http.proxy http://127.0.0.1:3213
git config --global https.proxy https://127.0.0.1:3213

也能支持设置 socks5 代理:

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

取消代理,置空:

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

参考原文:https://www.cnblogs.com/hookjc/p/13179004.html

小胖狐针对原文做了优化、修改和吸收。

评论区
暂无评论
avatar