use clap::{Parser, Subcommand};
use std::path::PathBuf;
#[derive(Parser, Debug)]
#[command(name = "codex_usage")]
#[command(author, version, about, long_about = None)]
pub struct Cli {
#[command(subcommand)]
pub command: Commands,
}
#[derive(Subcommand, Debug)]
pub enum Commands {
Analysis {
#[arg(short, long)]
path: PathBuf,
#[arg(short, long)]
output: Option<PathBuf>,
},
Usage {
#[arg(long)]
json: bool,
#[arg(long)]
text: bool,
#[arg(long)]
table: bool,
},
Version {
#[arg(long)]
json: bool,
#[arg(long)]
text: bool,
},
}
impl Cli {
pub fn parse_args() -> Self {
Self::parse()
}
}