Move your work in progress to another branch
suggest changeIf you realize you are on the wrong branch and you have not created any commits yet, you can move that work to the correct branch with the stash:
git stash
git checkout correct-branch
git stash pop
git stash pop applies the latest stash and removes it from the stash list. To apply it and keep it in the list:
git stash apply
Found a mistake? Have a question or improvement idea?
Let me know.
Table Of Contents