use clap::{Parser, Subcommand};
#[derive(Parser)]
#[command(
name = "roteiro",
version,
about = "Provenance-tagged codebase knowledge graph",
long_about = "Roteiro — the pilot book for your codebase.\n\n\
One SQLite store holding structure, intent, and context as a single \
provenance-tagged knowledge graph, queryable by humans and AI agents \
alike. Subcommands are scaffolds while the graph core lands; see \
ADR-0001 and docs/BUILD_PLAN.md for the roadmap.",
arg_required_else_help = true,
propagate_version = true
)]
struct Cli {
#[command(subcommand)]
command: Command,
}
#[derive(Subcommand)]
enum Command {
Init,
Sync,
Check,
Import {
#[arg(long)]
from: String,
},
Render {
target: String,
},
Spec,
#[cfg(feature = "mcp")]
Serve,
}
fn main() -> anyhow::Result<()> {
let cli = Cli::parse();
let name = match cli.command {
Command::Init => "init",
Command::Sync => "sync",
Command::Check => "check",
Command::Import { .. } => "import",
Command::Render { .. } => "render",
Command::Spec => "spec",
#[cfg(feature = "mcp")]
Command::Serve => "serve",
};
anyhow::bail!("`roteiro {name}` is not implemented yet (v0.0.1 scaffold; see ADR-0001)")
}