node-trucker
node-trucker copied to clipboard
Support multiple gitignores
When there are gitignores in both /project-root/.gitignore
and /project-root/subfolder/.gitignore
only the first .gitignore
found, walking the tree up from the base (pwd) is used to determine excluded files.
This results in two bugs:
- When running from
/project-root/
, only the higher-level.gitignore
is parsed, so the files in/project-root/subfolder
are not properly filtered - Conversely, when running from
/project-root/subfolder
, the higher-level ignores in/project-root
are not read
Also global gitignores are not supported. If a git project is detected, we may wish to just use git ls-files
and leave this to git.