Skip to content

Commit

Permalink
Adding an error message if the user is not running under a PR
Browse files Browse the repository at this point in the history
  • Loading branch information
gvegayon committed Oct 22, 2024
1 parent 01e2b0c commit 1ece256
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions post-artifact/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,13 @@ runs:

steps:

- name: Check this is a PR
if: ${{ github.event_name != 'pull_request' }}
run:
echo "This action must only run in pull requests."
echo "See https://github.com/CDCgov/cfa-actions for more information."
exit 1

# https://docs.github.com/en/rest/actions/artifacts?apiVersion=2022-11-28#list-workflow-run-artifacts
- name: "Get list of available artifacts and store as .json"
run: |
Expand Down

0 comments on commit 1ece256

Please sign in to comment.