使用 Git 報錯 error: src refspec master matches more than one.


今天在使用 Git push 代碼時遇到一個報錯:

error: src refspec master matches more than one.
error: failed to push some refs to 'git@127.0.0.1:yn/enh.git'

 

出現這個錯誤是因為有一個與當前提交分支同名的標簽

 

查看標簽列表:

git tag

 

刪除這個標簽(確定標簽無用時):

git tag -d <tag-name>

 

 

再次 push 就 ok 了


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM