diff --git a/dist/pre.js b/dist/pre.js index 80afe6a..7997af1 100644 --- a/dist/pre.js +++ b/dist/pre.js @@ -24,20 +24,23 @@ const { getLogger, getInputs } = util.util; const logger = getLogger(); const inputs = getInputs(logger); + const context = util.github.context; logger.debug(() => "Running pre tachometer-reporter-action..."); logger.debug(() => "Report ID: " + JSON.stringify(inputs.reportId)); - logger.debug(() => "Context: " + JSON.stringify(util.github.context, null, 2)); + logger.debug(() => "Issue: " + JSON.stringify(context.issue, null, 2)); + logger.debug(() => "Repo: " + JSON.stringify(context.repo, null, 2)); + logger.debug(() => "Context: " + JSON.stringify(context, null, 2)); if (!inputs.reportId) { - return logger.info( + logger.info( 'No reportId provided. Skipping updating comment with "Running..." status.' ); + + return; } - const context = util.github.context; const octokit = util.github.getOctokit(token); - const report = await reportTachRunning(octokit, context, inputs, logger); logger.debug(() => "Report: " + JSON.stringify(report, null, 2)); diff --git a/src/actions/pre.js b/src/actions/pre.js index f9a07f3..7783bb2 100644 --- a/src/actions/pre.js +++ b/src/actions/pre.js @@ -8,20 +8,23 @@ const { getLogger, getInputs } = require("./util"); const logger = getLogger(); const inputs = getInputs(logger); + const context = github.context; logger.debug(() => "Running pre tachometer-reporter-action..."); logger.debug(() => "Report ID: " + JSON.stringify(inputs.reportId)); - logger.debug(() => "Context: " + JSON.stringify(github.context, null, 2)); + logger.debug(() => "Issue: " + JSON.stringify(context.issue, null, 2)); + logger.debug(() => "Repo: " + JSON.stringify(context.repo, null, 2)); + logger.debug(() => "Context: " + JSON.stringify(context, null, 2)); if (!inputs.reportId) { - return logger.info( + logger.info( 'No reportId provided. Skipping updating comment with "Running..." status.' ); + + return; } - const context = github.context; const octokit = github.getOctokit(token); - const report = await reportTachRunning(octokit, context, inputs, logger); logger.debug(() => "Report: " + JSON.stringify(report, null, 2));