2018-08-01 03:47:08 +00:00
|
|
|
fn main() {}
|
|
|
|
// #[macro_use]
|
|
|
|
// extern crate clap;
|
2017-11-12 18:02:56 +00:00
|
|
|
|
2018-08-01 03:47:08 +00:00
|
|
|
// use clap::{App, Arg};
|
2017-11-12 18:02:56 +00:00
|
|
|
|
2018-08-01 03:47:08 +00:00
|
|
|
// #[derive(ArgEnum, Debug)]
|
|
|
|
// #[case_sensitive]
|
|
|
|
// enum ArgChoice {
|
|
|
|
// Foo,
|
|
|
|
// Bar,
|
|
|
|
// Baz,
|
|
|
|
// }
|
2017-11-12 18:02:56 +00:00
|
|
|
|
2018-08-01 03:47:08 +00:00
|
|
|
// fn main() {
|
|
|
|
// let matches = App::new(env!("CARGO_PKG_NAME"))
|
|
|
|
// .arg(
|
|
|
|
// Arg::with_name("arg")
|
|
|
|
// .required(true)
|
|
|
|
// .takes_value(true)
|
|
|
|
// .possible_values(&ArgChoice::variants()),
|
|
|
|
// )
|
|
|
|
// .get_matches();
|
2018-07-02 18:45:17 +00:00
|
|
|
|
2018-08-01 03:47:08 +00:00
|
|
|
// let t = value_t!(matches.value_of("arg"), ArgChoice).unwrap_or_else(|e| e.exit());
|
2017-11-12 18:02:56 +00:00
|
|
|
|
2018-08-01 03:47:08 +00:00
|
|
|
// println!("{:?}", t);
|
|
|
|
// }
|