Skip to content

[infra] Automation: Add release PR reviewers #2

[infra] Automation: Add release PR reviewers

[infra] Automation: Add release PR reviewers #2

name: Add reviewers to release PRs
on:
pull_request_target:
branches: ['master', 'next']
pull_request:
types: ['labeled']
permissions: {}
jobs:
add-reviewers:
if: ${{ github.event.label.name == 'release' }}
# Tests that label is added on the PR
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- id: get-members
uses: garnertb/get-team-members@v1
with:
org: mui
team_slug: x
role: maintainer
token: ${{ secrets.GITHUB_TOKEN }}
# assign reviewers
- run: "gh pr edit ${{ github.event.pull_request.number }} --add-reviewer ${{ steps.get-members.outputs.members }}"
shell: bash