windows下git pull超时,ping不通github

报错

ssh: connect to host github.com port 22: Connection timed out fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists.

解决办法

修改hosts

最后加一行,文件位置:C:\Windows\System32\drivers\etc\hosts

java 复制代码
140.82.113.3 github.com
注意

github的IP地址可能会变,去ipaddress.com查询即可

亲测有效

相关推荐
北冥有羽Victoria17 分钟前
OpenCLI 操作网页 从0到1完整实操指南
vscode·爬虫·python·github·api·ai编程·opencli
Thomas.Sir44 分钟前
GitHub Copilot从入门到精通【从基础补全到智能代理,解锁AI编程全技能】
github·copilot·ai编程
Hhaizhr1 小时前
Hermes Agent频频超时?一招教你解决API网络连通问题
github
华科大胡子1 小时前
Git二分法定位Bug
git
Renlijuande1 小时前
VSCode + GitHub Copilot + C语言环境(MinGW)配置攻略(2026版)
vscode·github·copilot
AI成长日志2 小时前
【GitHub开源项目专栏】TGI源码剖析:HuggingFace推理服务核心实现
开源·github
GISer_Jing2 小时前
AI Weekly | 2026年4月第二周 · GitHub热门项目与AI发展趋势深度解析
人工智能·github
代码搬运媛2 小时前
Open Core 模式:开源版与企业版的双仓库管理实践
github
AI精钢2 小时前
升级踩坑实录:OpenClaw 2026.4.9 后 GitHub Copilot 调用 Claude 全线 HTTP 400 的根因与修复
http·github·copilot·claude·github copilot·openclaw·ai 网关
m0_579146653 小时前
Git暂存区操作与版本回退
git