From 4891bd330f06f8bcf945f5e8f287fb4d22cc98d6 Mon Sep 17 00:00:00 2001 From: Seimizu Joukan Date: Mon, 22 Dec 2025 11:42:37 +0900 Subject: [PATCH] Add release note information to -i option ouput. --- Cargo.lock | 2 +- src/main.rs | 11 ++++++++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 7a3e679..ed35d25 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -422,7 +422,7 @@ dependencies = [ [[package]] name = "gh_release" -version = "0.2.3" +version = "0.2.4" dependencies = [ "chrono", "clap", diff --git a/src/main.rs b/src/main.rs index 8769b4c..518c508 100644 --- a/src/main.rs +++ b/src/main.rs @@ -35,6 +35,7 @@ struct Release { published_at: Option, draft: Option, prerelease: Option, + body: Option, assets: Vec, } @@ -125,7 +126,15 @@ impl Display for Release { .unwrap_or("-".to_string()) )?; - writeln!(f, "Assets:")?; + // Display release notes if available + if let Some(body) = &self.body { + if !body.is_empty() { + writeln!(f, "\nRelease Notes:")?; + writeln!(f, "{}", body)?; + } + } + + writeln!(f, "\nAssets:")?; for asset in &self.assets { writeln!( f,