-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Jan Starke
committed
Sep 8, 2023
1 parent
2814724
commit ef6a78b
Showing
2 changed files
with
30 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
use clap::Parser; | ||
use dfir_toolkit::common::HasVerboseFlag; | ||
use log::LevelFilter; | ||
|
||
|
||
#[derive(Parser, Debug)] | ||
#[clap(name=env!("CARGO_BIN_NAME"), author, version, about, long_about = None)] | ||
pub (crate) struct Cli { | ||
/// Name of the file to read | ||
#[clap()] | ||
pub (crate) polfile: String, | ||
|
||
#[clap(flatten)] | ||
pub (crate) verbose: clap_verbosity_flag::Verbosity, | ||
|
||
} | ||
|
||
impl HasVerboseFlag for Cli { | ||
fn log_level_filter(&self) -> LevelFilter { | ||
self.verbose.log_level_filter() | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters