how to undo previous interactive rebase code example Example: undo git rebase git reset --hard HEAD@{5}