【git】问题解决---Failed to connect to github.com

场景

最近运行命令git push,git pull或者git clone的时候总会报如下错误

bash 复制代码
fatal: unable to access 'https://github.com/xxxxx/xxxxxx.git/': **Failed to connect to github.com** port 443 after 21052 ms: Couldn't connect to server

原因

一般是网络配置原因造成的, 如果能正常进github网页,考虑代理配置原因。

解决方法

通过以下命令从 Git 配置中移除全局代理设置

bash 复制代码
git config --global --unset https.proxy
git config --global --unset http.proxy
相关推荐
Zzz 小生10 小时前
LangChain Streaming-Overview:流式处理使用完全指南
人工智能·python·语言模型·langchain·github
头发那是一根不剩了14 小时前
Git 常用命令
git
x-cmd15 小时前
[x-cmd] x git - Git 命令增强工具
git·终端·命令行·x-cmd
程序员果子16 小时前
Git从零到远程协作:手把手实战指南
git
用户5798547697118 小时前
04:工具系统设计:从抽象基类到 JSON Schema 的完整实现
github
fchampion18 小时前
最终一致性
java·spring·rabbitmq·github·mvc
猫头虎20 小时前
OpenClaw 常用操作命令完整速查手册:终端 CLI 操作指令详解|聊天斜杠指令详情
运维·git·容器·开源·github·aigc·ai编程
小哈里1 天前
【工具】Linux远程开发核心工具,Git命令缩写与SSH常用命令
linux·git·ssh·工具·远程开发
阿里嘎多学长2 天前
2026-02-20 GitHub 热点项目精选
开发语言·程序员·github·代码托管
迈克桀森2 天前
Git 日常操作全攻略:拉取 / 提交代码 + 高频命令速查
git·github