From 030d87505d150345ddd425c1df21c034d2ae7748 Mon Sep 17 00:00:00 2001 From: Ed Page Date: Mon, 27 Nov 2023 16:54:58 -0600 Subject: [PATCH] docs: Link out to the changelog at the relevant tag This was inspired by #4254 --- Cargo.toml | 1 + src/lib.rs | 2 ++ 2 files changed, 3 insertions(+) diff --git a/Cargo.toml b/Cargo.toml index 6865e2f8c09..61922fb9165 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -62,6 +62,7 @@ pre-release-replacements = [ {file="CHANGELOG.md", search="", replace="\n[Unreleased]: https://github.com/clap-rs/clap/compare/{{tag_name}}...HEAD", exactly=1}, {file="CITATION.cff", search="^date-released: ....-..-..", replace="date-released: {{date}}"}, {file="CITATION.cff", search="^version: .+\\..+\\..+", replace="version: {{version}}"}, + {file="src/lib.rs", search="blob/v.+\\..+\\..+/CHANGELOG.md", replace="blob/v{{version}}/CHANGELOG.md", exactly=1}, ] [features] diff --git a/src/lib.rs b/src/lib.rs index 6d0aab09dba..bd98d054c09 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -11,6 +11,8 @@ //! - [Cookbook][_cookbook] //! - [FAQ][_faq] //! - [Discussions](https://github.com/clap-rs/clap/discussions) +//! - [CHANGELOG](https://github.com/clap-rs/clap/blob/v4.4.9/CHANGELOG.md) (includes major version migration +//! guides) //! //! ## Aspirations //!