Enable language specific baselines via feature flag

This commit is contained in:
Henry Mercer 2023-08-11 17:20:42 +01:00
parent 9a510d9b07
commit 8a7b2e9c9b
6 changed files with 45 additions and 3 deletions

6
lib/codeql.js generated
View file

@ -278,6 +278,12 @@ async function getCodeQLForCmd(cmd, checkVersion) {
(await util.codeQlVersionAbove(this, exports.CODEQL_VERSION_INIT_WITH_QLCONFIG))) {
extraArgs.push(`--qlconfig-file=${qlconfigFile}`);
}
if (await features.getValue(feature_flags_1.Feature.LanguageBaselineConfigEnabled, this)) {
extraArgs.push("--calculate-language-specific-baseline");
}
else if (await util.codeQlVersionAbove(this, feature_flags_1.CODEQL_VERSION_LANGUAGE_BASELINE_CONFIG)) {
extraArgs.push("--no-calculate-language-specific-baseline");
}
await runTool(cmd, [
"database",
"init",