Fork me on GitHub

Git: Apply some commit(s) changes without creating a new commit

Use cherry-pick -n

For example: I want to apply a temporary commit's (e9a8822) changes into my master branch:

git co master
git cherry-pick -n e9a8822

You can also return to a commit while keeping all the changes that have been done afterward using reset --soft.

git reset --soft e9a8822
Tags: git