mirror of
https://github.com/github/codeql-action.git
synced 2026-01-04 05:30:16 +08:00
Remove local environment running
This is a functionality that never worked perfectly and hasn't been used for a while. This allows developers to run the action on their local machine, but the run was always flaky and never 100% mirrored what was happening on the actions runner.
This commit is contained in:
12
src/util.ts
12
src/util.ts
@@ -6,7 +6,6 @@ import { Readable } from "stream";
|
||||
import * as core from "@actions/core";
|
||||
import * as semver from "semver";
|
||||
|
||||
import { prepareLocalRunEnvironment } from "./actions-util";
|
||||
import { getApiClient, GitHubApiDetails } from "./api-client";
|
||||
import * as apiCompatibility from "./api-compatibility.json";
|
||||
import { Config } from "./config-utils";
|
||||
@@ -36,16 +35,6 @@ export function getExtraOptionsEnvParam(): object {
|
||||
}
|
||||
}
|
||||
|
||||
export function isLocalRun(): boolean {
|
||||
return (
|
||||
!!process.env.CODEQL_LOCAL_RUN &&
|
||||
process.env.CODEQL_LOCAL_RUN !== "false" &&
|
||||
process.env.CODEQL_LOCAL_RUN !== "0" &&
|
||||
// local runs only allowed for actions
|
||||
isActions()
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the array of all the tool names contained in the given sarif contents.
|
||||
*
|
||||
@@ -444,7 +433,6 @@ export function initializeEnvironment(mode: Mode, version: string) {
|
||||
core.exportVariable(EnvVar.FEATURE_MULTI_LANGUAGE, "true");
|
||||
core.exportVariable(EnvVar.FEATURE_SANDWICH, "true");
|
||||
|
||||
prepareLocalRunEnvironment();
|
||||
} else {
|
||||
process.env[EnvVar.RUN_MODE] = mode;
|
||||
process.env[EnvVar.VERSION] = version;
|
||||
|
||||
Reference in New Issue
Block a user