Compare commits

...

1 Commits

Author SHA1 Message Date
Paolo Tranquilli 3ce0b4fd9e Remove unsupported flag 2023-09-07 18:06:57 +02:00
2 changed files with 16 additions and 28 deletions
Generated
+1 -4
View File
@@ -282,9 +282,6 @@ async function getCodeQLForCmd(cmd, checkVersion) {
(await util.codeQlVersionAbove(this, exports.CODEQL_VERSION_INIT_WITH_QLCONFIG))) { (await util.codeQlVersionAbove(this, exports.CODEQL_VERSION_INIT_WITH_QLCONFIG))) {
extraArgs.push(`--qlconfig-file=${qlconfigFile}`); extraArgs.push(`--qlconfig-file=${qlconfigFile}`);
} }
if (await util.codeQlVersionAbove(this, exports.CODEQL_VERSION_LANGUAGE_BASELINE_CONFIG)) {
extraArgs.push("--calculate-language-specific-baseline");
}
await runTool(cmd, [ await runTool(cmd, [
"database", "database",
"init", "init",
@@ -963,4 +960,4 @@ function isNoCodeFoundError(e) {
async function isDiagnosticsExportInvalidSarifFixed(codeql) { async function isDiagnosticsExportInvalidSarifFixed(codeql) {
return await util.codeQlVersionAbove(codeql, exports.CODEQL_VERSION_DIAGNOSTICS_EXPORT_FIXED); return await util.codeQlVersionAbove(codeql, exports.CODEQL_VERSION_DIAGNOSTICS_EXPORT_FIXED);
} }
//# sourceMappingURL=codeql.js.map //# sourceMappingURL=codeql.js.map
+15 -24
View File
@@ -57,7 +57,7 @@ export class CommandInvocationError extends Error {
.join(" "); .join(" ");
super( super(
`Encountered a fatal error while running "${prettyCommand}". ` + `Encountered a fatal error while running "${prettyCommand}". ` +
`Exit code was ${exitCode} and error was: ${error.trim()}`, `Exit code was ${exitCode} and error was: ${error.trim()}`,
); );
} }
} }
@@ -580,15 +580,6 @@ export async function getCodeQLForCmd(
extraArgs.push(`--qlconfig-file=${qlconfigFile}`); extraArgs.push(`--qlconfig-file=${qlconfigFile}`);
} }
if (
await util.codeQlVersionAbove(
this,
CODEQL_VERSION_LANGUAGE_BASELINE_CONFIG,
)
) {
extraArgs.push("--calculate-language-specific-baseline");
}
await runTool( await runTool(
cmd, cmd,
[ [
@@ -686,7 +677,7 @@ export async function getCodeQLForCmd(
) { ) {
throw new util.UserError( throw new util.UserError(
"No code found during the build. Please see: " + "No code found during the build. Please see: " +
"https://gh.io/troubleshooting-code-scanning/no-source-code-seen-during-build", "https://gh.io/troubleshooting-code-scanning/no-source-code-seen-during-build",
); );
} }
throw e; throw e;
@@ -1085,15 +1076,15 @@ export async function getCodeQLForCmd(
) { ) {
core.warning( core.warning(
`CodeQL CLI version ${await codeql.getVersion()} was deprecated on 2023-06-20 alongside ` + `CodeQL CLI version ${await codeql.getVersion()} was deprecated on 2023-06-20 alongside ` +
"GitHub Enterprise Server 3.5 and will not be supported by the next release of the " + "GitHub Enterprise Server 3.5 and will not be supported by the next release of the " +
`CodeQL Action. Please update to CodeQL CLI version ${CODEQL_NEXT_MINIMUM_VERSION} or ` + `CodeQL Action. Please update to CodeQL CLI version ${CODEQL_NEXT_MINIMUM_VERSION} or ` +
"later. For instance, if you have specified a custom version of the CLI using the " + "later. For instance, if you have specified a custom version of the CLI using the " +
"'tools' input to the 'init' Action, you can remove this input to use the default " + "'tools' input to the 'init' Action, you can remove this input to use the default " +
"version.\n\n" + "version.\n\n" +
"Alternatively, if you want to continue using CodeQL CLI version " + "Alternatively, if you want to continue using CodeQL CLI version " +
`${await codeql.getVersion()}, you can replace 'github/codeql-action/*@v2' by ` + `${await codeql.getVersion()}, you can replace 'github/codeql-action/*@v2' by ` +
"'github/codeql-action/*@v2.20.4' in your code scanning workflow to ensure you continue " + "'github/codeql-action/*@v2.20.4' in your code scanning workflow to ensure you continue " +
"using this version of the CodeQL Action.", "using this version of the CodeQL Action.",
); );
core.exportVariable(EnvVar.SUPPRESS_DEPRECATED_SOON_WARNING, "true"); core.exportVariable(EnvVar.SUPPRESS_DEPRECATED_SOON_WARNING, "true");
} }
@@ -1153,10 +1144,10 @@ export function getExtraOptions(
paths.length === 0 paths.length === 0
? asExtraOptions(options, pathInfo) ? asExtraOptions(options, pathInfo)
: getExtraOptions( : getExtraOptions(
options?.[paths[0]], options?.[paths[0]],
paths?.slice(1), paths?.slice(1),
pathInfo.concat(paths[0]), pathInfo.concat(paths[0]),
); );
return all.concat(specific); return all.concat(specific);
} }