From 9fbfa349a1973610287879ceb926c6d10b4b539f Mon Sep 17 00:00:00 2001 From: Daniel Schadt Date: Tue, 9 Nov 2021 18:57:36 +0100 Subject: enable SubcommandRequired & ColoredHelp Especially SubcommandRequired is helpful, as without one, we're not doing all that much. --- src/main.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/main.rs b/src/main.rs index 5b8c19c..817d39b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -6,7 +6,7 @@ use std::{ }; use anyhow::{anyhow, bail, Context, Result}; -use clap::{crate_version, App, Arg, ArgMatches, SubCommand}; +use clap::{crate_version, App, AppSettings, Arg, ArgMatches, SubCommand}; use itertools::Itertools; use log::debug; use termcolor::{Color, ColorChoice, ColorSpec, StandardStream, WriteColor}; @@ -76,6 +76,7 @@ fn main() -> Result<()> { .required(false), ), ) + .settings(&[AppSettings::SubcommandRequired, AppSettings::ColoredHelp]) .get_matches(); let mut stdout = StandardStream::stdout(ColorChoice::Auto); -- cgit v1.2.3