//! Entry point: parses `argv` and dispatches to `pipeline`. Nothing here //! makes a network/subprocess call or contains a decision worth a test — //! see docs/ARCHITECTURE.md > "main is a dispatcher, not the program." mod builder; mod checker; mod config; mod fetcher; mod github; mod hash; mod pipeline; mod publisher; mod sanity; mod state; #[cfg(test)] mod test_support; mod verifier; use anyhow::{Result, bail}; /// check -> fetch -> verify -> build -> sanity-check -> publish, for /// whatever is in packages.d/. Tier 1-3 passes auto-publish; tier 4-6 /// passes queue for `pkgwatch review`. See docs/SPEC.md > Architecture for what /// each stage does, and docs/ARCHITECTURE.md for how the code implementing it /// is organized. fn main() -> Result<()> { let args: Vec = std::env::args().skip(1).collect(); match args.first().map(String::as_str) { None => pipeline::run_check(), Some("review") => pipeline::run_review(&args[1..]), Some(other) => bail!("unknown subcommand '{other}' (expected: review)"), } }