mirror of
https://github.com/securego/gosec.git
synced 2024-12-24 11:35:52 +00:00
Exclude .git directory from scan (#485)
This commit is contained in:
parent
6202b38a44
commit
af699f6a62
1 changed files with 4 additions and 0 deletions
|
@ -249,6 +249,10 @@ func main() {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Fprintf(os.Stderr, "\nError: failed to exclude the %q directory from scan", "vendor")
|
fmt.Fprintf(os.Stderr, "\nError: failed to exclude the %q directory from scan", "vendor")
|
||||||
}
|
}
|
||||||
|
err = flag.Set("exclude-dir", ".git")
|
||||||
|
if err != nil {
|
||||||
|
fmt.Fprintf(os.Stderr, "\nError: failed to exclude the %q directory from scan", ".git")
|
||||||
|
}
|
||||||
|
|
||||||
// Parse command line arguments
|
// Parse command line arguments
|
||||||
flag.Parse()
|
flag.Parse()
|
||||||
|
|
Loading…
Reference in a new issue