当前位置:网站首页>Push failed Dst refspec V1.0.0 matches more than one.
Push failed Dst refspec V1.0.0 matches more than one.
2022-01-15 02:03:26 【markix】
执行git push
失败,异常信息:Push failed Dst refspec V1.0.0 matches more than one.
原因:远程存在相同名称的branch和tag,冲突了。
解决:删除branch或者tag
- 删除远程tag(本地tag不会被删)
$ git push origin --delete refs/tags/[name] - 删除远程branch(本地branch不会被删)
$ git push origin --delete refs/heads/[name]
另一种解决思路:
注意,上述命令不会删除本地的branch或tag,也就是说,如果你本地也存在相同名称的branch和tag,虽然通过上述一顿操作后可以正常push,但是,下次push还是会出现同样的问题。至于原因你懂的吧,push后远程又会出现相同名称的branch和tag。所以,根本问题是,怎么避免branch和tag名称冲突?
我的解决思路是,把branch当成一些列版本的合集,命名格式为:V1.x,而tag当作具体的一个发布版本,命名格式为:V1.x.x。(参考开源库的方式,eg: spring)
划重点,个人觉得比较好处理方式
- 删除远程分支
$ git push origin --delete refs/heads/[name] - 修改本地分支的名称
$ git branch -m [old_name] [new_branch_name]
版权声明
本文为[markix]所创,转载请带上原文链接,感谢
https://markix.blog.csdn.net/article/details/119850310
边栏推荐
- Résumé de fin d'année 2021
- Trois JS rendent des tailles qui ne sont pas des tailles de formulaire de navigateur et sont vérifiées pour résoudre les problèmes
- AndroidAPP启动速度优化;冷启动和热启动解析,2021Android研发必问高级面试题
- 2021.10.10 deduction - stock price fluctuation
- Androidstudio下一个工程生成不同的app,多亏这份《秋招 金九银十-腾讯面试题合集》跳槽薪资翻倍
- Winfo link database addition, deletion, modification and query
- Sqlstatehy0001045access denied for userrootipusing passwords yes
- Sqlstatehy0001045access denied for userroot my ipusing passwords yes
- Using WinDbg to analyze magicodes A wrong writing of IE leads to a sharp increase in memory
- Using WinDbg to analyze magicodes A wrong writing of IE leads to a sharp increase in memory
猜你喜欢
随机推荐
- backtrader和tushare进行量化交易
- 一些开源
- 程序员的基本功:关于JVM
- 程序员不能不懂的一些事:代码片段
- 通过故事的方式尝试和大家说说线程池
- 花5分钟学习TiDB
- Unity3D开发
- How to turn this MySQL statement into an opentsdb Jason statement?
- Watermelon video game station
- 使用MRFT(混合现实功能工具)为 HoloLens 2 创建 Unity 项目
- PyCharm汉化(官方)
- Unity改变图片文本颜色
- After the H3C 5170 switch 802.1x is configured, the win terminal cannot normally issue a security ACL
- Unity change la couleur du texte de l'image
- Pycharm Chinese (Official)
- Créer un projet d'Unit é pour hololens 2 en utilisant mrft (Hybrid Reality Function Tool)
- Unity改變圖片文本顏色
- rds执行sql报错
- 证券公司开户安全吗?股票开户选择哪家证券所
- Jimureport building block report v1 Version 4.2 release, free visual low code report
- JVM - automatic memory management - 2 - garbage collector and memory allocation strategy
- Web page integration calls third-party exe -- writing registry
- Spotmax update: scalable statistics, instance preheating, intelligent storage, providing multiple cost reduction guarantees
- 黑五 圣诞节
- 【TiChoo资讯站】
- 行业分享 | TiChoo数据CEO 陆诗冬展望全球视频电商未来蓝图
- tiktok 数据分析平台
- TikTok数据分析选品平台 - TiChoo数据
- 使用S7.net通信库
- 使用Text.json解析Json文件
- 常用的SQL语句
- 使用多线程写winform程序
- Modbus协议编写与测试
- 使用多线程,Invoke和Action 访问SQL数据库
- Access数据库练习
- 泛型类, 泛型接口的继承, 委托
- 泛型类,泛型接口
- 跨域请求无法携带Cookie的问题
- I think code is a work of art. She's beautiful
- Try the map and slice of the model version in go 1.18