mirror of
https://github.com/clap-rs/clap
synced 2024-12-14 23:02:31 +00:00
12 lines
303 B
Rust
12 lines
303 B
Rust
use clap::App;
|
|
use clap_generate::generate;
|
|
use clap_generate_fig::Fig;
|
|
use std::io;
|
|
|
|
fn main() {
|
|
let mut app = App::new("myapp")
|
|
.subcommand(App::new("test").subcommand(App::new("config")))
|
|
.subcommand(App::new("hello"));
|
|
|
|
generate(Fig, &mut app, "myapp", &mut io::stdout());
|
|
}
|