mirror of
https://github.com/github/codeql-action.git
synced 2026-04-27 01:08:46 +00:00
Return OfflineFeatures for CCR
This commit is contained in:
Generated
+9
-1
@@ -103247,6 +103247,10 @@ function isSelfHostedRunner() {
|
||||
function isDynamicWorkflow() {
|
||||
return getWorkflowEventName() === "dynamic";
|
||||
}
|
||||
var CCR_KEY_PREFIX = "dynamic/copilot-pull-request-reviewer";
|
||||
function isCCR() {
|
||||
return process.env["CODEQL_ACTION_ANALYSIS_KEY" /* ANALYSIS_KEY */]?.startsWith(CCR_KEY_PREFIX) || false;
|
||||
}
|
||||
function prettyPrintInvocation(cmd, args) {
|
||||
return [cmd, ...args].map((x) => x.includes(" ") ? `'${x}'` : x).join(" ");
|
||||
}
|
||||
@@ -104349,7 +104353,11 @@ function supportsFeatureFlags(githubVariant) {
|
||||
return githubVariant === "GitHub.com" /* DOTCOM */ || githubVariant === "GitHub Enterprise Cloud with data residency" /* GHEC_DR */;
|
||||
}
|
||||
function initFeatures(gitHubVersion, repositoryNwo, tempDir, logger) {
|
||||
return new Features(gitHubVersion, repositoryNwo, tempDir, logger);
|
||||
if (isCCR()) {
|
||||
return new OfflineFeatures(logger);
|
||||
} else {
|
||||
return new Features(gitHubVersion, repositoryNwo, tempDir, logger);
|
||||
}
|
||||
}
|
||||
|
||||
// src/init.ts
|
||||
|
||||
Reference in New Issue
Block a user