main
Colby Knox Publish 0.1.0 fb6e12f 11d ago
use clap::{Parser, Subcommand};

#[derive(Parser)]
#[command(name = "adom-resend-studio", version, about = "Author, preview, and publish Resend email templates")]
pub struct Cli {
    #[command(subcommand)]
    pub command: Command,
}

#[derive(Subcommand)]
pub enum Command {
    /// Start the local server + webview UI.
    Serve {
        #[arg(long, default_value_t = 8894)]
        port: u16,
        /// Enables dev-only behavior. Never set this in production.
        #[arg(long)]
        dev: bool,
        /// Also open the app in a Hydrogen webview tab via adom-cli.
        #[arg(long)]
        open_tab: bool,
    },
    /// Check whether a running instance is reachable.
    Health {
        #[arg(long, default_value_t = 8894)]
        port: u16,
    },
    /// One-time local setup check.
    Install,
}