Skip to content

Commit

Permalink
feat: Use tracing feature from clap-verbosity-flag (#12)
Browse files Browse the repository at this point in the history
  • Loading branch information
pavelzw authored Feb 27, 2025
1 parent e950343 commit e35a861
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,9 @@ tracing-subscriber = { version = "0.3.19", features = [
"default",
"env-filter",
] }
tracing-log = "0.2.0"
anyhow = "1.*"
clap = { version = "4.5.23", features = ["derive", "string"] }
clap-verbosity-flag = "3.0.2"
clap-verbosity-flag = { version = "3.0.2", features = ["tracing"] }
futures = "0.3.31"
indicatif = "0.17.8"
rattler = { version = "0.28.0", default-features = false }
Expand Down
3 changes: 1 addition & 2 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ use clap::Parser;
use clap_verbosity_flag::Verbosity;

use anyhow::Result;
use tracing_log::AsTrace;

/* -------------------------------------------- CLI -------------------------------------------- */

Expand Down Expand Up @@ -36,7 +35,7 @@ async fn main() -> Result<()> {
let cli = Cli::parse();

tracing_subscriber::FmtSubscriber::builder()
.with_max_level(cli.verbose.log_level_filter().as_trace())
.with_max_level(cli.verbose)
.init();

tracing::debug!("Starting pixi-inject CLI");
Expand Down

0 comments on commit e35a861

Please sign in to comment.