- Empty commit
git commit --allow-empty -m 'fake commit to push'
git stash
git stash pop
- apply last stashed patchgit stash show
- it makes the list of files of the last stashed patchgit stash show -p
- it shows the diff of the last stashed patch
git reset --hard a1b2c3d4
git reset --hard HEAD~3
# Go back 3 commits. You will lose uncommitted work
git rebase -i HEAD~2
- merge the last 2 commits