Enable github labeler, use for api-change

Belated followup to #11829: use github labeler workflow[1] to
auto-add 'kind/api-change' label to PRs in which files are
touched under pkg/api

 [1] https://github.com/actions/labeler

Signed-off-by: Ed Santiago <santiago@redhat.com>
This commit is contained in:
Ed Santiago
2022-09-13 07:33:13 -06:00
parent 51b5d30b10
commit 885bc4742d
2 changed files with 19 additions and 0 deletions

4
.github/labeler.yml vendored Normal file
View File

@ -0,0 +1,4 @@
# Add labels based on file paths in PR
# https://github.com/actions/labeler
kind/api-change:
- pkg/api/**/*

15
.github/workflows/labeler.yml vendored Normal file
View File

@ -0,0 +1,15 @@
# https://github.com/actions/labeler
name: "Pull Request Labeler"
on:
- pull_request_target
jobs:
triage:
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@v4
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"