Skip to content

Commit

Permalink
modified step order
Browse files Browse the repository at this point in the history
MAybe this makes it work better?
  • Loading branch information
Bullrich committed Apr 8, 2024
1 parent a5f189a commit 625d4f1
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/review-trigger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ jobs:
github.event.action == 'synchronize' &&
github.event.sender.login == github.event.pull_request.user.login
run: |
echo "::error::Project needs to be reviewed again"
# We get the list of reviewers who approved the PR
REVIEWERS=$(gh api repos/${{ github.repository }}/pulls/${{ github.event.number }}/reviews \
--jq '{reviewers: [.[] | select(.state == "APPROVED") | .user.login]}')
Expand All @@ -40,18 +38,20 @@ jobs:
echo "commenters=COMMENTS" >> "$GITHUB_OUTPUT"
echo "Commeneters are $COMMENTS"
echo "::error::Project needs to be reviewed again"
# We request them to review again
echo $REVIEWERS | gh api --method POST repos/${{ github.repository }}/pulls/${{ github.event.number }}/requested_reviewers --input -
exit 1
env:
GH_TOKEN: ${{ github.token }}
- name: Comment requirements
if: failure() && ${{ contains(steps.fail.output.commenters, 'github-action') }}
run: |
echo "OH NO!"
env:
GH_TOKEN: ${{ github.token }}
# - name: Comment requirements
# if: failure() && ${{ contains(steps.fail.output.commenters, 'github-action') }}
# run: |
# echo "OH NO!"
# env:
# GH_TOKEN: ${{ github.token }}
- name: Get PR number
env:
PR_NUMBER: ${{ github.event.pull_request.number }}
Expand Down

0 comments on commit 625d4f1

Please sign in to comment.