1

enter image description here

I don't want the part Rebasing feature/thread-temp onto 02fc3a4771e03d0ba98b9e52305117b4cfa05fce

I tried git reset --soft HEAD~1 and recommitting, but it won't save me..

I don't know how I ended up here since I vaguely knows what rebase is and didn't mean to use it here.

How do I go back to the normal state?

It's different from other questions in that I could use magit-specific method.

eugene
  • 39,839
  • 68
  • 255
  • 489

2 Answers2

4

Use @Dogbert's answer if your rebase has not concluded and you're still able to abort it.

If you've gone past that and completed your rebase locally and would like to undo it, you can follow the accepted answer from here

In the magit status buffer, press

l r

This will show the magit-reflog buffer. Now move your cursor to the commit you want to reset to (be sure) and

M-x magit-reset-hard

You'll see a list of choices, with the default-selected one corresponding to where your cursor was when you M-x magit-reset-hard. You could pick another, but again: be certain.

Then press enter, and the process is done.

user1011471
  • 1,090
  • 2
  • 14
  • 34
anquegi
  • 11,125
  • 4
  • 51
  • 67
  • I did this just now and the name magit used in the list of `magit-reset-hard` choices surprised me because it was relative to `some-other-branch~1` ... but it was still the correct one. Worked like a charm. – user1011471 Feb 02 '18 at 18:26
1

In the latest Magit, you can abort an active rebase by pressing r then a.

Magit Rebase Popup

Dogbert
  • 212,659
  • 41
  • 396
  • 397