Skip to content

Commit 4a5b493

Browse files
add future looking pull_request event to conditional
Scorecard currently has experimental support for the `pull_request` trigger, so we want to allow analysis to be run for it in the future. Signed-off-by: Spencer Schrock <sschrock@google.com>
1 parent 41e00af commit 4a5b493

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

code-scanning/scorecard.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ jobs:
2121
analysis:
2222
name: Scorecard analysis
2323
runs-on: ubuntu-latest
24-
# This action only works when run from the default branch
25-
if: github.event.repository.default_branch == github.ref_name
24+
# `publish_results: true` only works when run from the default branch. conditional can be removed if disabled.
25+
if: github.event.repository.default_branch == github.ref_name || github.event_name == 'pull_request'
2626
permissions:
2727
# Needed to upload the results to code-scanning dashboard.
2828
security-events: write

0 commit comments

Comments
 (0)