Skip to content

Commit cd6fdee

Browse files
authored
Add workflow to require release labels on PRs (#4281)
1 parent ca7159d commit cd6fdee

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Requires PRs to have either 'release-notes' or 'no-release-notes' label
2+
# This ensures release notes are considered for every PR before merging.
3+
# The check is enforced via branch protection rules on develop.
4+
name: Require Release Label
5+
6+
on:
7+
pull_request:
8+
types: [opened, labeled, unlabeled, synchronize]
9+
10+
jobs:
11+
check-label:
12+
if: github.repository == 'zenml-io/zenml'
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Check for release label
16+
uses: mheap/github-action-required-labels@v5
17+
with:
18+
mode: exactly
19+
count: 1
20+
labels: "release-notes, no-release-notes"
21+
message: |
22+
This PR is missing a release label. Please add one of:
23+
- `release-notes` - if this PR has user-facing changes that should appear in the changelog
24+
- `no-release-notes` - if this is an internal change (refactoring, tests, CI, etc.)

0 commit comments

Comments
 (0)