Share CodeQL bundle platform definitions

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
Henry Mercer
2026-09-16 17:28:00 +01:00
parent 2d47caf123
commit dfb9bf52c9
7 changed files with 124 additions and 100 deletions

View File

@@ -17,6 +17,7 @@ import {
isRunningLocalAction,
} from "./actions-util";
import * as api from "./api-client";
import { getBundlePlatform } from "./bundle-platform";
import * as defaults from "./defaults.json";
import {
addNoLanguageDiagnostic,
@@ -78,20 +79,6 @@ function getCodeQLBundleExtension(
}
}
/** Returns the platform component of the CodeQL bundle name for the current platform. */
export function getBundlePlatform(): string | undefined {
switch (process.platform) {
case "win32":
return "win64";
case "linux":
return process.arch === "arm64" ? "linux-arm64" : "linux64";
case "darwin":
return "osx64";
default:
return undefined;
}
}
/**
* Returns the name of the CodeQL bundle asset to download.
*