From d5bf9176670f2dd0b8c63a0fa4ad3a4a0474ac48 Mon Sep 17 00:00:00 2001 From: Keegan Campbell Date: Fri, 17 Nov 2023 11:17:00 -1000 Subject: [PATCH] Reduce diff --- dist/index.js | 4 ++-- index.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dist/index.js b/dist/index.js index 83f5caf9..2888fe8d 100644 --- a/dist/index.js +++ b/dist/index.js @@ -671,6 +671,7 @@ async function main() { }; core.debug(`Inputs: ${inspect(inputs)}`); + let [owner, repo] = process.env.GITHUB_REPOSITORY.split("/"); if (inputs.repository) { [owner, repo] = inputs.repository.split("/"); @@ -698,8 +699,6 @@ async function main() { if (inputs.pathToCdTo) { core.debug(`Changing directory to ${inputs.pathToCdTo}`); process.chdir(inputs.pathToCdTo); - console.log("running pwd"); - await runShellCommand(`pwd`); } const { hasChanges } = await getLocalChanges(inputs.path); @@ -710,6 +709,7 @@ async function main() { } else { core.info("No local changes"); } + core.setOutput("result", "unchanged"); process.exit(0); // there is currently no neutral exit code } diff --git a/index.js b/index.js index 7c33aa5b..b5250253 100644 --- a/index.js +++ b/index.js @@ -60,6 +60,7 @@ async function main() { }; core.debug(`Inputs: ${inspect(inputs)}`); + let [owner, repo] = process.env.GITHUB_REPOSITORY.split("/"); if (inputs.repository) { [owner, repo] = inputs.repository.split("/"); @@ -87,8 +88,6 @@ async function main() { if (inputs.pathToCdTo) { core.debug(`Changing directory to ${inputs.pathToCdTo}`); process.chdir(inputs.pathToCdTo); - console.log("running pwd"); - await runShellCommand(`pwd`); } const { hasChanges } = await getLocalChanges(inputs.path); @@ -99,6 +98,7 @@ async function main() { } else { core.info("No local changes"); } + core.setOutput("result", "unchanged"); process.exit(0); // there is currently no neutral exit code }