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
Copy file name to clipboardExpand all lines: README.md
+80-88Lines changed: 80 additions & 88 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -39,84 +39,40 @@ Generate Release Notes action is dedicated to enhance the quality and organizati
39
39
-**Python 3.11+**: Ensure you have Python 3.11 installed on your system.
40
40
41
41
## Inputs
42
-
### `GITHUB_TOKEN`
43
-
-**Description**: Your GitHub token for authentication. Store it as a secret and reference it in the workflow file as secrets.GITHUB_TOKEN.
44
-
-**Required**: Yes
45
-
46
-
### `tag-name`
47
-
-**Description**: The name of the tag for which you want to generate release notes. This should be the same as the tag name used in the release workflow.
48
-
-**Required**: Yes
49
-
50
-
### `from-tag-name`
51
-
-**Description**: The name of the tag from which you want to generate release notes.
52
-
-**Required**: No
53
-
-**Default**: ``
54
-
55
-
### `chapters`
56
-
-**Description**: An YAML array defining chapters and corresponding labels for categorization. Each chapter should have a title and a label matching your GitHub issues and PRs.
57
-
-**Required**: Yes
58
-
59
-
### `row-format-issue`
60
-
-**Description**: The format of the row for the issue in the release notes. The format can contain placeholders for the issue `number`, `title`, and issues `pull-requests`. The placeholders are case-sensitive.
61
-
-**Required**: No
62
-
-**Default**: `"{number} _{title}_ in {pull-requests}"`
63
-
64
-
### `row-format-pr`
65
-
-**Description**: The format of the row for the PR in the release notes. The format can contain placeholders for the PR `number`, and `title`. The placeholders are case-sensitive.
66
-
-**Required**: No
67
-
-**Default**: `"{number} _{title}_"`
68
-
69
-
### `row-format-link-pr`
70
-
-**Description**: If defined `true`, the PR row will begin with a `"PR: "` string. Otherwise, no prefix will be added.
71
-
-**Required**: No
72
-
-**Default**: true
73
-
74
-
### `duplicity-scope`
75
-
-**Description**: Set to `custom` to allow duplicity issue lines to be shown only in custom chapters. Options: `custom`, `service`, `both`, `none`.
76
-
-**Required**: No
77
-
-**Default**: `both`
78
-
79
-
### `duplicity-icon`
80
-
-**Description**: The icon used to indicate duplicity issue lines in the release notes. Icon will be placed at the beginning of the line.
81
-
-**Required**: No
82
-
-**Default**: `🔔`
83
-
84
-
### `published-at`
85
-
-**Description**: Set to true to enable the use of the `published-at` timestamp as the reference point for searching closed issues and PRs, instead of the `created-at` date of the latest release. If first release, repository creation date is used.
86
-
-**Required**: No
87
-
-**Default**: false
88
-
89
-
### `skip-release-notes-labels`
90
-
-**Description**: List labels used for detection if issues or pull requests are ignored in the Release Notes generation process. Example: `skip-release-notes, question`.
91
-
-**Required**: No
92
-
-**Default**: `skip-release-notes`
93
-
- Notes:
94
-
- If used on issue then Issue will be skipped during Release Notes generation.
95
-
- If used on PR with issue then on PR it will be ignored and PR will show as part of issue's release notes.
96
-
- If used on PR without issue then PR will be skipped during Release Notes generation.
97
-
98
-
### `verbose`
99
-
-**Description**: Set to true to enable verbose logging for detailed output during the action's execution.
100
-
-**Required**: No
101
-
-**Default**: false
102
-
-**Note**: If workflow run in debug regime, 'verbose' logging is activated.
103
-
104
-
### `release-notes-title`
105
-
-**Description**: The title of the release notes section in the PR description.
|`GITHUB_TOKEN`| Your GitHub token for authentication. Store it as a secret and reference it in the workflow file as secrets.GITHUB_TOKEN. | Yes ||
46
+
|`tag-name`| The name of the tag for which you want to generate release notes. This should be the same as the tag name used in the release workflow. | Yes ||
47
+
|`from-tag-name`| The name of the tag from which you want to generate release notes. | No | '' |
48
+
|`chapters`| An YAML array defining chapters and corresponding labels for categorization. Each chapter should have a title and a label matching your GitHub issues and PRs. | Yes ||
49
+
|`row-format-issue`| The format of the row for the issue in the release notes. The format can contain placeholders for the issue `number`, `title`, and issues `pull-requests`. The placeholders are case-sensitive. | No |`"{number} _{title}_ in {pull-requests}"`|
50
+
|`row-format-pr`| The format of the row for the PR in the release notes. The format can contain placeholders for the PR `number`, and `title`. The placeholders are case-sensitive. | No |`"{number} _{title}_"`|
51
+
|`row-format-link-pr`| If defined `true`, the PR row will begin with a `"PR: "` string. Otherwise, no prefix will be added. | No | true |
52
+
|`duplicity-scope`| Set to `custom` to allow duplicity issue lines to be shown only in custom chapters. Options: `custom`, `service`, `both`, `none`. | No |`both`|
53
+
|`duplicity-icon`| The icon used to indicate duplicity issue lines in the release notes. Icon will be placed at the beginning of the line. | No |`🔔`|
54
+
|`published-at`| Set to true to enable the use of the `published-at` timestamp as the reference point for searching closed issues and PRs, instead of the `created-at` date of the latest release. If first release, repository creation date is used. | No | false |
55
+
|`skip-release-notes-labels`| List labels used for detection if issues or pull requests are ignored in the Release Notes generation process. Example: `skip-release-notes, question`. | No |`skip-release-notes`|
56
+
|`verbose`| Set to true to enable verbose logging for detailed output during the action's execution. | No | false |
57
+
|`release-notes-title`| The title of the release notes section in the PR description. | No |`[Rr]elease [Nn]otes:`|
58
+
|`coderabbit-support-active`| Enable CodeRabbit support. If true, the action will use CodeRabbit to generate release notes. | No | false |
59
+
|`coderabbit-release-notes-title`| The title of the CodeRabbit summary in the PR body. Value supports regex. | No |`Summary by CodeRabbit`|
60
+
|`coderabbit-summary-ignore-groups`| List of "group names" to be ignored by release notes detection logic. Example: `Documentation, Tests, Chores, Bug Fixes`. | No | '' |
61
+
62
+
> **Notes**
63
+
> -`skip-release-notes-labels`
64
+
> - If used on issue then Issue will be skipped during Release Notes generation.
65
+
> - If used on PR with issue then on PR it will be ignored and PR will show as part of issue's release notes.
66
+
> - If used on PR without issue then PR will be skipped during Release Notes generation.
67
+
> -`verbose`
68
+
> - If workflow run in debug regime, 'verbose' logging is activated.
110
69
111
-
### `warnings`
112
-
-**Description**: Set to true to print service chapters in the release notes. These warnings identify issues without release notes, without user-defined labels, or without associated pull requests, and PRs without linked issues.
113
-
-**Required**: No
114
-
-**Default**: true (Service chapters are printed.)
70
+
### Feature controls
115
71
116
-
### `print-empty-chapters`
117
-
-**Description**: Set it to true to print chapters with no issues or PRs.
|`warnings`| Set to true to print service chapters in the release notes. These warnings identify issues without release notes, without user-defined labels, or without associated pull requests, and PRs without linked issues. | No | true (Service chapters are printed.) |
75
+
|`print-empty-chapters`| Set it to true to print chapters with no issues or PRs. | No | true (Empty chapters are printed.)|
120
76
121
77
## Outputs
122
78
The output of the action is a markdown string containing the release notes for the specified tag. This string can be used in subsequent steps to publish the release notes to a file, create a GitHub release, or send notifications.
@@ -154,7 +110,7 @@ Add the following step to your GitHub workflow (in example are used non-default
154
110
```yaml
155
111
- name: Generate Release Notes
156
112
id: release_notes_generator
157
-
uses: AbsaOSS/generate-release-notes@v0.2.0
113
+
uses: AbsaOSS/generate-release-notes@v0.7.0
158
114
env:
159
115
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
160
116
with:
@@ -173,38 +129,74 @@ Add the following step to your GitHub workflow (in example are used non-default
173
129
verbose: false
174
130
release-notes-title: '[Rr]elease Notes:'
175
131
132
+
coderabbit-support-active: true
133
+
coderabbit-release-notes-title: 'Summary by CodeRabbit'
This feature searches for release notes in the description of GitHub pull requests, making it easier for maintainers to track changes and updates.
184
-
- **Format:**
185
-
- The release notes section have to begin with the title `Release Notes:` (case-sensitive), followed by the release notes in bullet points. [Markdown formatting is supported](https://www.markdownguide.org/basic-syntax/#unordered-lists).
186
-
- If no release notes line is detected under the `Release Notes:` title, no release notes will be printed in the output.
143
+
144
+
This feature automatically extracts release notes from GitHub pull request descriptions to help maintainers track meaningful changes.
145
+
146
+
##### 🔍 How Detection Works
147
+
148
+
- The Action looks for a specific section in the PR body, defined by:
149
+
- `release-notes-title`: A regex pattern to match the release notes section header.
150
+
- `coderabbit-support-active`: Enables fallback support for CodeRabbit summaries.
151
+
- ✅ _Used only if no section matching `release-notes-title` is found._
152
+
153
+
##### 📏 Detection Rules
154
+
- The release notes section:
155
+
- Can be **anywhere in the PR body**
156
+
- Must begin with a header that matches either:
157
+
- `release-notes-title`
158
+
- or `coderabbit-release-notes-title` (when CodeRabbit support is active)
- Only the **first matching section** is extracted
161
+
- Is **optional** – the Action will still proceed even if no notes are found
162
+
- Will be **skipped silently** if the PR has a label listed in `skip-release-notes-labels`
163
+
164
+
> 🔕 If no valid section is found, the output Release Notes record will not contain any release notes.
165
+
187
166
- **Example:**
188
167
- Here are examples of how to structure the release notes:
189
-
```
190
-
Release Notes:
168
+
169
+
```markdown
170
+
## Release Notes:
191
171
- This update introduces a new caching mechanism that improves performance by 20%.
192
172
- The caching mechanism reduces database queries.
193
173
- Optimized for high-traffic scenarios.
194
174
- Includes support for distributed caching.
195
175
196
-
Release Notes:
176
+
## Release Notes:
197
177
* This update introduces a new caching mechanism that improves performance by 20%.
198
178
* Affected only specific edge cases.
199
179
200
-
Release Notes:
180
+
## Release Notes:
201
181
+ This update introduces a new caching mechanism that improves performance by 20%.
202
182
203
-
```
204
-
The extraction process supports all three types of bullet points: `-`, `*`, and `+`, and their combinations. (GitHub documentation do not recommend to mix them.)
183
+
## Summary by CodeRabbit
205
184
206
-
- **Best Practice:** Select one character from `-`, `*`, `+` for bullet points. The Markdown parser will automatically format them as a list.
207
-
- **Optional usage:** The release notes section is not mandatory for GH action to work.
185
+
- **New Features**
186
+
- Introduced a new feature.
187
+
188
+
- **Documentation**
189
+
- Added new descriptions.
190
+
191
+
- **Chores**
192
+
- Added configuration files for code style.
193
+
194
+
- **Tests**
195
+
- Introduced a complete test suite for all classes.
196
+
```
197
+
> The extraction process supports all three types of bullet points: `-`, `*`, and `+`, and their combinations. (GitHub documentation do not recommend to mix them.)
198
+
>
199
+
> **Best Practice:** Select one character from `-`, `*`, `+` for bullet points. The Markdown parser will automatically format them as a list.
208
200
209
201
#### Handling Multiple PRs
210
202
If an issue is linked to multiple PRs, the action fetches and aggregates contributions from all linked PRs.
Copy file name to clipboardExpand all lines: action.yml
+16-1Lines changed: 16 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -21,7 +21,7 @@ inputs:
21
21
description: 'The tag name of the release to generate notes for.'
22
22
required: true
23
23
chapters:
24
-
description: 'An string representation of YAML array defining chapters and corresponding labels for categorization. (Created by used "|".)'
24
+
description: 'A string representation of a YAML array defining chapters and corresponding labels for categorization. (Created by used "|".)'
25
25
required: false
26
26
default: ''
27
27
duplicity-scope:
@@ -60,6 +60,18 @@ inputs:
60
60
description: 'The title of the release notes section in the PR body. Value supports regex.'
61
61
required: false
62
62
default: '[Rr]elease [Nn]otes:'
63
+
coderabbit-support-active:
64
+
description: 'Enable CodeRabbit support. If true, the action will use CodeRabbit to generate release notes.'
65
+
required: false
66
+
default: 'false'
67
+
coderabbit-release-notes-title:
68
+
description: 'The title of the CodeRabbit summary in the PR body. Value supports regex.'
69
+
required: false
70
+
default: 'Summary by CodeRabbit'
71
+
coderabbit-summary-ignore-groups:
72
+
description: 'List of "group names" to be ignored by release notes detection logic.'
73
+
required: false
74
+
default: ''
63
75
row-format-issue:
64
76
description: 'Format of the issue row in the release notes. Available placeholders: {number}, {title}, {pull-requests}. Placeholders are case-insensitive.'
0 commit comments