我通过交互式 rebase 让自己陷入了混乱,我现在希望中止它。(即回到我进入交互式变基模式之前的点,在我的例子中是 via git pull --rebase
。)这样做的方法似乎是 via git rebase --abort
,但这不起作用:
$ git rebase --abort
error: Ref refs/heads/master is at 55b388c141b1485b1acd9e050dbeb0eb90ef2ee7 but
expected b918ac16a33881ce00799bea63d9c23bf7022d67
fatal: Cannot lock the ref 'refs/heads/master'.
Could not move back to refs/heads/master
我怎样才能摆脱交互式变基模式,并清理对它的所有引用?(git reset --hard
成功,但不会让我退出变基模式。)