How do you debug why a path is ignored?
IntermediateConceptCommits, branches and tags
Answer
Use git check-ignore -v which prints the exact file, line and pattern responsible. Remember precedence: later patterns override earlier ones, ! negates but cannot re-include a file whose parent directory is excluded, and a nested .gitignore applies to its subtree.
git check-ignore -v build/app.js
More on Commits, branches and tags
How do you write a good commit message?BeginnerWhat is the difference between `git add .`, `git add -A` and `git add -u`?BeginnerHow do you commit only part of the changes in a file?BeginnerHow do you change the last commit message or add a forgotten file?BeginnerWhat is the difference between `git switch`, `git restore` and `git checkout`?BeginnerWhat is the difference between lightweight and annotated tags?Beginner