diff --git a/CHANGELOG.md b/CHANGELOG.md index c9b4701..f7710fa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to this project will be documented in this file. + +## [1.18.1] +- Restored --version cli argument +- Added test for the argument + ## [1.18.0] - Added rules for DeepSeek, xAI - Removed branding diff --git a/Cargo.toml b/Cargo.toml index 6a90c97..98fb1fd 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,7 +10,7 @@ publish = false [package] name = "kingfisher" -version = "1.18.0" +version = "1.18.1" edition.workspace = true rust-version.workspace = true license.workspace = true diff --git a/NOTICE b/NOTICE index da698e9..62c3bf2 100644 --- a/NOTICE +++ b/NOTICE @@ -28,8 +28,4 @@ Additional notices for Kingfisher Copyright 2025 MongoDB, Inc. https://www.mongodb.com -Kingfisher is a fork of Nosey Parker that adds (at the time of writing): - - Live secret validation via cloud-provider APIs - - Extra detection rules and tree-sitter parsing - - Native GitLab integration and Windows x64 support Source repository: https://github.com/mongodb/kingfisher diff --git a/src/cli/global.rs b/src/cli/global.rs index 37e0bbb..e8001a9 100644 --- a/src/cli/global.rs +++ b/src/cli/global.rs @@ -10,10 +10,11 @@ use crate::cli::commands::{ github::GitHubArgs, gitlab::GitLabArgs, rules::RulesArgs, scan::ScanArgs, }; + #[deny(missing_docs)] #[derive(Parser, Debug)] - -/// Kingfisher — Detect and validate secrets across files and full Git history +#[command(version = env!("CARGO_PKG_VERSION"))] +/// Kingfisher - Detect and validate secrets across files and full Git history pub struct CommandLineArgs { /// The command to execute #[command(subcommand)] diff --git a/tests/cli.rs b/tests/cli.rs index f1af007..0486b73 100644 --- a/tests/cli.rs +++ b/tests/cli.rs @@ -22,4 +22,14 @@ mod test { .success() .stdout(contains("kingfisher.aws.").and(contains("pattern"))); } + + #[test] + fn cli_version_flag() { + Command::cargo_bin("kingfisher") + .unwrap() + .arg("--version") + .assert() + .success() + .stdout(contains(env!("CARGO_PKG_VERSION"))); + } }