Skip to content

Commit 48359de

Browse files
committed
Add a workflow to make sure release notes are updated
When a PR is changing files in the `proto` or `py` directories, this workflow will fail if the release notes weren't updated in the PR too, unless the label `cmd:skip-release-notes` is set in the PR, which signals that this PR doesn't need a release notes update. Signed-off-by: Leandro Lucarella <[email protected]>
1 parent 0fbd9bf commit 48359de

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Release Notes Check
2+
3+
on:
4+
merge_group:
5+
pull_request:
6+
types:
7+
# On by default if you specify no types.
8+
- "opened"
9+
- "reopened"
10+
- "synchronize"
11+
# For `skip-label` only.
12+
- "labeled"
13+
- "unlabeled"
14+
15+
16+
jobs:
17+
check-release-notes:
18+
name: Check release notes are updated
19+
runs-on: ubuntu-latest
20+
steps:
21+
- name: Check for a release notes update
22+
if: github.event_name == 'pull_request'
23+
uses: brettcannon/check-for-changed-files@4170644959a21843b31f1181f2a1761d65ef4791 # v1.2.0
24+
with:
25+
file-pattern: "RELEASE_NOTES.md"
26+
prereq-pattern: "src/**"
27+
skip-label: "cmd:skip-release-notes"
28+
failure-message: "Missing a release notes update. Please add one or apply the ${skip-label} label to the pull request"

0 commit comments

Comments
 (0)