Skip to content

Commit

Permalink
Chore: Add assign reviewers GHA (#958)
Browse files Browse the repository at this point in the history
  • Loading branch information
yaronya authored Sep 25, 2024
1 parent 4fb7d27 commit ee882b8
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/assign-reviewers.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Assign PR Reviewers

on:
issue_comment:
types: [created]

jobs:
assign-reviewers:
runs-on: ubuntu-latest
if: ${{ github.event.issue.pull_request != null && github.event.comment.body == '/review' }}
steps:
- name: Assign PR Reviewers
env:
GITHUB_TOKEN: ${{ secrets.ENV0_BOT_PAT }}
run: |
curl -X POST \
-H "Authorization: token $GITHUB_TOKEN" \
-H "Accept: application/vnd.github.v3+json" \
https://api.github.com/repos/${{ github.repository }}/pulls/${{ github.event.issue.number }}/requested_reviewers \
-d '{"team_reviewers":["env0-team"]}'

0 comments on commit ee882b8

Please sign in to comment.