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

相关推荐
你挚爱的强哥14 小时前
解决:动态文本和背景色一致导致文字看不清楚,用js获取背景图片主色调,并获取对比度最大的hex色值给文字
前端·javascript·github
逛逛GitHub15 小时前
最近用的贼多的 3 个 Claude Code 开源宝藏,感觉太爽了。
github
一只叫煤球的猫16 小时前
[自荐] macOS 99% 原生 SSH + SFTP 工具 Remora ,现在开源了~
开源·ssh·github
用户97514707513617 小时前
如何在 JavaScript 中实现防抖和节流?
github
喷火龙8号17 小时前
记一次已推送仓库启用 Git LFS 的完整迁移与验证过程
github
大家的林语冰18 小时前
《前端周刊》React 败北,虾皇登基,OpenClaw 勇夺 GitHub 第一开源软件
前端·javascript·github
ShineWinsu20 小时前
对于Linux:git版本控制器和cgdb调试器的解析
linux·c语言·git·gitee·github·调试·cgdb
zhensherlock20 小时前
Protocol Launcher 系列:Microsoft Edge 浏览器唤起的优雅方案
javascript·chrome·microsoft·typescript·edge·github·edge浏览器
嗡嗡嗡qwq21 小时前
【如何使用vscode+github copilot会更加省额度】
vscode·github·copilot
汪海游龙1 天前
03.25 AI 精选:Wine 11重写内核层提速跑Windows游戏
github