The problem seems to be that by default the stash
command will not include untracked files.
To include untracked files, use the -u
(--include-untracked
) flag:
git stash -u
If the –include-untracked option is used, all untracked files are
also stashed and then cleaned up with git clean, leaving the working
directory in a very clean state.