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

相关推荐
阿米亚波3 小时前
【C/C++包管理器】vcpkg(by microsoft)
c语言·c++·git·vscode·microsoft·github·vcpkg
打工的小王6 小时前
github教程之多人协作
github
笨笨狗吞噬者6 小时前
IRIS: shell 中的智能实时输入提示工具
github·shell
fthux8 小时前
MCP协议开发实战:从零搭建AI Agent工具链
前端·人工智能·ai·开源·github
@CLoudbays_Martin119 小时前
Linux 服务器如何查看是否被植入后门?
linux·服务器·网络·安全·github·ssl
一次旅行9 小时前
Ollama本地私有化大模型完整工程实战
人工智能·机器学习·github
华科大胡子9 小时前
GitHub Copilot 能换成本地模型吗?—— 本地化替代方案深度解析
人工智能·github·copilot
TunerT_TQ1 天前
Valhalla 静态工程审阅 #024|蚂蚁集团Ant Design 源码证据驱动评测【大厂开源基础设施特辑】
开源·github·蚂蚁集团·#推荐系统·#typescript·#antdesign
tokenKe1 天前
Cloudflare Computer: 给每个 AI Agent 一台专属电脑 | SSP Github Daily
人工智能·github