mirror of
https://github.com/github/codeql-action.git
synced 2026-04-02 01:32:17 +00:00
Replace all occurrences
This commit is contained in:
2
lib/runner.js
generated
2
lib/runner.js
generated
@@ -158,7 +158,7 @@ program
|
||||
const shEnvFile = path.join(config.tempDir, "codeql-env.sh");
|
||||
const shEnvFileContents = Object.entries(tracerConfig.env)
|
||||
// Some vars contain ${LIB} that we do not want to be expanded when executing this script
|
||||
.map(([key, value]) => `export ${key}="${value.replace("$", "\\$")}"`)
|
||||
.map(([key, value]) => `export ${key}="${value.replace(/\$/g, "\\$")}"`)
|
||||
.join("\n");
|
||||
fs.writeFileSync(shEnvFile, shEnvFileContents);
|
||||
logger.info(`\nCodeQL environment output to "${jsonEnvFile}" and "${shEnvFile}". ` +
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -231,7 +231,9 @@ program
|
||||
const shEnvFile = path.join(config.tempDir, "codeql-env.sh");
|
||||
const shEnvFileContents = Object.entries(tracerConfig.env)
|
||||
// Some vars contain ${LIB} that we do not want to be expanded when executing this script
|
||||
.map(([key, value]) => `export ${key}="${value.replace("$", "\\$")}"`)
|
||||
.map(
|
||||
([key, value]) => `export ${key}="${value.replace(/\$/g, "\\$")}"`
|
||||
)
|
||||
.join("\n");
|
||||
fs.writeFileSync(shEnvFile, shEnvFileContents);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user