From 2280bee6e2faa14b6f061bd956ca0985bf2ad855 Mon Sep 17 00:00:00 2001 From: Mick Grove Date: Wed, 2 Jul 2025 15:13:31 -0700 Subject: [PATCH] JSON output was missing committer name and email --- CHANGELOG.md | 2 ++ Cargo.toml | 4 ++-- src/reporter.rs | 4 ++++ tests/smoke_update.rs | 5 +++++ 4 files changed, 13 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f7710fa..026c26d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ All notable changes to this project will be documented in this file. +## [1.19.0] +- JSON output was missing committer name and email ## [1.18.1] - Restored --version cli argument diff --git a/Cargo.toml b/Cargo.toml index 98fb1fd..779f8a9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,7 +10,7 @@ publish = false [package] name = "kingfisher" -version = "1.18.1" +version = "1.19.0" edition.workspace = true rust-version.workspace = true license.workspace = true @@ -159,7 +159,7 @@ rand = "0.9.1" percent-encoding = "2.3.1" trust-dns-resolver = { version = "0.23.2", default-features = false, features = ["tokio-runtime"] } atty = "0.2.14" -self_update = { version = "0.42.0", default-features = false, features = ["rustls"] } +self_update = { version = "0.42.0", default-features = false, features = ["rustls", "archive-tar", "archive-zip", "compression-flate2"] } semver = "1.0.26" [dependencies.tikv-jemallocator] diff --git a/src/reporter.rs b/src/reporter.rs index a720c9e..93583fa 100644 --- a/src/reporter.rs +++ b/src/reporter.rs @@ -80,6 +80,10 @@ impl DetailsReporter { "id": cmd.commit_id.to_string(), "url": format!("{}/commit/{}", repo_url, cmd.commit_id), "date": atime, + "committer": { + "name": String::from_utf8_lossy(&cmd.committer_name), + "email": String::from_utf8_lossy(&cmd.committer_email), + }, // "author": { // "name": String::from_utf8_lossy(&cmd.author_name), // "email": String::from_utf8_lossy(&cmd.author_email), diff --git a/tests/smoke_update.rs b/tests/smoke_update.rs index 8224d42..929eea7 100644 --- a/tests/smoke_update.rs +++ b/tests/smoke_update.rs @@ -5,6 +5,11 @@ use wiremock::{ Mock, MockServer, ResponseTemplate, }; +use flate2::{write::GzEncoder, Compression}; +use tar::Builder; +use tempfile::tempdir; +use std::fs::{self, File}; + #[tokio::test] async fn no_update_when_flag_set() { let args = GlobalArgs { no_update_check: true, ..Default::default() };