From 9bc2dd29ad6ba334fd57a20114e367d3c04763d4 Mon Sep 17 00:00:00 2001 From: Luca Casonato Date: Mon, 19 Aug 2024 00:39:53 +0200 Subject: fix: clean up flag help output (#24686) Permission flags are unified in a clearer and concise output. Unstable flags are hidden by default with exception of the `unstable` flag itself. the remaining unstable flags can be seen with a `--help=unstable`. This also cleans up to show unstable flags only for subcommands that actually need them. Also sorts flags alphabetically, and gorups various flags together in a set of categories. --------- Co-authored-by: crowlkats --- cli/main.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'cli/main.rs') diff --git a/cli/main.rs b/cli/main.rs index 9b141c536..aafa7f009 100644 --- a/cli/main.rs +++ b/cli/main.rs @@ -402,8 +402,7 @@ fn resolve_flags_and_init( let flags = match flags_from_vec(args) { Ok(flags) => flags, Err(err @ clap::Error { .. }) - if err.kind() == clap::error::ErrorKind::DisplayHelp - || err.kind() == clap::error::ErrorKind::DisplayVersion => + if err.kind() == clap::error::ErrorKind::DisplayVersion => { // Ignore results to avoid BrokenPipe errors. let _ = err.print(); -- cgit v1.2.3