【Git】Git代理配置 http & https

✨Git代理配置

# http & https
git config --global http.proxy 127.0.0.1:7890
git config --global https.proxy 127.0.0.1:7890

# socks5
git config --global http.proxy socks5://127.0.0.1:7890
git config --global https.proxy socks5://127.0.0.1:7890

# 取消代理
git config --global --unset http.proxy
git config --global --unset https.proxy

ssh代理配置暂未解决

查询相关教程对~/.ssh/config进行配置

会导致使用git clone时ssh认证出错


曲线救国方式:

配置git https代理后clone repo

修改.git中的config

把remote的url更改为ssh url


⭐转载请注明出处

本文作者:双份浓缩馥芮白

原文链接:https://www.cnblogs.com/Flat-White/p/17413624.html

版权所有,如需转载请注明出处。

posted @ 2023-05-18 23:29  双份浓缩馥芮白  阅读(30)  评论(0编辑  收藏  举报