GitHub提交项目到仓库fatal: No configured push destination.

原因:没指定提交到哪个远程仓库

解决方法:

在你git add .和commit之后

bash 复制代码
git add .
git commit -m "信息"

git push前输入以命令

bash 复制代码
git branch -M main
git remote add origin git@github.com:xxx(你GitHub的名称)/xxx.git(你仓库的名称)
git push -u origin main

参考:

关于gitee第一次提交出现fatal: No configured push destination. Either specify the URL from the command-line or_either specify the url from the command-line or co-CSDN博客

如何新建Github仓库并将本地文件上传到Github(远程连接)以及Git常用命令总结_github 新建仓库push-CSDN博客

相关推荐
CoderJia程序员甲10 小时前
GitHub 热榜项目 - 日榜(2026-04-09)
人工智能·ai·大模型·github·ai教程
魔卡少女110 小时前
Nginx配置代码化自动部署詹金斯/Github方案
前端·nginx·github
李白的天不白10 小时前
ai编程工具
github
斯坦SteinY11 小时前
github年度热门开源项目
ai·chatgpt·开源·github·排名·热门项目
第一程序员12 小时前
Python函数式编程:非科班转码者的入门指南
python·github
Hhaizhr12 小时前
放弃OpenClaw,开始用Hermes
github
ShawnLiaoking12 小时前
Github 克隆 PyCharm,vscode
ide·pycharm·github
想七想八不如1140813 小时前
【GitHub开源】一款基于 Python 的人脸识别 C/S 系统:YOLOv5 + PyQt5 + 批量入库
yolo·开源·github
CoderJia程序员甲14 小时前
GitHub 热榜项目 - 日榜(2026-04-10)
人工智能·ai·大模型·github·ai教程
辣椒酱.14 小时前
github入门与实战
github