Skip to content

Commit c7ed38c

Browse files
markushiclaude
andauthored
feat(ci): Notify linked issues on release (#5367)
Add a release workflow that comments on GitHub issues closed by PRs included in a published stable release. Also document that PR authors need to use GitHub closing keywords for linked issues to receive the release notification. Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 5bc94fc commit c7ed38c

2 files changed

Lines changed: 46 additions & 0 deletions

File tree

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: 'Automation: Notify issues for release'
2+
on:
3+
release:
4+
types:
5+
- published
6+
workflow_dispatch:
7+
inputs:
8+
version:
9+
description: Which version to notify issues for
10+
required: true
11+
12+
permissions:
13+
contents: read
14+
issues: write
15+
pull-requests: read
16+
17+
jobs:
18+
release-comment-issues:
19+
runs-on: ubuntu-24.04
20+
name: 'Notify issues'
21+
steps:
22+
- name: Get version
23+
id: get_version
24+
env:
25+
INPUTS_VERSION: ${{ github.event.inputs.version }}
26+
RELEASE_TAG_NAME: ${{ github.event.release.tag_name }}
27+
run: echo "version=${INPUTS_VERSION:-$RELEASE_TAG_NAME}" >> "$GITHUB_OUTPUT"
28+
29+
- name: Comment on linked issues that are mentioned in release
30+
if: |
31+
steps.get_version.outputs.version != ''
32+
&& !contains(steps.get_version.outputs.version, '-beta.')
33+
&& !contains(steps.get_version.outputs.version, '-alpha.')
34+
&& !contains(steps.get_version.outputs.version, '-rc.')
35+
36+
uses: getsentry/release-comment-issues-gh-action@v1
37+
with:
38+
github_token: ${{ secrets.GITHUB_TOKEN }}
39+
version: ${{ steps.get_version.outputs.version }}

CONTRIBUTING.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,13 @@ or
5757

5858
However, if your change did not intend to modify the public API, consider changing the method/property visibility or removing the change altogether.
5959

60+
# Linking issues
61+
62+
If a PR should notify a linked issue after release, use a GitHub closing keyword in the PR
63+
description, such as `Fixes #123`, `Closes #123`, or `Resolves #123`. Release notification
64+
automation only comments on issues GitHub recognizes as closed by the released PR; mentioning an
65+
issue without a closing keyword is not enough.
66+
6067
# CI
6168

6269
Build and tests are automatically run against branches and pull requests

0 commit comments

Comments
 (0)