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

相关推荐
dong_junshuai2 小时前
每天一个开源项目#43 KTransformers:18.5K星的异构MoE推理引擎
github
OpenTiny社区5 小时前
TinyRobot v0.5.0 新版本强在哪?
前端·vue.js·github
humbinal7 小时前
同时支持 gui & cli 的 parquet 文件查看工具,高性能小清新!
hive·python·rust·spark·开源·github·parquet
华科大胡子7 小时前
GitHub Actions 自动化运维实战:从入门到精通
github
fliter10 小时前
不用再反复 stash:用 Git Worktree 同时开发多个分支
后端·github
Tenifs11 小时前
在 VS Code 中,你可以通过修改全局或项目目录下的 settings.json 文件来彻底关闭 GitHub Copilot
github·copilot
Cosolar12 小时前
深入理解 AI Agent:设计原理与工程实践
人工智能·面试·github
love530love1 天前
ComfyUI 插件发布 GitHub Release + Comfy Registry (官方节点商店)完整复盘教程(从零开始)
人工智能·windows·github·devops
CoderJia程序员甲1 天前
GitHub 热榜项目 - 周榜(2026-07-18)
ai·大模型·llm·github·ai教程
AA陈超1 天前
006 T03 — 蓝图操作指南
c++·游戏·架构·ue5·github·虚幻引擎