diff --git a/src/discover/registry.rs b/src/discover/registry.rs index c3c52ed..c716470 100644 --- a/src/discover/registry.rs +++ b/src/discover/registry.rs @@ -288,7 +288,9 @@ const IGNORED_PREFIXES: &[&str] = &[ "case ", ]; -const IGNORED_EXACT: &[&str] = &["cd", "echo", "true", "false", "wait", "pwd", "bash", "sh", "fi", "done"]; +const IGNORED_EXACT: &[&str] = &[ + "cd", "echo", "true", "false", "wait", "pwd", "bash", "sh", "fi", "done", +]; lazy_static! { static ref REGEX_SET: RegexSet = RegexSet::new(PATTERNS).expect("invalid regex patterns"); diff --git a/src/go_cmd.rs b/src/go_cmd.rs index 278c0ce..42ff0cd 100644 --- a/src/go_cmd.rs +++ b/src/go_cmd.rs @@ -267,8 +267,7 @@ fn filter_go_test_json(output: &str) -> String { // Handle build-output/build-fail events (use ImportPath, no Package) match event.action.as_str() { "build-output" => { - if let (Some(import_path), Some(output_text)) = - (&event.import_path, &event.output) + if let (Some(import_path), Some(output_text)) = (&event.import_path, &event.output) { let text = output_text.trim_end().to_string(); if !text.is_empty() { diff --git a/src/runner.rs b/src/runner.rs index 6ae6599..afd77b8 100644 --- a/src/runner.rs +++ b/src/runner.rs @@ -58,7 +58,8 @@ pub fn run_err(command: &str, verbose: u8) -> Result<()> { } else { println!("{}", rtk); } - timer.track(command, "rtk run-err", &raw, &rtk); + let label = format!("rtk err {}", command); + timer.track(command, &label, &raw, &rtk); Ok(()) } @@ -99,7 +100,8 @@ pub fn run_test(command: &str, verbose: u8) -> Result<()> { } else { println!("{}", summary); } - timer.track(command, "rtk run-test", &raw, &summary); + let label = format!("rtk test {}", command); + timer.track(command, &label, &raw, &summary); Ok(()) }