Skip to content

Commit

Permalink
Log context
Browse files Browse the repository at this point in the history
  • Loading branch information
danieldeichfuss committed Jan 2, 2022
1 parent 738ce39 commit 1da4e7d
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
7 changes: 5 additions & 2 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

5 changes: 4 additions & 1 deletion src/get-status/get-status.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import * as core from '@actions/core'
import {ActionInput, ActionOutput} from '../types'
import {context} from '@actions/github'
import {fetchChecks} from '../fetch-checks'

export async function getStatus({
Expand All @@ -18,11 +19,13 @@ export async function getStatus({
}
}

const ignoredCheckRunNames = ['get-status', ...ignore]
const ignoredCheckRunNames = ['get-status', context.job, ...ignore]

core.info(`Number of check runs: ${checkRuns.length}`)
core.debug(`Current Job: ${context.job}`)
core.info(`Ignored checks: ${ignoredCheckRunNames.join(', ')}`)
core.debug(`Check Runs: ${JSON.stringify(checkRuns)}`)
core.debug(`Context: ${JSON.stringify(context)}`)

const previousCheckRuns = checkRuns.filter(
checkRun => !ignoredCheckRunNames.includes(checkRun.name)
Expand Down

0 comments on commit 1da4e7d

Please sign in to comment.