Why my untracked files in stash disappear when I amend the current commit?

Viewed 35

I just lost my works due to this problem. I working on something then I realized that I need to refactor the current commit before create a new commit for the current works. So I stash all of my current works with:

git stash -u

Then I start refactor the current commit. Once finished I amend the current commit with:

git commit --amend

Then I restore my stash with:

git stash pop

What I found is all changes have been restored EXCEPT untracked files. No any untracked files has been restored.

0 Answers
Related