Lets you do this:
#!/usr/bin/env -S cargo +nightly -Zscript ```cargo [dependencies] clap = { version = "4.2", features = ["derive"] } ``` use clap::Parser; #[derive(Parser, Debug)] #[clap(version)] struct Args { #[clap(short, long, help = "Path to config")] config: Option<std::path::PathBuf>, } fn main() { let args = Args::parse(); println!("{:?}", args); }