From af7bd46ac400ef670dd708e1633ec3d1add2b1db Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 23 Dec 2024 14:17:38 +0000 Subject: [PATCH] [AUTO]Update CJS script Files changed: M dist/index.js M src/index.js --- dist/index.js | 9 ++------- src/index.js | 5 +++-- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/dist/index.js b/dist/index.js index 320ecb6..46b35df 100644 --- a/dist/index.js +++ b/dist/index.js @@ -27331,20 +27331,15 @@ async function run() { const workspaceNotEmpty = (await fs.readdir(workspacePath)).length > 0; if (workspaceExists && workspaceNotEmpty) { - // Escaping quotes in the options array const escapedOptions = options.map((str) => - str.replace(/(["'])/g, "\\$1"), + str.replace(/(["'])/g, "$1"), ); - // Debugging output to check the escaped options - console.log("Escaped Options:", escapedOptions); - execFile( `${process.env["ProgramFiles(x86)"]}\\Inno Setup 6\\iscc.exe`, [...escapedOptions, `${workspacePath}\\${path}`], (execError, stdout, stderr) => { - console.log("stdout:", stdout); - console.log("stderr:", stderr); + console.log(stdout, stderr); if (execError) { core.setFailed(`Execution failed with error: ${stderr}`); process.exit(execError.code || 1); diff --git a/src/index.js b/src/index.js index e76c763..7ee9ddc 100644 --- a/src/index.js +++ b/src/index.js @@ -23,8 +23,9 @@ async function run() { const workspaceNotEmpty = (await fs.readdir(workspacePath)).length > 0; if (workspaceExists && workspaceNotEmpty) { - - const escapedOptions = options.map(str => str.replace(/(["'])/g, '$1')); + const escapedOptions = options.map((str) => + str.replace(/(["'])/g, "$1"), + ); execFile( `${process.env["ProgramFiles(x86)"]}\\Inno Setup 6\\iscc.exe`,