revert a commit from local branch code example Example: undo reset commit git git reflog //to get commitID git reset #commitID