diff --git a/index.js b/index.js index e2445ba..35672ed 100644 --- a/index.js +++ b/index.js @@ -109,7 +109,7 @@ async function commitChanges(filesToCommit, commitMessage, git, branch) { await git.push("repo", branch); }); } else { - console.log("No changes to make"); + core.info("No changes to make"); } } @@ -133,6 +133,7 @@ async function run() { } if (commitAndPushChanges !== false) { + core.info("Setting Commit and Push to True"); commitAndPushChanges = true; } @@ -175,12 +176,13 @@ async function run() { // Log Changed files core.info("Files to commit: " + JSON.stringify(filesToCommit)); - if (commitAndPushChanges) { + if (commitAndPushChanges === true) { // Generate DIff and commit changes + core.info("Attempting Committing Changes."); await commitChanges(filesToCommit, commitMessage, git, branch); } } catch (error) { - console.log(error); + core.error(error); throw error; } }