forked from mirrors/kingfisher
Restored --version cli argument. Added a test for it
This commit is contained in:
parent
65de1b0290
commit
c6567ee04b
4 changed files with 19 additions and 3 deletions
|
|
@ -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
|
||||
|
|
|
|||
|
|
@ -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
|
||||
|
|
|
|||
|
|
@ -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)]
|
||||
|
|
|
|||
10
tests/cli.rs
10
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")));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue