Forward category input to codeql cli

This commit is contained in:
David Verdeguer 2021-05-03 19:41:53 +02:00
parent 519d0771c7
commit c93cbc943a
15 changed files with 33 additions and 17 deletions

5
lib/codeql.js generated
View file

@ -427,7 +427,7 @@ function getCodeQLForCmd(cmd) {
}).exec();
return JSON.parse(output);
},
async databaseAnalyze(databasePath, sarifFile, extraSearchPath, querySuite, memoryFlag, addSnippetsFlag, threadsFlag) {
async databaseAnalyze(databasePath, sarifFile, extraSearchPath, querySuite, memoryFlag, addSnippetsFlag, threadsFlag, automationDetailsId) {
const args = [
"database",
"analyze",
@ -444,6 +444,9 @@ function getCodeQLForCmd(cmd) {
if (extraSearchPath !== undefined) {
args.push("--search-path", extraSearchPath);
}
if (automationDetailsId !== undefined) {
args.push("--sarif-category", automationDetailsId);
}
args.push(querySuite);
await new toolrunner.ToolRunner(cmd, args).exec();
},