Git stash: "Cannot apply to a dirty working tree, please stage your changes"

Viewed 54660

I am trying to apply changes I stashed earlier with git stash pop and get the message:

Cannot apply to a dirty working tree, please stage your changes

Any suggestion on how to deal with that?

12 Answers

That's my take on the problem that worked for me without problems.

git stash show | patch -p1

Of course it partially resorts to a command outside the git commands family.

Related