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博客

相关推荐
摇滚侠23 分钟前
零基础小白自学 Git_Github 教程,解决分支合并冲突,笔记14
笔记·git·github
CoderJia程序员甲1 小时前
GitHub 热榜项目 - 日榜(2025-12-1)
ai·开源·llm·github·ai教程
摇滚侠6 小时前
Idea Git 合并分支,rebase 和 merge 的区别,应该使用哪个,多人协作开发,禁止使用 rebase 合并分支
git·github
猫头虎8 小时前
本地部署 Stable Diffusion3.5超详细教程
stable diffusion·开源·prompt·github·aigc·midjourney·ai编程
摇滚侠9 小时前
零基础小白自学 Git_Github 教程,分支合并,笔记13
笔记·git·github
七牛云行业应用9 小时前
霸榜 GitHub 的 TrendRadar 能用吗?实测三天服务器崩了,附修复代码
github
逛逛GitHub10 小时前
DeepSeek 最新开源!直接干到了数学奥赛金牌水平。
github
小年糕是糕手11 小时前
【C++同步练习】C++入门
开发语言·数据结构·c++·算法·pdf·github·排序算法
hello1114-14 小时前
Git 学习打卡Day1-基础、高级、远程仓库初步
git·学习·github
蚂蚁集团数据体验技术14 小时前
AI 文字信息图表的技术选型
前端·javascript·github