mirror of
https://github.com/clap-rs/clap
synced 2024-12-14 14:52:33 +00:00
15 lines
223 B
Rust
15 lines
223 B
Rust
use clap::Parser;
|
|
|
|
#[derive(Parser, Debug)]
|
|
#[command(name = "test")]
|
|
pub struct Opt {
|
|
#[arg(long)]
|
|
a: u32,
|
|
#[arg(skip, long)]
|
|
b: u32,
|
|
}
|
|
|
|
fn main() {
|
|
let opt = Opt::parse();
|
|
println!("{:?}", opt);
|
|
}
|