【Github】ssh: connect to host github.com port 22: Connection refused

ssh: connect to host github.com port 22: Connection refused

近日在进行push的时候出现以下错误:

复制代码
$ git push
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.

解决思路:

参考资料:

然后保存,Git中输入一下密令:

复制代码
ssh -T git@github.com

使用ssh -T git@github.com来测试和GitHub的网络通信是否正常,如果提示Hi xxxxx! You've successfully authenticated, but GitHub does not provide shell access. 就表示一切正常了。

然后就可以正常上传了。

相关推荐
电商API_180079052472 小时前
京东商品详情API技术文章
大数据·运维·人工智能·网络爬虫
三言老师3 小时前
秘诀-如何远程SSN访问家里的八台电脑(frp 实操方案)
linux·运维·ssh
BTU_YC5 小时前
Docker Compose 部署 DozerDB 完整教程
运维·docker·容器
wangruofeng6 小时前
20822 star 的开源录屏软件弃 Tauri 换 Electron:表层是换壳,里子是 46 个 Rust 模块
github·音视频开发
RisunJan7 小时前
Linux命令-scriptreplay(终端会话回放)
linux·运维·chrome
x²+(y-√³x²)²=19 小时前
Linux打包文件到Windows,文件/文件类型丢失
linux·运维·windows
世人万千丶9 小时前
去重插入与超限淘汰:ArkTS 实现鸿蒙搜索历史的 LIMIT 艺术
运维·服务器·学习·华为·harmonyos·鸿蒙
CAD老兵9 小时前
一行代码集成 DWG/DXF 图纸查看:测量批注,数据不出站
前端·javascript·github
柒号华仔9 小时前
「速通Shell」聚砖成墙,Shell函数封装之道
linux·ssh·bash
未来之窗软件服务9 小时前
企业自动化运营-电子合同预览-东方仙盟
运维·自动化·仙盟创梦ide·东方仙盟