[英]Ran git rebase origin/develop and now I have a (develop|REBASE 1/2) - branch
So, I am still fairly new to git and still running into things here and there. 因此,我对git还是很陌生,仍然在这里和那里碰到东西。 Someone shared a quick tip for pulling on master branch... git rebase origin/master
. 有人分享了拉主分支的快速提示... git rebase origin/master
。 So, I did the same on develop not thinking it would hurt it. 因此,我在开发上也做了同样的事情,并不认为这会伤害到它。 Not I am at branch (develop|REBASE 1/2)
. 我不在分支(develop|REBASE 1/2)
。 And when I switch to master it still shows (develop|REBASE 1/2)
. 而且当我切换到master时,它仍然显示(develop|REBASE 1/2)
。 I went to revert backwards a commit and nothing happened. 我去向后退了一个提交,什么也没发生。
I am trying to undo this and get back to the latest commit. 我正在尝试撤消此操作并返回到最新提交。 Does anyone have any suggestions? 有没有人有什么建议?
EDIT So, I finally found something to help. 编辑因此,我终于找到了一些帮助。 I first ran git rebase --abort
, then I really needed to go backwards so I ran git reset --hard HEAD@{22}
to go back to the last commit I needed to before messing up. 我首先运行git rebase --abort
,然后我真的需要倒退,所以我运行了git reset --hard HEAD@{22}
返回到我需要弄乱之前的最后一次提交。
git rebase --abort
将取消您当前已签出的分支上的rebase操作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.