error: failed to push some refs to '[email protected]'

【問題描述】:通過 git push -u origin master 提交代碼時出現如下報錯:

##git push -u origin master
Enumerating objects: 96, done.
Counting objects: 100% (96/96), done.
Delta compression using up to 4 threads
Compressing objects: 100% (74/74), done.
Writing objects: 100% (74/74), 93.61 KiB | 3.23 MiB/s, done.
Total 74 (delta 33), reused 0 (delta 0)
remote: GitLab: You are not allowed to push code to protected branches on this project.
To git.bd.com:new/bd.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to '[email protected]:new/bd.git'

【排查分析】:語法沒有問題,是提交到指定的分支,與以往沒有不同
因爲項目賬號刪除,即沒有owner,而當前提交人員爲developer,所以報錯。
【解決方案】: 添加項目的owner,再次提交即可。

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章