From 3c983a2a11986ef641b8e010667a33cd4538c4c1 Mon Sep 17 00:00:00 2001 From: Kaspar Schleiser Date: Fri, 6 Oct 2023 13:09:57 +0200 Subject: [PATCH] chore: set up more cargo-release CHANGELOG.md automation --- CHANGELOG.md | 11 +++++++++-- Cargo.toml | 8 ++++++++ 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 19ee33de..e0f60808 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,9 @@ 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). -## [0.1.17] + + +## [Unreleased] - ReleaseDate ### Changed @@ -13,6 +15,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - fixed expression evaluation for tasks +### Internal + +- more CHANGELOG.md automation + ## [0.1.16] ### Changed @@ -185,7 +191,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [0.1.1] - 2021-01-07 -[0.1.17]: https://github.com/kaspar030/laze/compare/0.1.15...0.1.17 + +[Unreleased]: https://github.com/kaspar030/laze/compare/0.1.16...HEAD [0.1.16]: https://github.com/kaspar030/laze/compare/0.1.15...0.1.16 [0.1.15]: https://github.com/kaspar030/laze/compare/0.1.14...0.1.15 [0.1.14]: https://github.com/kaspar030/laze/compare/0.1.13...0.1.14 diff --git a/Cargo.toml b/Cargo.toml index d7a1604f..dbe2f33b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -51,3 +51,11 @@ codegen-units = 1 sign-commit = true sign-tag = true tag-name = "{{prefix}}{{version}}" + +pre-release-replacements = [ + {file="CHANGELOG.md", search="Unreleased", replace="{{version}}"}, + {file="CHANGELOG.md", search="\\.\\.\\.HEAD", replace="...{{tag_name}}", exactly=1}, + {file="CHANGELOG.md", search="ReleaseDate", replace="{{date}}"}, + {file="CHANGELOG.md", search="", replace="\n\n## [Unreleased] - ReleaseDate", exactly=1}, + {file="CHANGELOG.md", search="", replace="\n[Unreleased]: https://github.com/assert-rs/predicates-rs/compare/{{tag_name}}...HEAD", exactly=1}, +]