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查询即可

亲测有效

相关推荐
DogDaoDao13 分钟前
【GitHub】andrej-karpathy-skills:让 AI 编程助手告别三大通病
人工智能·深度学习·程序员·大模型·github·ai编程·andrej-karpathy
Shin_chan2 小时前
Linux 内核史诗级提权漏洞:CVE-2026-31431 复现与分析
github
CoderJia程序员甲5 小时前
GitHub 热榜项目 - 日榜(2026-05-03)
ai·大模型·llm·github·ai教程
yyuuuzz6 小时前
aws 基础认知与实践注意点
运维·服务器·网络·云计算·github·aws
weixin_514253187 小时前
430-github-aguvis tmux
github
阿里嘎多学长7 小时前
2026-05-03 GitHub 热点项目精选
开发语言·程序员·github·代码托管
努力努力再努力wz8 小时前
【MySQL进阶系列】一文打通事务机制:从锁、Undo Log 到 MVCC 与隔离级别
c语言·数据结构·数据库·c++·mysql·算法·github
武超杰8 小时前
Git 从入门到精通教程
git
程序员夏末8 小时前
【开源经历 | 第一篇】参与开源需要掌握的Git和Github指令
git·开源
钱塘江渔夫9 小时前
一键式解决Windows访问github.com不了问题
windows·github