Skip to content

Commit

Permalink
review-bot: trigger only on review approvals (#2289)
Browse files Browse the repository at this point in the history
Moved the review event of review-bot to only be triggered in approvals.

Because we only update the required reviews when someone approves, this
will stop the bot from immediately requesting a new review when someone
comments or request changes as they should have been already notified in
the first batch.
  • Loading branch information
Bullrich authored Nov 13, 2023
1 parent f332d68 commit 8d26379
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/review-trigger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ on:

jobs:
trigger-review-bot:
if: github.event.pull_request.draft != true
# (It is not a draft) && (it is not a review || it is an approving review)
if: ${{ github.event.pull_request.draft != true && (github.event_name != 'pull_request_review' || (github.event.review && github.event.review.state == 'APPROVED')) }}
runs-on: ubuntu-latest
name: trigger review bot
steps:
Expand Down

0 comments on commit 8d26379

Please sign in to comment.