Git stash

Stash is not a very common but useful function, something like “Pause” button for your local changes.
For example, you’re working on some stuff in dev branch and you need to get branch clean (as it was in the last commit).
Of course you can commit your stuff and switch to previous commit, but lots of commits might complicate team work.
This is where the Stash would be helpful – it will save uncommitted changes internally and I’ll be able to come back to them later with git stash pop command:

Screen Shot 2016-06-22 at 15.35.57

Keep in mind that during git stash pop some conflicts might appear, but they can be resolved just as usual.
If you ask me – I do prefer to commit changes frequently to my working branch but I still use stash from time to time.

VCS table of contents