spec_driven_docs/cli/docs.rs
1//! `docs` subcommand: parse-shape.
2//!
3//! One positional taking any number of words, so `sdd docs context budget`
4//! and `sdd docs "context budget"` reach the same alias. No `--index`
5//! flag: the bare verb is the index, which keeps the always-loaded route
6//! one clause and gives an agent no flag to half-remember.
7//!
8//! Holds the clap derive struct only. No I/O, no business logic.
9
10/// Read this binary's own corpus: the index, or one topic.
11#[derive(Debug, clap::Args)]
12pub struct DocsArgs {
13 /// The topic, as one or more words. With none, print the index.
14 #[arg(value_name = "TOPIC")]
15 pub topic: Vec<String>,
16
17 /// Print one JSON object instead of text.
18 #[arg(long)]
19 pub json: bool,
20}