Skip to content

Commit

Permalink
Support clap_verbosity_flag 3
Browse files Browse the repository at this point in the history
  • Loading branch information
joaander committed Dec 2, 2024
1 parent 5dc3886 commit 95cdcfa
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#![warn(clippy::pedantic)]

use clap::Parser;
use clap_verbosity_flag::log::LevelFilter;
use indicatif::{MultiProgress, ProgressDrawTarget};
use indicatif_log_bridge::LogWrapper;
use log::{error, info};
Expand Down Expand Up @@ -40,13 +41,13 @@ fn main_detail() -> Result<(), Box<dyn Error>> {
}

let log_level = match options.verbose.log_level_filter() {
clap_verbosity_flag::LevelFilter::Off => "off",
clap_verbosity_flag::LevelFilter::Error => "error",
clap_verbosity_flag::LevelFilter::Warn => "warn",
LevelFilter::Off => "off",
LevelFilter::Error => "error",
LevelFilter::Warn => "warn",

clap_verbosity_flag::LevelFilter::Info => "info",
clap_verbosity_flag::LevelFilter::Debug => "debug",
clap_verbosity_flag::LevelFilter::Trace => "trace",
LevelFilter::Info => "info",
LevelFilter::Debug => "debug",
LevelFilter::Trace => "trace",
};

let multi_progress = if options.global.no_progress {
Expand Down

0 comments on commit 95cdcfa

Please sign in to comment.