Skip to content

Commit

Permalink
fix:semgrep - Disable collect metrics and fix log message (#968)
Browse files Browse the repository at this point in the history
In this commit I change semgrep tool to not collect information
of the your analysis. And I found an error in Log when semgrep
fails was showing the tool name wrong.

Signed-off-by: wilian <wilian.silva@zup.com.br>
  • Loading branch information
wiliansilvazup authored Feb 3, 2022
1 parent 886da4c commit f14f910
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion internal/services/formatters/generic/semgrep/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@ package semgrep

const CMD = `
{{WORK_DIR}}
semgrep --config=p/r2c-ci -q --json .
semgrep --disable-metrics --config=p/r2c-ci -q --json .
`
2 changes: 1 addition & 1 deletion internal/services/formatters/generic/semgrep/formatter.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (f *Formatter) StartAnalysis(projectSubPath string) {
}

output, err := f.startSemgrep(projectSubPath)
f.SetAnalysisError(err, tools.SecurityCodeScan, output, projectSubPath)
f.SetAnalysisError(err, tools.Semgrep, output, projectSubPath)
f.LogDebugWithReplace(messages.MsgDebugToolFinishAnalysis, tools.Semgrep, languages.Generic)
}

Expand Down

0 comments on commit f14f910

Please sign in to comment.