2OF1 · the depletionmode zineLinkedIn · X
← back to the issue

03 August 2010

Git: Undoing a rebase (reflog)

Originally published on the old depletionmode / 2of1 blog (archived copy).

The easiest way to undo a rebase is to find the relevant commit as it was immediately before the rebase using git reflog.

You can then reset to that commit; e.g.:

listing text
git reset --hard HEAD@{50}

→ end of entry

2/1
@depletionmode
security research & systems engineering