美文网首页
fatal: unable to access ‘https:/

fatal: unable to access ‘https:/

作者: 我叫没名字啊 | 来源:发表于2023-02-21 14:55 被阅读0次

原文转载自这里

Q:

今个 pod update 的时候,出现了死活拉不下来的情况,clash 里那个复制终端命令后也不行,报错:

unable to access 'https://github.com/CocoaPods/Specs.git/'

A:

用代理+ Git Proxy 设置来解决,设置git Global Proxy
其中 socks5 后面的值,就是 clash 点 ‘复制终端命令’ 粘出来里的值

clash 点 ‘复制终端命令’ 复制的值:
export https_proxy=http://127.0.0.1:7890 http_proxy=http://127.0.0.1:7890 all_proxy=socks5://127.0.0.1:7890

// 命令行设置 IP 和 host
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 --list 看看是否配置成功
如果要移除 git proxy 配置,可以用以下命令:

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

这样就可以访问魔法网站辣🧙🏻

相关文章

网友评论

      本文标题:fatal: unable to access ‘https:/

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