use clap::ValueHint; #[derive(clap::Parser)] #[clap(author, version)] /// Pings configured hosts in a configurable intervals and exposes metrics for prometheus. pub struct Cli { /// Set config file #[clap(value_hint = ValueHint::FilePath)] pub config: std::path::PathBuf, #[clap(short, long, parse(from_occurrences))] /// Be verbose (you can add this up to 4 times for more logs). /// By default, only errors are logged, so no output is a good thing. pub verbose: usize, }