Git stash

Sometimes, you may suddenly recall some emergency task in coding but you have already been working on your current work in a half way.

So you may want to save your work temporarily, but not commit the half-completed codes.

# git stash
# git checkout <another_branch>

 

When you come back to resume your previous work, you can simply do:

# git checkout <original_branch>
# git stash pop

 

That’s cool!