Skip to content

Conversation

@zaidmonis
Copy link

Fixes #78
This pull request enhances the PathScanner class to support .gitignore file handling, ensuring that files and directories ignored by Git are also excluded from scanning. It also introduces a corresponding unit test to verify this behavior.

Gitignore support in resource scanning

  • Updated PathScanner to load and parse a .gitignore file from the project root using JGit's IgnoreNode, and modified the scanning logic to skip resources ignored by Git rules.

Testing

  • Added a new unit test ignoresResourcesListedInGitignore in PathScannerTest to verify that files listed in .gitignore are excluded from scan results.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Ignore all resources in .gitignore when scanning

1 participant