how to cancel a git stash pop code example Example 1: git abort stash pop git apply --reverse Example 2: git stash pop abort git reset HEAD --hard