Skip to content

Commit af8f2f8

Browse files
committed
Add support for generating a non api libs agenda
1 parent 1207c4b commit af8f2f8

File tree

4 files changed

+435
-265
lines changed

4 files changed

+435
-265
lines changed

tools/agenda-generator/Cargo.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,5 @@ chrono = "0.4"
1010
reqwest = { version = "0.10", features = ["blocking", "json"] }
1111
serde = { version = "1.0", features = ["derive"] }
1212
serde_json = "1.0"
13+
itertools = "0.10.1"
14+
structopt = "0.3.21"

tools/agenda-generator/src/cli.rs

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
use structopt::StructOpt;
2+
use structopt::clap::arg_enum;
3+
4+
#[derive(Debug, StructOpt)]
5+
pub struct Args {
6+
#[structopt(long, short, default_value = "LibsAPI", possible_values = &AgendaKind::variants())]
7+
pub agenda: AgendaKind,
8+
}
9+
10+
impl Args {
11+
pub fn from_args() -> Args {
12+
StructOpt::from_args()
13+
}
14+
}
15+
16+
arg_enum! {
17+
#[derive(Debug)]
18+
pub enum AgendaKind {
19+
Libs,
20+
LibsAPI,
21+
}
22+
}

0 commit comments

Comments
 (0)