Push master
The following error occurred when branching:
To git@gitlab.ddcard.com.cn:csntgao/qiaruqifen.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'git@gitlab.ddcard.com.cn:csntgao/qiaruqifen.git'
master
The branch can only be pulled but not pushed. Other branches are normal. I searched online and said that I need to delete the two files in .git
. I did it but failed
I remember that I might have deleted something by mistake when I rolled back the version on the master, so I planned to delete the local master
branch and pull a new master branch again. I used fetch
and then checkout master
Then I made some modifications and tried push, but the same error occurred in the Korean version
I think it may be necessary to completely delete the branch deleted by git branch -D
. Master, please come soon
迷茫2017-05-02 09:37:52
You may consider rolling back the local master to the same version as the online one
git reset --hard ooxxooxx
ooxxooxx represents the version number seen using git log. It’s a long string
and then
git pull
Go on and finish the work, commit and push
If you can’t push, it basically means that your account does not have push permission to the remote master