You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
ggshield secret scan path does not honor the content of .gitignore files. When running it at the root of a git checkout, this often causes it to scan files it should not scan, since they are not part of the repository content.
Describe the solution you'd like
secret scan path should support a --honor-gitignore or --ignore-vcs option to honor .gitignore files and related files (.git/info/exclude, $HOME/.config/git/ignore).
Regarding naming: --honor-gitignore is more explicit I think, but verbose. --ignore-vcs is used by other tools such as fd and ripgrep.
Additional context
ggshield low-level code already knows how to honor .gitignore files (including .git/info/exclude and $HOME/.config/git/ignore). We "just" need to expose the setting to the CLI.
The text was updated successfully, but these errors were encountered:
agateau-gg
changed the title
add an option to make secret scan path honor .gitignore files
Add an option to make secret scan path honor .gitignore files
Nov 17, 2023
Is your feature request related to a problem? Please describe.
ggshield secret scan path
does not honor the content of .gitignore files. When running it at the root of a git checkout, this often causes it to scan files it should not scan, since they are not part of the repository content.Describe the solution you'd like
secret scan path
should support a--honor-gitignore
or--ignore-vcs
option to honor.gitignore
files and related files (.git/info/exclude
,$HOME/.config/git/ignore
).Regarding naming:
--honor-gitignore
is more explicit I think, but verbose.--ignore-vcs
is used by other tools such asfd
andripgrep
.Additional context
ggshield low-level code already knows how to honor .gitignore files (including
.git/info/exclude
and$HOME/.config/git/ignore
). We "just" need to expose the setting to the CLI.The text was updated successfully, but these errors were encountered: