Skip to content

Commit ee22a70

Browse files
authored
chore(ci): add changelog.yml workflow (#28)
1 parent 5de96c3 commit ee22a70

File tree

3 files changed

+377
-42
lines changed

3 files changed

+377
-42
lines changed

.github/workflows/changelog.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: update-changelog
2+
on:
3+
push:
4+
branches:
5+
- main
6+
permissions:
7+
contents: write
8+
jobs:
9+
changelog:
10+
name: Update CHANGELOG
11+
runs-on: ubuntu-latest
12+
timeout-minutes: 15
13+
if: |
14+
!startsWith(github.event.head_commit.message, '[Release]') &&
15+
!startsWith(github.event.head_commit.message, 'chore(changelog): update CHANGELOG.md') &&
16+
github.event.head_commit.author.name != 'github-actions[bot]'
17+
steps:
18+
- uses: actions/checkout@v6
19+
with:
20+
fetch-depth: 0
21+
- uses: jdx/mise-action@v3
22+
with:
23+
experimental: true
24+
- name: Generate CHANGELOG.md
25+
env:
26+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27+
run: git cliff --config ./cliff.toml -o ./CHANGELOG.md
28+
- name: Check for CHANGELOG changes
29+
id: changelog-changes
30+
run: |
31+
if git diff --quiet CHANGELOG.md; then
32+
echo "No changes in CHANGELOG.md"
33+
echo "has-changes=false" >> $GITHUB_OUTPUT
34+
else
35+
echo "CHANGELOG.md has changes"
36+
echo "has-changes=true" >> $GITHUB_OUTPUT
37+
fi
38+
- name: Commit CHANGELOG
39+
uses: stefanzweifel/git-auto-commit-action@v7
40+
if: steps.changelog-changes.outputs.has-changes == 'true'
41+
with:
42+
commit_message: "chore(changelog): update CHANGELOG.md"
43+
commit_options: '--no-verify'
44+
file_pattern: CHANGELOG.md
45+
commit_user_name: github-actions[bot]
46+
commit_user_email: github-actions[bot]@users.noreply.github.com

CHANGELOG.md

Lines changed: 63 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,67 +1,88 @@
1-
# Change Log
1+
# Changelog
2+
23
All notable changes to this project will be documented in this file.
34

5+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7+
48
#### 1.x Releases
59
- `1.2.x` Releases - [1.2.0](#120)
6-
- `1.1.x` Releases - [1.1.0](#110) | [1.1.1](#111)
10+
- `1.1.x` Releases - [1.1.1](#111) | [1.1.0](#110)
711
- `1.0.x` Releases - [1.0.0](#100)
812

13+
---
14+
## [Unreleased]
15+
16+
### Uncategorized Changes
17+
- Add renovate.json
18+
- Contributed by [@renovate[bot]](https://github.com/renovate[bot]) in Pull Request [#23](https://github.com/space-code/package-template/pull/23).
19+
- Bump actions/checkout from 4 to 5
20+
- Contributed by [@dependabot[bot]](https://github.com/dependabot[bot]) in Pull Request [#20](https://github.com/space-code/package-template/pull/20).
21+
22+
### New Contributors
23+
* @renovate[bot] made their first contribution in [#23](https://github.com/space-code/package-template/pull/23)
24+
925
## [1.2.0](https://github.com/space-code/package-template/releases/tag/1.2.0)
10-
Released on 2025-04-20
1126

12-
## Added
13-
- Add the `Dependapot` action
14-
- Added in Pull Request [#15](https://github.com/space-code/package-template/pull/15).
27+
Released on 2025-04-20. All issues associated with this milestone can be found using this [filter](https://github.com/space-code/package-template/milestones?state=closed&q=1.2.0).
28+
29+
### Uncategorized Changes
30+
- Fix the replacement of Cookiecutter parameters
31+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#19](https://github.com/space-code/package-template/pull/19).
32+
- Update `deploy_docc.yml`
33+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#18](https://github.com/space-code/package-template/pull/18).
34+
- Bump actions/cache from 3 to 4
35+
- Contributed by [@dependabot[bot]](https://github.com/dependabot[bot]) in Pull Request [#17](https://github.com/space-code/package-template/pull/17).
36+
- Bump actions/checkout from 3 to 4
37+
- Contributed by [@dependabot[bot]](https://github.com/dependabot[bot]) in Pull Request [#16](https://github.com/space-code/package-template/pull/16).
38+
- Integrate `dependabot.yml`
39+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#15](https://github.com/space-code/package-template/pull/15).
40+
- Update the `post_gen_project` script
41+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#14](https://github.com/space-code/package-template/pull/14).
1542
- Add `DocC` deployment template
16-
- Added in Pull Request[#13](https://github.com/space-code/package-template/pull/13).
43+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#13](https://github.com/space-code/package-template/pull/13).
1744
- Add additional badges to `README.md`
18-
- Added in Pull Request [#12](https://github.com/space-code/package-template/pull/12).
45+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#12](https://github.com/space-code/package-template/pull/12).
1946
- Add files to comply with community standards
20-
- Added in Pull Request [#11](https://github.com/space-code/package-template/pull/11).
47+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#11](https://github.com/space-code/package-template/pull/11).
2148
- Update the GitHub Actions configuration
22-
- Added in Pull Request [#10](https://github.com/space-code/package-template/pull/10).
49+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#10](https://github.com/space-code/package-template/pull/10).
2350
- Add the Swift Package Index badges to `README.md`
24-
- Added in Pull Request [#9](https://github.com/space-code/package-template/pull/9).
25-
- Update the Ruby version from 2.7 to 3.1.4
26-
- Added in Pull Request [#8](https://github.com/space-code/package-template/pull/8).
51+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#9](https://github.com/space-code/package-template/pull/9).
52+
- Update the Ruby version from `2.7` to `3.1.4`
53+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#8](https://github.com/space-code/package-template/pull/8).
2754
- Implement typo checking
28-
- Added in Pull Request [#7](https://github.com/space-code/package-template/pull/7).
29-
30-
## Updated
31-
- Update the `deploy_docc.yml` action
32-
- Updated in Pull Request [#18](https://github.com/space-code/package-template/pull/18).
33-
- Update the `post_get_project` script
34-
- Updated in Pull Request [#14](https://github.com/space-code/package-template/pull/14).
55+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#7](https://github.com/space-code/package-template/pull/7).
3556

36-
## Fixed
37-
- Fix the replacement of Cookiecutter parameters.
38-
- Fixed in Pull Request [#19](https://github.com/space-code/package-template/pull/19).
57+
### New Contributors
58+
* @dependabot[bot] made their first contribution in [#17](https://github.com/space-code/package-template/pull/17)
3959

4060
## [1.1.1](https://github.com/space-code/package-template/releases/tag/1.1.1)
41-
Released on 2023-12-18
4261

43-
## Fixed
44-
- Implementing the handling of failed tests on GitHub Actions
45-
- Added in Pull Request [#6](https://github.com/space-code/package-template/pull/6).
62+
Released on 2023-12-18. All issues associated with this milestone can be found using this [filter](https://github.com/space-code/package-template/milestones?state=closed&q=1.1.1).
63+
64+
### Uncategorized Changes
65+
- Update the passed parameters in the `xcodebuild` command
66+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#6](https://github.com/space-code/package-template/pull/6).
4667

4768
## [1.1.0](https://github.com/space-code/package-template/releases/tag/1.1.0)
48-
Released on 2023-12-01
4969

50-
## Added
51-
- Update GitHub Actions configuration
52-
- Added in Pull Request [#4](https://github.com/space-code/package-template/pull/4).
70+
Released on 2023-12-01. All issues associated with this milestone can be found using this [filter](https://github.com/space-code/package-template/milestones?state=closed&q=1.1.0).
71+
72+
### Uncategorized Changes
73+
- Update `CHANGELOG.md`
74+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#5](https://github.com/space-code/package-template/pull/5).
75+
- Update GitHub Actions Configuration
76+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#4](https://github.com/space-code/package-template/pull/4).
77+
- Update `SwiftFormat` rules
78+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#3](https://github.com/space-code/package-template/pull/3).
5379
- Integrate `danger`
54-
- Added in Pull Request [#2](https://github.com/space-code/package-template/pull/2).
80+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#2](https://github.com/space-code/package-template/pull/2).
5581
- Add issues and pull request templates
56-
- Added in Pull Request [#1](https://github.com/space-code/package-template/pull/1).
57-
58-
## Fixed
59-
- Fix deprecated SwiftLint rules
60-
- Added in Pull Request [#3](https://github.com/space-code/package-template/pull/3).
82+
- Contributed by [@ns-vasilev](https://github.com/ns-vasilev) in Pull Request [#1](https://github.com/space-code/package-template/pull/1).
6183

62-
## [1.0.0](https://github.com/space-code/package-template/releases/tag/1.0.0)
63-
Released on 2023-10-12.
84+
[unreleased]: https://github.com/space-code/package-template/compare/1.2.0..HEAD
85+
[1.2.0]: https://github.com/space-code/package-template/compare/1.1.1..1.2.0
86+
[1.1.1]: https://github.com/space-code/package-template/compare/1.1.0..1.1.1
87+
[1.1.0]: https://github.com/space-code/package-template/compare/1.0.0..1.1.0
6488

65-
#### Added
66-
- Initial release of package-template.
67-
- Added by [Nikita Vasilev](https://github.com/nik3212).

0 commit comments

Comments
 (0)