Add a workflow to auto-label new PRs with team:viewer.

When a PR appears on the QA board, QA wants to know whose team it came from.
So every PR on the viewer repo should be labeled with team:viewer.
master
Nat Goodspeed 2024-01-11 13:19:25 -05:00 committed by nat-goodspeed
parent 77395eddc9
commit f5d6af9cfc
1 changed files with 17 additions and 0 deletions

17
.github/workflows/label_pr.yaml vendored Normal file
View File

@ -0,0 +1,17 @@
name: Label PR with team:viewer when first opened
on:
pull_request:
types:
- opened
jobs:
label_pr:
runs-on: ubuntu-latest
permissions:
issues: write
steps:
- run: gh pr edit "$NUMBER" --add-label "$LABELS"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
NUMBER: ${{ github.event.pull_request.number }}
LABELS: "team:viewer"