Sometime you just want to to go back to how things were. You want to merge something, or run some command as it was before you were working on it. Luckily this is really easy with git stash. Just run:
and your workspace reverts to what it was the last time you committed (except for files not yet tracked by git). Want your changes back?
git stash apply
and you're back where you were, but the change is still in the stash.
git stash pop
applies your stashed changes, and removes from the stash as well, so everything is exactly as it was. (Thanks @mordhak for the clarification.)
In a sense it's like doing a temporary commit that you then roll back. But you don't have to write a commit messages or do anything complicated. It's just an easy way to get a blank slate, and fill it right back up.
There's more fancy stuff you can do with the stash as well. You can read more in the Git book