From 2e421a9db04693c5a388d05c411cac0565da7047 Mon Sep 17 00:00:00 2001 From: gacallea <3269984+gacallea@users.noreply.github.com> Date: Fri, 9 Aug 2024 14:39:40 +0200 Subject: [PATCH] fix(changelog): new template Closes #22 Signed-off-by: gacallea <3269984+gacallea@users.noreply.github.com> --- CHANGELOG.md | 190 +++++++++++++++++++++++++---------------------- release-plz.toml | 70 +++++++++++++++++ 2 files changed, 171 insertions(+), 89 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 98120a1..10d141b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,153 +7,165 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] -## [0.2.11](https://github.com/gacallea/freesound-credits/compare/v0.2.10...v0.2.11) - 2024-08-08 +## [0.2.11](https://github.com/gacallea/freesound-credits/compare/v0.2.10..v0.2.11) -### Fixed -- single git tag and tag template +### ๐Ÿ› Bug Fixes -### Other -- binstall name var -- remove configs with default values +- Single git tag and tag template - ([aa1a051](https://github.com/gacallea/freesound-credits/commit/aa1a051824c405c06fb4677e9786f69a106d301a)) by gacallea -## [0.2.10](https://github.com/gacallea/freesound-credits/compare/v0.2.9...v0.2.10) - 2024-08-08 -### Fixed -- removed cliff altogether -- trying to switch to keep a changelog +### โš™๏ธ Miscellaneous Tasks -### Other -- empty the changelog +- Release v0.2.11 (#16) - ([4a56702](https://github.com/gacallea/freesound-credits/commit/4a56702d40e16615bfc053fbd2fd5d5d38c5c530)) by Andrea C -### Changed +- Release - ([8250e43](https://github.com/gacallea/freesound-credits/commit/8250e43dc0fefb786cd9326529b39fcb6db91e20)) by Andrea C -- Empty the changelog +- Improve release-plz config (#15) - ([b942acd](https://github.com/gacallea/freesound-credits/commit/b942acdc5595dad560017d1f3cafdf7ef88404ca)) by Andrea C -### Fixed +- Binstall name var - ([5d3977e](https://github.com/gacallea/freesound-credits/commit/5d3977e081cda505f0998356abaee716f5e297d4)) by gacallea -- Trying to switch to keep a changelog -- Trying to switch to keep a changelog (#12) +- Remove configs with default values - ([d5b0e9e](https://github.com/gacallea/freesound-credits/commit/d5b0e9eb7ff69b23b0ce12ceada8010532cf8134)) by gacallea -### Removed -- Removed cliff altogether +## [0.2.10](https://github.com/gacallea/freesound-credits/compare/v0.2.9..v0.2.10) -## [0.2.9] - 2024-08-08 +### ๐Ÿ› Bug Fixes -### Changed +- Remove git-cliff altogether (#13) - ([04de822](https://github.com/gacallea/freesound-credits/commit/04de8223600530d9c9488142e6accf29d4b5b5c5)) by Andrea C -- Release v0.2.9 (#11) +- Removed cliff altogether - ([4184fae](https://github.com/gacallea/freesound-credits/commit/4184fae2bb61b4bcae32df55404ac28fbb38cf9c)) by gacallea -### Fixed +- Trying to switch to keep a changelog (#12) - ([8847a1c](https://github.com/gacallea/freesound-credits/commit/8847a1c6ba5f564ac5043e330aee4096d0687651)) by Andrea C -- Fixing git cliff and changelog -- adding clarify for some license (#10) +- Trying to switch to keep a changelog - ([0c432c6](https://github.com/gacallea/freesound-credits/commit/0c432c6557f379ba11b04484656d3e84ab803284)) by gacallea -## [0.2.8] - 2024-08-08 -### Changed +### โš™๏ธ Miscellaneous Tasks -- Improvements for deny assist pre-commit and plz (#8) -- Release v0.2.8 (#9) +- Release v0.2.10 (#14) - ([f774cc5](https://github.com/gacallea/freesound-credits/commit/f774cc573c35fb67d29b4968b2444298541beb9b)) by Andrea C -## [0.2.7] - 2024-08-07 +- Release - ([1612ea1](https://github.com/gacallea/freesound-credits/commit/1612ea1b4b2f9948781091f8a80011ca54c0b3f5)) by Andrea C -### Added +- Empty the changelog - ([e675890](https://github.com/gacallea/freesound-credits/commit/e6758909169f591c42f22007b3d6d7c2fa0cf7f6)) by gacallea -- Adding emtpy chagelog file cause cargo-dist needs it. (#6) -### Changed +## [0.2.9](https://github.com/gacallea/freesound-credits/compare/v0.2.8..v0.2.9) -- Release v0.2.7 (#7) +### โš™๏ธ Miscellaneous Tasks -## [0.2.6] - 2024-08-07 +- Release v0.2.9 (#11) - ([64bef43](https://github.com/gacallea/freesound-credits/commit/64bef439a5b39a79f568fb3f87b80323b773ddea)) by Andrea C -### Added +- Fixing git cliff and changelog -- adding clarify for some license (#10) - ([fdbb853](https://github.com/gacallea/freesound-credits/commit/fdbb853dd1c2a73f10ae5d74e909f8a10a425423)) by Andrea C -- Added cargo-assist -### Changed +## [0.2.8](https://github.com/gacallea/freesound-credits/compare/v0.2.7..v0.2.8) -- Change dependabot to less aggressive schedule -- Path bump for ci improvements -- Path bump for ci improvements (#5) +### โš™๏ธ Miscellaneous Tasks -### Fixed +- Release v0.2.8 (#9) - ([2f4a74c](https://github.com/gacallea/freesound-credits/commit/2f4a74cc6b5ed7b19691b53b3dcb262353e008e6)) by Andrea C -- Fix cliff toml +- Improvements for deny assist pre-commit and plz (#8) - ([9c9b2a2](https://github.com/gacallea/freesound-credits/commit/9c9b2a212846aef18559dfda00550d9d901c2297)) by Andrea C -## [0.2.5] - 2024-08-07 -### Added +## [0.2.7](https://github.com/gacallea/freesound-credits/compare/v0.2.6..v0.2.7) -- Added homebrew -- Added musl +### โš™๏ธ Miscellaneous Tasks -### Changed +- Release v0.2.7 (#7) - ([4f17315](https://github.com/gacallea/freesound-credits/commit/4f1731527441bbede6a8fb91fe79b0e5070087c1)) by Andrea C -- Chronological order for badges -- Release (#4) +- Adding empty chagelog file cause cargo-dist needs it. (#6) - ([cc0e118](https://github.com/gacallea/freesound-credits/commit/cc0e118c1ffcf57af6d01456d6cfced3bbfbe83f)) by Andrea C -### Fixed -- Change run mode to upload +## [0.2.6](https://github.com/gacallea/freesound-credits/compare/v0.2.5..v0.2.6) -## [0.2.4] - 2024-08-07 +### โš™๏ธ Miscellaneous Tasks -### Changed +- Path bump for ci improvements (#5) - ([9181092](https://github.com/gacallea/freesound-credits/commit/9181092e24499ea91b23def027cbff0e5fc54a77)) by Andrea C -- Bump version to be on track with release-plz and crates +- Path bump for ci improvements - ([1be859a](https://github.com/gacallea/freesound-credits/commit/1be859a751359d4114fda6002cf33409d2597448)) by gacallea -### Fixed +- Fix cliff toml - ([f541cee](https://github.com/gacallea/freesound-credits/commit/f541cee669415cbfab3db0c198ec83148fb92690)) by gacallea -- Fix badge name for deployment +- Added cargo-assist - ([f0c0005](https://github.com/gacallea/freesound-credits/commit/f0c0005f42ae8d853c0ba2be72b1cee787ac9e0f)) by gacallea -## [0.2.3] - 2024-08-07 +- Change dependabot to less aggressive schedule - ([4cdcf61](https://github.com/gacallea/freesound-credits/commit/4cdcf612e6a11f66f5ec29981f92aa7027f387cb)) by gacallea -### Added -- Add/fix templates emojis +## [0.2.5](https://github.com/gacallea/freesound-credits/compare/v0.2.4..v0.2.5) -### Changed +### โ›ฐ๏ธ Features -- Automated CI/CD improved -- Release +- Added musl - ([f30644d](https://github.com/gacallea/freesound-credits/commit/f30644d070dd8b9472905b8da1c1b4d10283bb7c)) by gacallea -### Removed +- Added homebrew - ([d10839f](https://github.com/gacallea/freesound-credits/commit/d10839fe941eff7348926c2ac962b1da4f406410)) by gacallea -- Delete leftover script dir -## [0.2.2] - 2024-08-06 +### ๐Ÿ› Bug Fixes -### Changed +- Change run mode to upload - ([22d288c](https://github.com/gacallea/freesound-credits/commit/22d288c0fc6c4d74a8a83ef09f0b72b3642d2be7)) by gacallea -- Wow shiny new cargo-dist CI! -## [0.2.1] - 2024-08-06 +### โš™๏ธ Miscellaneous Tasks -### Fixed +- Release (#4) - ([f3dd43e](https://github.com/gacallea/freesound-credits/commit/f3dd43ec5a057f6eafe2fff01d8fc0f6e5f346f3)) by Andrea C -- Cargo version bump to fix install mistake +- Chronological order for badges - ([f1a4f68](https://github.com/gacallea/freesound-credits/commit/f1a4f68a2939cb6da3d581640f4739c88f559095)) by gacallea -## [0.2.0] - 2024-08-06 -### Added +## [0.2.4](https://github.com/gacallea/freesound-credits/compare/v0.2.3..v0.2.4) -- Adding DAW request template -- Add bug report template -- Add feature request template -- Adding contributing -- Added cc section and link to contribute +### โš™๏ธ Miscellaneous Tasks + +- Bump version to be on track with release-plz and crates - ([667af7f](https://github.com/gacallea/freesound-credits/commit/667af7f8979586f19653e6f69f142a9e0f174b33)) by gacallea + +- Fix badge name for deployment - ([ca31d63](https://github.com/gacallea/freesound-credits/commit/ca31d6337ac6812f16661c0bbd64e87b244d717b)) by gacallea + + +## [0.2.3](https://github.com/gacallea/freesound-credits/compare/v0.2.2..v0.2.3) + +### โš™๏ธ Miscellaneous Tasks + +- Release - ([f1896b3](https://github.com/gacallea/freesound-credits/commit/f1896b3e55b7f04a06f41c65af9f6e5c232f9956)) by Andrea C + +- Automated CI/CD improved - ([4c93d95](https://github.com/gacallea/freesound-credits/commit/4c93d9528189655a75d18b72d9192cbc67526a45)) by gacallea + +- Add/fix templates emojis - ([2dbe1d7](https://github.com/gacallea/freesound-credits/commit/2dbe1d746a34399b8d405568ea7391c781ed344c)) by gacallea + +- Delete leftover script dir - ([dedf877](https://github.com/gacallea/freesound-credits/commit/dedf8777f5f8a5209bd8b7ccb5c4b0a59d126304)) by gacallea + + +## [0.2.2](https://github.com/gacallea/freesound-credits/compare/v0.2.1..v0.2.2) + +### โš™๏ธ Miscellaneous Tasks + +- Wow shiny new cargo-dist CI! - ([8c76d66](https://github.com/gacallea/freesound-credits/commit/8c76d6682c05a8bd5200abb6d71d68941b19ec99)) by gacallea + + +## [0.2.1](https://github.com/gacallea/freesound-credits/compare/v0.2.0..v0.2.1) + +### ๐Ÿ› Bug Fixes + +- *(rewadme)* Cargo version bump to fix install mistake - ([c8ef775](https://github.com/gacallea/freesound-credits/commit/c8ef775ea3527920b2df8c9a78eb37421e76c421)) by gacallea + + +## [0.2.0](https://github.com/gacallea/freesound-credits/compare/v0.1.2..v0.2.0) + +### โ›ฐ๏ธ Features + +- *(issue)* Add feature request template - ([d10b225](https://github.com/gacallea/freesound-credits/commit/d10b225da2e5d2e287cf546c34e0b1cb7ad7d555)) by gacallea + +- *(issue)* Add bug report template - ([52ce50d](https://github.com/gacallea/freesound-credits/commit/52ce50d795dd765805a7b8683901b2b6f3ab89f7)) by gacallea + +- *(issue)* Adding DAW request template - ([05c5a36](https://github.com/gacallea/freesound-credits/commit/05c5a36eec0cfb98146e04d367679b57ae9c7910)) by gacallea + + +### ๐Ÿ› Bug Fixes + +- *(readme)* Added cc section and link to contribute - ([15145ee](https://github.com/gacallea/freesound-credits/commit/15145ee337c1d63e70a28add8caa7fbbb1ecac29)) by gacallea + + +### ๐Ÿ“š Documentation + +- *(contributing)* Adding contributing - ([f60b2e6](https://github.com/gacallea/freesound-credits/commit/f60b2e64844de98f61eea81a4967a4a06846baba)) by gacallea -[unreleased]: https://github.com///compare/v0.2.9..HEAD -[0.2.9]: https://github.com///compare/v0.2.8..v0.2.9 -[0.2.8]: https://github.com///compare/v0.2.7..v0.2.8 -[0.2.7]: https://github.com///compare/v0.2.6..v0.2.7 -[0.2.6]: https://github.com///compare/v0.2.5..v0.2.6 -[0.2.5]: https://github.com///compare/v0.2.4..v0.2.5 -[0.2.4]: https://github.com///compare/v0.2.3..v0.2.4 -[0.2.3]: https://github.com///compare/v0.2.2..v0.2.3 -[0.2.2]: https://github.com///compare/v0.2.1..v0.2.2 -[0.2.1]: https://github.com///compare/v0.2.0..v0.2.1 -[0.2.0]: https://github.com///compare/v0.1.2..v0.2.0 - diff --git a/release-plz.toml b/release-plz.toml index 3f40e31..74745cb 100644 --- a/release-plz.toml +++ b/release-plz.toml @@ -20,3 +20,73 @@ git_tag_name = "v{{ version }}" # Enable git tags for this package git_tag_enable = true + +[changelog] +header = """# Changelog + +All notable changes to this project will be documented in this file. + +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), +and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). + +## [Unreleased] + +""" + +body = """ +{%- macro remote_url() -%} + https://github.com/{{ remote.owner }}/{{ remote.repo }} +{%- endmacro -%} + +{% macro print_commit(commit) -%} + - {% if commit.scope %}*({{ commit.scope }})* {% endif %}\ + {% if commit.breaking %}[**breaking**] {% endif %}\ + + {{ commit.message | upper_first }} - \ + ([{{ commit.id | truncate(length=7, end="") }}]({{ self::remote_url() }}/commit/{{ commit.id }})) \ + by {{ commit.author.name }}\ +{% endmacro -%} + +{% if version %}\ + {% if previous.version %}\ + ## [{{ version | trim_start_matches(pat="v") }}]\ + ({{ self::remote_url() }}/compare/{{ previous.version }}..{{ version }}) + {% else %}\ + ## [{{ version | trim_start_matches(pat="v") }}] + {% endif %}\ +{% endif %}\ + +{% for group, commits in commits | group_by(attribute="group") %} + ### {{ group | striptags | trim | upper_first }} + {% for commit in commits + | filter(attribute="scope") + | sort(attribute="scope") %} + {{ self::print_commit(commit=commit) }} + {%- endfor -%} + {% raw %}\n{% endraw %}\ + {%- for commit in commits %} + {%- if not commit.scope -%} + {{ self::print_commit(commit=commit) }} + {% endif -%} + {% endfor -%} +{% endfor %}\n +""" + +commit_parsers = [ + { message = "^feat", group = "โ›ฐ๏ธ Features" }, + { message = "^fix", group = "๐Ÿ› Bug Fixes" }, + { message = "^doc", group = "๐Ÿ“š Documentation" }, + { message = "^perf", group = "โšก Performance" }, + { message = "^refactor\\(clippy\\)", skip = true }, + { message = "^refactor", group = "๐Ÿšœ Refactor" }, + { message = "^style", group = "๐ŸŽจ Styling" }, + { message = "^test", group = "๐Ÿงช Testing" }, + { message = "^chore\\(release\\): prepare for", skip = true }, + { message = "^chore\\(deps.*\\)", skip = true }, + { message = "^chore\\(pr\\)", skip = true }, + { message = "^chore\\(pull\\)", skip = true }, + { message = "^chore\\(npm\\).*yarn\\.lock", skip = true }, + { message = "^chore|^ci", group = "โš™๏ธ Miscellaneous Tasks" }, + { body = ".*security", group = "๐Ÿ›ก๏ธ Security" }, + { message = "^revert", group = "โ—€๏ธ Revert" }, +]