美文网首页
mac终端设置git代理

mac终端设置git代理

作者: 靠北的北 | 来源:发表于2020-07-16 10:03 被阅读0次

终端设置代理

每次打开终端需要重新设置

export http_proxy=socks5://127.0.0.1:7980
export https_proxy=socks5://127.0.0.1:7980

cocoapods设置代理

查看代理

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

pod设置代理

//端口号可以自己更改
git config --global http.proxy 'socks5://127.0.0.1:1086' 
git config --global https.proxy 'socks5://127.0.0.1:1086'
//一般来说设置前两个就行了
git config --global https.proxy http://127.0.0.1:1086
git config --global https.proxy https://127.0.0.1:1086

取消代理

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

相关文章

网友评论

      本文标题:mac终端设置git代理

      本文链接:https://www.haomeiwen.com/subject/imouhktx.html