Extending previous answers, I sometimes have a complex set of changes staged, but wish to commit a separate change first. For example, I might have spotted a bug or otherwise incorrect code that I'd like to fix ahead of my staged changes. One possible route to take is this:
first stash everything, but leave the staged changes intact
$ git stash save --keep-index [--include-untracked]
now stash the staged changes separately too
$ git stash save
make changes for fix; and test; commit them:
$ git add [--interactive] [--patch]
$ git commit -m"fix..."
now restore the previously staged changes:
$ git stash pop
resolve any conflicts, and note that if there were conflicts, git will have applied but not dropped that top stash entry.
(... Then commit the staged changes, and restore the stash of all the other changes, and continue ...)
man git stash
is much better. – Unapiedra Oct 4 '11 at 16:17