Skip to content
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

feat: added ignore pattern matching for filesystem plugin #97

Merged
merged 2 commits into from
Jun 21, 2023
Merged

feat: added ignore pattern matching for filesystem plugin #97

merged 2 commits into from
Jun 21, 2023

Conversation

SHA65536
Copy link
Contributor

@SHA65536 SHA65536 commented Jun 20, 2023

I added the --ignore flag to let the user add patterns for files to be ignored. A user may supply multiple patterns using this form: 2ms filesystem --path path --ignore "*foo" --ignore "bar*"

I did not add tests as I am unsure how you guys want to test the plugins, worth discussing how a plugin test should be written.

Awaiting your feedback, cheers.

Close #93

@SHA65536 SHA65536 changed the title added ignore pattern matching for filesystem plugin feat: added ignore pattern matching for filesystem plugin Jun 20, 2023
@SHA65536
Copy link
Contributor Author

this closes #93 btw

Copy link
Contributor

@baruchiro baruchiro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! (see my comment)

Thanks @SHA65536!

@jossef Please review. The question is if you accept this approach of --ignore "*foo" --ignore "bar*" or did you expected to load a file with patterns (like .gitignore)?

plugins/filesystem.go Show resolved Hide resolved
plugins/filesystem.go Outdated Show resolved Hide resolved
@baruchiro baruchiro requested a review from jossef June 20, 2023 11:23
@SHA65536
Copy link
Contributor Author

We can support both, with an option like --ignorefile ignorelist.txt.
What are your thoughts?

@kaplanlior
Copy link
Contributor

kaplanlior commented Jun 20, 2023

@SHA65536 Thanks for contributing.
Please also sign-off (git commit -s) on your future commits (with a real email... )

Copy link
Contributor

@baruchiro baruchiro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!! Good work!

GoodJobThumbsUpGIF

@kaplanlior Please complete it when it is ready in your condition.

@jossef jossef merged commit 67d27fe into Checkmarx:master Jun 21, 2023
@jossef
Copy link
Member

jossef commented Jun 21, 2023

10x lgtm

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

Successfully merging this pull request may close these issues.

filesystem plugin - option to exclude specific file path or patterns
4 participants