@@ -266,6 +266,7 @@ var analyzeCmd = &cobra.Command{
266266 }
267267 defer os .RemoveAll (tmpDir )
268268
269+ << << << < HEAD
269270 var sarifOutputs []string
270271 for toolName := range toolsToRun {
271272 log .Printf ("Running %s...\n " , toolName )
@@ -303,6 +304,24 @@ var analyzeCmd = &cobra.Command{
303304 log .Printf ("Running %s...\n " , toolName )
304305 runTool (workDirectory , toolName , args , outputFile )
305306 }
307+ == == == =
308+ switch toolToAnalyze {
309+ case "eslint" :
310+ runEslintAnalysis (workDirectory , args , autoFix , outputFile , outputFormat )
311+ case "trivy" :
312+ runTrivyAnalysis (workDirectory , args , outputFile , outputFormat )
313+ case "pmd" :
314+ runPmdAnalysis (workDirectory , args , outputFile , outputFormat )
315+ case "pylint" :
316+ runPylintAnalysis (workDirectory , args , outputFile , outputFormat )
317+ case "dartanalyzer" :
318+ runDartAnalyzer (workDirectory , args , outputFile , outputFormat )
319+ case "" :
320+ log .Fatal ("You need to specify a tool to run analysis with, e.g., '--tool eslint'" )
321+ default :
322+ log .Fatal ("Trying to run unsupported tool: " , toolToAnalyze )
323+ }
324+ >> >> >> > dad888420cc7f054236ede90ae794432e96d7fcf
306325 },
307326}
308327
0 commit comments