From be09ae413fcb94ea7dc83c1e8eb08bc0c9c31639 Mon Sep 17 00:00:00 2001 From: sharkdp Date: Sat, 24 Mar 2018 20:41:35 +0100 Subject: [PATCH] Clean up the --help text --- src/main.rs | 42 ++++++++++++++++++++++-------------------- 1 file changed, 22 insertions(+), 20 deletions(-) diff --git a/src/main.rs b/src/main.rs index 4632d7e..2d0ef61 100644 --- a/src/main.rs +++ b/src/main.rs @@ -100,6 +100,8 @@ fn main() { .setting(clap_color_setting) .setting(AppSettings::DeriveDisplayOrder) .setting(AppSettings::UnifiedHelpMessage) + .setting(AppSettings::NextLineHelp) + .setting(AppSettings::HidePossibleValuesInHelp) .max_term_width(90) .about("A command-line benchmarking tool.") .arg( @@ -142,26 +144,6 @@ fn main() { clearing disk caches, for example.", ), ) - .arg( - Arg::with_name("style") - .long("style") - .short("s") - .takes_value(true) - .value_name("TYPE") - .possible_values(&["auto", "basic", "full", "nocolor"]) - .help( - "Set output style type (default: auto). Set this to 'basic' to disable output \ - coloring and interactive elements. Set it to 'full' to enable all effects \ - even if no interactive terminal was detected. Setting to 'nocolor' maintains \ - all advanced output, but uses no colorization.", - ), - ) - .arg( - Arg::with_name("ignore-failure") - .long("ignore-failure") - .short("i") - .help("Ignore non-zero exit codes."), - ) .arg( Arg::with_name("parameter-scan") .long("parameter-scan") @@ -174,6 +156,26 @@ fn main() { .allow_hyphen_values(true) .value_names(&["VAR", "MIN", "MAX"]), ) + .arg( + Arg::with_name("style") + .long("style") + .short("s") + .takes_value(true) + .value_name("TYPE") + .possible_values(&["auto", "basic", "full", "nocolor"]) + .help( + "Set output style type (default: auto). Set this to 'basic' to disable output \ + coloring and interactive elements. Set it to 'full' to enable all effects \ + even if no interactive terminal was detected. Set this to 'nocolor' to \ + keep the interactive output without any colors.", + ), + ) + .arg( + Arg::with_name("ignore-failure") + .long("ignore-failure") + .short("i") + .help("Ignore non-zero exit codes."), + ) .arg( Arg::with_name("export-csv") .long("export-csv")