use clap::{Parser, ValueEnum};
#[derive(Copy, Clone, Debug, ValueEnum)]
pub enum GraphType {
Mermaid,
Dot,
Json,
}
impl GraphType {
pub fn file_extension(self) -> &'static str {
match self {
GraphType::Mermaid => "mmd",
GraphType::Dot => "dot",
GraphType::Json => "json",
}
}
}
#[derive(Parser, Debug, Default)]
pub struct GraphConfig {
#[clap(long)]
pub graph: Option<GraphType>,
#[clap(long, short = 'o')]
pub output: Option<String>,
#[clap(long)]
pub long_labels: bool,
#[clap(long)]
pub no_metadata: bool,
}