pub mod completions;
pub mod gate;
pub mod hooks;
pub mod init;
pub mod license;
pub mod read;
pub mod skill;
pub mod status;
pub mod upgrade;
pub mod verify;
use clap::{ArgAction, Parser, Subcommand};
#[derive(Debug, Parser)]
#[command(name = "sdd", version, about, long_about = None)]
pub struct Cli {
#[command(flatten)]
pub global: GlobalArgs,
#[command(subcommand)]
pub command: Commands,
}
#[derive(Debug, clap::Args)]
pub struct GlobalArgs {
#[arg(short, long, action = ArgAction::Count, global = true)]
pub verbose: u8,
}
#[derive(Debug, Subcommand)]
pub enum Commands {
Init(init::InitArgs),
Verify(verify::VerifyArgs),
Upgrade(upgrade::UpgradeArgs),
Gate(gate::GateArgs),
Hooks(hooks::HooksArgs),
Method(read::ReadArgs),
Spec(read::ReadArgs),
Template(read::ReadArgs),
Skill(skill::SkillArgs),
Status(status::StatusArgs),
License(license::LicenseArgs),
SelfManifest,
Completions(completions::CompletionsArgs),
Man,
}
#[must_use]
pub fn subcommand_names() -> Vec<String> {
<Cli as clap::CommandFactory>::command()
.get_subcommands()
.map(|command| command.get_name().to_string())
.collect()
}