Allow overriding path of temporary files.

This commit is contained in:
Chris Gavin 2021-02-01 15:18:14 +00:00
parent 6408d72268
commit ed751ece83
No known key found for this signature in database
GPG key ID: 07F950B80C27E4DA
12 changed files with 22 additions and 15 deletions

5
lib/actions-util.js generated
View file

@ -51,6 +51,11 @@ function getRequiredEnvParam(paramName) {
return value;
}
exports.getRequiredEnvParam = getRequiredEnvParam;
function getTemporaryDirectory() {
const value = process.env["CODEQL_ACTION_TEMP"];
return value !== undefined ? value : getRequiredEnvParam("RUNNER_TEMP");
}
exports.getTemporaryDirectory = getTemporaryDirectory;
/**
* Ensures all required environment variables are set in the context of a local run.
*/