git undo last merge to master code example Example: revert last merge git git revert -m 1 commit_hash