1 2 3 4 5 6 7 8 9 10 11 12
use clap::Parser; #[derive(Parser, Debug)] #[command(author, version, about, long_about = None)] pub struct Cli { #[arg(short, long, env = "CONFIG_PATH")] pub config: Option<String>, } pub fn parse() -> Cli { Cli::parse() }