error: failed to push some refs to ‘http://git.text.com:9988.git‘hint: Updates were rejected...

To http://git.text.com:9988/text.git
 ! [rejected]        dev -> dev (non-fast-forward)
 ! [rejected]        feature.import_setting_view -> feature.import_setting_view (non-fast-forward)
error: failed to push some refs to 'http://git.text.com:9988.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
 

解决方案:不知什么原因,在git push时候,git自己选择dev分支合并到dev分支,莫名其妙

方法一:打开gitlab 网站,找到merge request里面自己提交的合并分支删除,重新上传,再次在git 命令里面git push就ok了

方法二:在git 命令窗口输入git push 自己分支的路径//比如origin feature_view

 如果还不行在上面命令基础上,后面加个-f

问题解决

猜你喜欢

转载自blog.csdn.net/qq_43644046/article/details/122696942