From a21174e87ef6870c47934ecb80961c56fb7b6358 Mon Sep 17 00:00:00 2001 From: clubby789 Date: Tue, 12 Nov 2024 16:23:19 +0000 Subject: [PATCH] Print all args properly in final report --- src/main.rs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/main.rs b/src/main.rs index 5437208..720489e 100644 --- a/src/main.rs +++ b/src/main.rs @@ -695,10 +695,11 @@ fn print_final_report( eprintln!("Reproduce with:"); eprintln!("```bash"); eprint!("cargo bisect-rustc "); - for (index, arg) in env::args_os().enumerate() { - if index > 1 { - eprint!("{} ", arg.to_string_lossy()); - } + for arg in env::args_os() + .map(|arg| arg.to_string_lossy().into_owned()) + .skip_while(|arg| arg.ends_with("bisect-rustc")) + { + eprint!("{arg} "); } eprintln!(); eprintln!("```");