-
Notifications
You must be signed in to change notification settings - Fork 106
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ignored git folders/file are scanned while it shouldn't #280
Comments
They should already be ignored https://github.com/Bearer/curio/blob/6aa6f39169ed0a7684e86dfc3dd6249d5b7b0512/pkg/util/file/file.go#L75 with this |
I haven't been able to reproduce this locally. @gmontard Could you share the exact entry that you are adding to the |
For instance I have in my .gitignore And when I scan in debug mode you can see that it goes in each file of this directory still:
|
When possible, obtain the list of files to be scanned by means of `git ls-files`. This will automatically exclude files that are covered by the Git ignore file, so that we no longer need even visit these as we walk over the scanned directory tree. Closes #280
The content of the .git folder also gets scanned :-( |
When possible, obtain the list of files to be scanned by means of `git ls-files`. This will automatically exclude files that are covered by the Git ignore file, so that we no longer need even visit these as we walk over the scanned directory tree. Closes #280
When possible, obtain the list of files to be scanned by means of `git ls-files`. This will automatically exclude files that are covered by the Git ignore file, so that we no longer need even visit these as we walk over the scanned directory tree. Closes #280
When possible, obtain the list of files to be scanned by means of `git ls-files`. This will automatically exclude files that are covered by the Git ignore file, so that we no longer need even visit these as we walk over the scanned directory tree. Closes #280
* feat: Do not visit Git-ignored files When possible, obtain the list of files to be scanned by means of `git ls-files`. This will automatically exclude files that are covered by the Git ignore file, so that we no longer need even visit these as we walk over the scanned directory tree. Closes #280 * Update pkg/util/gitutil/gitutil.go Co-authored-by: Cédric Fabianski <cedric@bearer.sh> Co-authored-by: Cédric Fabianski <cedric@bearer.sh>
Folders/file present /gitignore are scanned.
Description
Folders and files referenced in a .gitignore shouldn't be scanned.
Expected Behavior
Avoid scanning files and folder present in a .gitignore
Steps to Reproduce
folder_to_ignore/test.txt
in a sample app and addfolder_to_ignore
folder in the app .gitignorefolder_to_ignore
folder.Context
It slows down the scan a lot.
Your Environment
The text was updated successfully, but these errors were encountered: