Failed to connect to 127.0.0.1 port 7890 after 0 ms: Connection refused解决方案

Failed to connect to 127.0.0.1 port 7890 after 0 ms: Connection refused解决方案

    • 先看当前项目的配置
    • 解决方案

先看当前项目的配置

git config --list

得到类似如下的输出
Failed to connect to 127.0.0.1 port 7890 after 0 ms: Connection refused解决方案_第1张图片

我的问题是之前给设置的代理是网址后面加代理地址 刚刚看了一堆人的解决方案去清除代理 然后我发现还是报错Failed to connect to 127.0.0.1 port 7890 after 0 ms: Connection refused
原因就是
http.https://github.com.proxy=http://127.0.0.1:7890
https.https://github.com.proxy=https://127.0.0.1:7890
这两行导致的

解决方案

所以我把这两行删除了

git config --global --unset http.https://github.com.proxy
git config --global --unset https.https://github.com.proxy

Failed to connect to 127.0.0.1 port 7890 after 0 ms: Connection refused解决方案_第2张图片
只留下了我自己的代理这两行后成果run了
http.proxy=http://xxx.xx.xxx.1:7890
https.proxy=http://xxx.xx.xxx.1:7890

你可能感兴趣的:(Failed to connect to 127.0.0.1 port 7890 after 0 ms: Connection refused解决方案)