使用https url从github克隆项目时突然失败了,失败原因如下:
xxx ➤ git clone https://github.com/xxx/xxx.git
Cloning into 'xxx'...
fatal: unable to access 'https://github.com/xxx/xxx.git/': Failed to connect to 127.0.0.1 port 9999 after 3 ms: Couldn't connect to server
考虑之前在使用homebrew,git和github时出了问题修改过一些配置,从报错ip看起来像是跟代理有关,所有就试着取消了代理,修复了该问题。
- 先git config --list看下全部配置
credential.helper=xxx
init.defaultbranch=main

在尝试使用https url从github克隆项目时遇到错误:Couldn‘t connect to server。问题根源在于git配置中存在代理设置。通过运行`git config --list`检查配置,发现并取消了代理,成功修复了该问题。
最低0.47元/天 解锁文章
9293





