You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ci: add changelog workflow for automated release notes (#2317)
* docs: add changelog generation command for self-hosted Console
Custom Claude Code command that generates CHANGELOG.md entries by
comparing git tags. Scoped to self-hosted Redpanda Console — excludes
enterprise, ADP, AI Agents, AI Gateway, and cloud-only changes.
* ci: add GitHub Actions workflow to auto-generate changelog on tag push
Triggers on version tags (v*), runs Claude Code CLI to generate a
changelog entry, then opens a PR to master.
Copy file name to clipboardExpand all lines: .claude/commands/changelog/update.md
+26-25Lines changed: 26 additions & 25 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,17 +14,17 @@ Generate a succinct changelog by comparing a specified git tag with the previous
14
14
15
15
The version comparison logic:
16
16
- For patch versions (x.y.z): compare with x.y.(z-1) or x.y.(highest patch)
17
-
- Example: 2.8.9 compares with 2.8.7
17
+
- Example: 2.8.9 compares with 2.8.7
18
18
- For minor versions (x.y.0): compare with x.(y-1).(highest patch)
19
-
- Example: 3.2.0 compares with 3.1.3
19
+
- Example: 3.2.0 compares with 3.1.3
20
20
21
21
## Context
22
22
23
23
### User provided input for this command
24
24
25
25
The user provided the following additional input for this command (may be empty): $ARGUMENTS
26
26
27
-
**Usage**:
27
+
**Usage**:
28
28
-`changelog` - Generate changelog for the latest tag
29
29
-`changelog v2.8.9` - Generate changelog for a specific tag (v2.8.9)
30
30
-`changelog 2.8.9` - Generate changelog for a specific tag (accepts with or without 'v' prefix)
@@ -40,30 +40,31 @@ The user provided the following additional input for this command (may be empty)
40
40
41
41
### Changelog Generation Steps
42
42
43
-
1.**Determine Version Range**:
44
-
- If $ARGUMENTS is provided, use that as the target tag (add 'v' prefix if missing)
45
-
- If $ARGUMENTS is empty, get the latest tag from OSS repo
46
-
- Calculate the previous version based on semantic versioning rules
47
-
- Verify both tags exist
43
+
1.**Determine Version Range**:
44
+
- If $ARGUMENTS is provided, use that as the target tag (add 'v' prefix if missing)
45
+
- If $ARGUMENTS is empty, get the latest tag from OSS repo
46
+
- Calculate the previous version based on semantic versioning rules
47
+
- Verify both tags exist
48
48
49
49
2.**Check if Changelog Entry Already Exists**:
50
-
- Read CHANGELOG.md to see if the target version already has an entry
51
-
- If entry exists and there are commits since the tag, update "Master / Unreleased" section instead
52
-
- If no entry exists, proceed with creating a new version section
50
+
- Read CHANGELOG.md to see if the target version already has an entry
51
+
- If entry exists and there are commits since the tag, update "Master / Unreleased" section instead
52
+
- If no entry exists, proceed with creating a new version section
53
53
54
54
3.**Collect Changes from OSS Repository**:
55
-
- For existing entries: Get commits since the target tag: `git log --pretty=format:"%s" <target_tag>..HEAD`
56
-
- For new entries: Get commits between versions: `git log --pretty=format:"%s" <prev_tag>..<target_tag>`
57
-
- Filter and categorize commits into [BUGFIX], [IMPROVEMENT], [CHANGE], and [SECURITY]
58
-
- Select up to 10 most significant changes
59
-
-
55
+
- For existing entries: Get commits since the target tag: `git log --pretty=format:"%s" <target_tag>..HEAD`
56
+
- For new entries: Get commits between versions: `git log --pretty=format:"%s" <prev_tag>..<target_tag>`
57
+
- Filter and categorize commits into [BUGFIX], [IMPROVEMENT], [CHANGE], and [SECURITY]
58
+
- Select up to 10 most significant changes
59
+
-
60
60
61
61
4.**Update CHANGELOG.md**:
62
-
-**For existing entries**: Update "Master / Unreleased" section with new changes since the tag
63
-
-**For new patch releases**: Create new version section with changes from previous version
64
-
-**For new minor/major releases**: Create new version section using unreleased changes + new changes from previous version
65
-
- Limit to 10 most significant changes total across both repositories
66
-
- Format:
62
+
-**For existing entries**: Update "Master / Unreleased" section with new changes since the tag
63
+
-**For new patch releases**: Create new version section with changes from previous version
64
+
-**For new minor/major releases**: Create new version section using unreleased changes + new changes from previous version
65
+
- Limit to 10 most significant changes total across both repositories
66
+
- Use the tag's commit date for the version heading (get it via `git log -1 --format=%ai <target_tag>` and extract the YYYY-MM-DD)
67
+
- Format:
67
68
```
68
69
## [v<target_tag>] - YYYY-MM-DD
69
70
@@ -78,7 +79,7 @@ The user provided the following additional input for this command (may be empty)
78
79
**[IMPROVEMENT]** entries include:
79
80
- New features (feat:, feature:)
80
81
- Enhancements to existing functionality
81
-
- Performance improvements (perf:)
82
+
- Performance improvements (perf:)
82
83
- UI/UX improvements
83
84
- Documentation updates (docs:)
84
85
- Refactoring that adds value (refactor:)
@@ -105,9 +106,9 @@ The user provided the following additional input for this command (may be empty)
105
106
### Output Requirements
106
107
107
108
- Update the root `CHANGELOG.md` file appropriately based on the scenario:
108
-
-**Existing version entry**: Update "Master / Unreleased" section with changes since the tag
109
-
-**New patch version**: Create new version section with changes from previous version
110
-
-**New minor/major version**: Incorporate existing unreleased changes into the new version section
109
+
-**Existing version entry**: Update "Master / Unreleased" section with changes since the tag
110
+
-**New patch version**: Create new version section with changes from previous version
111
+
-**New minor/major version**: Incorporate existing unreleased changes into the new version section
111
112
- Limit to 10 most significant changes total across both repositories
112
113
- Display a summary of changes found
113
114
- Deduplicate closely related commits — if multiple commits address the same user-facing change (e.g. a fix and a follow-up perf improvement for the same feature), merge them into a single entry
0 commit comments