|
1
|
on: |
|
2
|
pull_request: |
|
3
|
issues: |
|
4
|
name: Label PR with team |
|
5
|
permissions: |
|
6
|
contents: read |
|
7
|
pull-requests: write |
|
8
|
jobs: |
|
9
|
team-labeler: |
|
10
|
runs-on: ubuntu-latest |
|
11
|
# Skip PRs opened from forks (community contributions): they run with a |
|
12
|
# read-only GITHUB_TOKEN, so labeling fails, and team labels don't apply to |
|
13
|
# non-team authors anyway. Issues and same-repo (team) PRs still run. |
|
14
|
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository |
|
15
|
steps: |
|
16
|
- id: label-the-PR |
|
17
|
uses: actions/labeler@v5 |
|
18
|
- uses: JulienKode/team-labeler-action@v1.1.0 |
|
19
|
with: |
|
20
|
repo-token: "${{ secrets.GITHUB_TOKEN }}" |