diff --git a/init/action.yml b/init/action.yml index 544eebdb2..c33e8a61e 100644 --- a/init/action.yml +++ b/init/action.yml @@ -115,7 +115,6 @@ inputs: (which for GitHub-hosted runners is 2 for Linux and Windows and 3 for macOS). This input also sets the number of threads that can later be used by the "analyze" action. required: false - default: "${{ env.CODEQL_THREADS }}" debug: description: >- Enable debugging mode. diff --git a/src/init-action.ts b/src/init-action.ts index b399d9dc5..e9c6cd0d3 100644 --- a/src/init-action.ts +++ b/src/init-action.ts @@ -547,7 +547,8 @@ async function run() { ); core.exportVariable( "CODEQL_THREADS", - getThreadsFlagValue(getOptionalInput("threads"), logger).toString(), + process.env["CODEQL_THREADS"] || + getThreadsFlagValue(getOptionalInput("threads"), logger).toString(), ); // Disable Kotlin extractor if feature flag set