How do you stash only specific files or include untracked files when stashing?
Last updated
git stash push <paths>stashes only the listed files (add-mfor a message), and-plets you pick individual hunks.Untracked files are skipped by default. Use
-u(--include-untracked) to include them.-a(--all) also stashes files ignored by.gitignore.
- https://git-scm.com/docs/git-stash
- https://git-scm.com/book/en/v2/Git-Tools-Stashing-and-Cleaning
- https://dev.to/mrsaynothing/git-stash-a-single-file-without-losing-the-rest-4jcn
- https://betterstack.com/community/questions/git-stahs-specific-file/
- https://www.geeksforgeeks.org/git/how-to-stash-an-untracked-file-in-git/