Skip to content

Commit

Permalink
Enforce proper labeling of pull requests (#733)
Browse files Browse the repository at this point in the history
This patch adds a GitHub Actions workflow which checks that pull requests
have proper labels assigned to them.

In combination with pull request #731, this ensures that pull requests
are always properly listed  in the release notes.
  • Loading branch information
lkiesow committed Jun 7, 2023
1 parent 6128865 commit 9cb5a30
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/check-label.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# This workflow runs on any change made to a pull-request and aims to verify
# that the correct label is present.

name: Check proper lable usage

on:
pull_request_target:
types: [opened, labeled, unlabeled, synchronize]

jobs:
labels:
runs-on: ubuntu-latest
steps:
# Ensure that one of the required labels is present and none of the undesired is absent
# See https://github.com/jesusvasquez333/verify-pr-label-action
- name: Verify PR label action
uses: jesusvasquez333/[email protected]
with:
github-token: '${{ secrets.GITHUB_TOKEN }}'
valid-labels: 'type:accessibility, type:bug, type:dependencies, type:documentation, type:enhancement, type:feature, type:infrastructure, type:mobile, type:security, type:tests, type:usability, type:visual-clarity'
invalid-labels: 'status:duplicate, status:conflicts, status:wontfix, status:backlog, status:feedback-required, status:needs-testing, status:user-story'
pull-request-number: '${{ github.event.pull_request.number }}'
disable-reviews: true

0 comments on commit 9cb5a30

Please sign in to comment.