Skip to content

Commit

Permalink
Enforce labels workflow (#260)
Browse files Browse the repository at this point in the history
  • Loading branch information
withinfocus authored Mar 18, 2024
1 parent beae919 commit 7519981
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/enforce-labels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
name: Enforce PR labels

on:
workflow_call:
pull_request:
types: [labeled, unlabeled, opened, reopened, synchronize]
jobs:
enforce-label:
if: ${{ contains(github.event.*.labels.*.name, 'hold') || contains(github.event.*.labels.*.name, 'needs-qa') }}
name: Enforce label
runs-on: ubuntu-22.04

steps:
- name: Check for label
run: |
echo "PRs with the hold or needs-qa labels cannot be merged"
echo "### :x: PRs with the hold or needs-qa labels cannot be merged" >> $GITHUB_STEP_SUMMARY
exit 1

0 comments on commit 7519981

Please sign in to comment.