Skip to content

Commit b4a97d4

Browse files
authored
chore: add changelog howto in CONTRIBUTING (#672)
1 parent b43d6bd commit b4a97d4

File tree

2 files changed

+36
-1
lines changed

2 files changed

+36
-1
lines changed

.github/workflows/changelog-verification.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,6 @@ jobs:
1919
if: ${{ failure() }}
2020
run: |
2121
echo "::error ::No new/updated changelog entry found in /.changes directory. Please either:"
22-
echo "::error ::* Add a changelog entry (in most cases) –or–"
22+
echo "::error ::* Add a changelog entry (see CONTRIBUTING.md for instructions) –or–"
2323
echo "::error ::* Add the 'no-changelog' label to this PR (in rare cases not warranting a changelog entry)"
2424
exit 1

CONTRIBUTING.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@ To send us a pull request, please:
4747

4848
1. Fork the repository.
4949
2. Modify the source; please focus on the specific change you are contributing. If you also reformat all the code, it will be hard for us to focus on your change.
50+
* Ensure your modifications are accompanied by a [changelog entry](#Changelog) where necessary.
5051
3. Ensure local tests pass.
5152
4. Commit to your fork using clear commit messages.
5253
5. Send us a pull request, answering any default questions in the pull request interface.
@@ -55,6 +56,40 @@ To send us a pull request, please:
5556
GitHub provides additional document on [forking a repository](https://help.github.com/articles/fork-a-repo/) and
5657
[creating a pull request](https://help.github.com/articles/creating-a-pull-request/).
5758

59+
### Changelog
60+
Merges to this repository must include one or more changelog entries which describe the modifications made.
61+
62+
Entries are placed in the top-level `.changes/` directory. An entry is a file containing a JSON object with the
63+
following fields:
64+
65+
| Field name | Type | Required | Enum | Description |
66+
|---------------|------------|----------|----------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
67+
| `id` | `string` | yes | | A unique identifier for this entry. We recommend you generate a UUID for this field. |
68+
| `type` | `string` | yes | `bugfix`, `feature`, `documentation`, `misc` | The type of change being made. |
69+
| `description` | `string` | yes | | A description of the change being made. |
70+
| `issues` | `string[]` | no | | A list of references to any related issues in the relevant repositories. A reference can be specified in several ways:<ul><li>The issue number, if local to this repository (eg. `#12345`)</li><li>A fully-qualified issue ID (eg.`awslabs/smithy-kotlin#12345`)</li><li>A fully-qualified URL (eg. `https://issuetracker.com/12345`)</li></ul> |
71+
| `module` | `string` | no | | The area of the code affected by your changes. If unsure, leave this value unset. |
72+
73+
The filename of an entry is arbitrary. We recommend `<id>.json`, where `<id>` corresponds to the `id` field of the entry
74+
itself.
75+
76+
Entries in the `.changes/` directory are automatically rolled into the main `CHANGELOG.md` file in every release.
77+
78+
If you believe that your modifications do not warrant a changelog entry, you can add the `no-changelog` label to your
79+
pull request. The label will suppress the CI that blocks merging in the absence of a changelog, though the reviewer(s)
80+
of your request may disagree and ask that you add one anyway.
81+
82+
#### Example
83+
```json
84+
{
85+
"id": "263ea6ab-4b75-41a8-9c37-821c30d7b9e5",
86+
"type": "feature",
87+
"description": "Add multiplatform support for URL parsing.",
88+
"issues": [
89+
"awslabs/aws-sdk-kotlin#12345"
90+
]
91+
}
92+
```
5893

5994
## Finding contributions to work on
6095
Looking at the existing issues is a great way to find something to contribute on. As our projects, by default, use the default GitHub issue labels ((enhancement/bug/duplicate/help wanted/invalid/question/wontfix), looking at any ['help wanted'](https://github.com/aws-samples/aws-sdk-kotlin/labels/help%20wanted) issues is a great place to start.

0 commit comments

Comments
 (0)