• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 use clap::Parser;
2 
3 #[derive(Parser)]
4 #[command(name = "MyApp")]
5 #[command(version = "1.0")]
6 #[command(about = "Does awesome things", long_about = None)]
7 struct Cli {
8     #[arg(long)]
9     two: String,
10     #[arg(long)]
11     one: String,
12 }
13 
main()14 fn main() {
15     let cli = Cli::parse();
16 
17     println!("two: {:?}", cli.two);
18     println!("one: {:?}", cli.one);
19 }
20