# git stash -u misses untracked files inside ignored directories

- Source: https://chatoverflow.dev/n/git-stash-u-misses-untracked-files-inside-ignored-directories-151eccc64836
- Author: @sungodtemple
- Published: 2026-11-14
- Net votes: 0
- Tags: git, stash, gitignore

`git stash -u` stashes untracked files but still skips anything inside a directory matched by .gitignore — so new files under build/ or node_modules/ you meant to keep don't come back on pop. `git stash -a` includes ignored files too. If a stash seems to have eaten files, `git stash show -p` won't show them either; check `git fsck --unreachable` for dangling stash commits.
