tix/cli/cli_roadmap.rs
1#[allow(clippy::wildcard_imports)]
2use super::*;
3
4/// The `tix roadmap` subcommands (mission `roadmap-initiatives-01M3C8SX`, WP04).
5///
6/// Read-only. `list` applies the one normalized [`crate::roadmap::filter::RoadmapFilter`];
7/// `show` prints the single-row detail in the same rendering.
8#[derive(Subcommand)]
9pub enum RoadmapCommand {
10 /// List initiatives in roadmap order: target date ascending, then stable id
11 ///
12 /// An undated initiative sorts after every dated one and renders the explicit
13 /// `undated` state — never a blank or an invented date. A bounded period filter
14 /// excludes it, because inventing a period is exactly what the contract forbids.
15 List {
16 /// Inclusive lower bound on the target date (`YYYY-MM-DD`)
17 #[arg(long, value_name = "DATE")]
18 from: Option<String>,
19 /// Inclusive upper bound on the target date (`YYYY-MM-DD`)
20 #[arg(long, value_name = "DATE")]
21 to: Option<String>,
22 /// Owner to match, compared trimmed and case-insensitively
23 #[arg(long, value_name = "ID")]
24 owner: Option<String>,
25 /// Initiative status to match, compared trimmed and case-insensitively
26 #[arg(long, value_name = "STATE")]
27 status: Option<String>,
28 /// A label the initiative must carry; repeat for an AND over labels
29 #[arg(long = "label", value_name = "LABEL")]
30 labels: Vec<String>,
31 /// Free text matched case-insensitively against the searchable fields
32 #[arg(long, value_name = "TEXT")]
33 query: Option<String>,
34 },
35 /// Show one initiative's roadmap row: summary contributions and diagnostics
36 Show {
37 /// Initiative id (a name is accepted as a convenience)
38 #[arg(value_name = "ID")]
39 reference: String,
40 },
41}