#[cfg(feature = "cli")]
use clap::ValueEnum;
use serde::Serialize;
#[cfg(any(feature = "cli", feature = "server"))]
#[derive(Debug, Clone)]
pub struct OutputConfig {
pub format: OutputFormat,
pub file: Option<String>,
pub pretty: bool,
pub append: bool,
pub create_parent_dirs: bool,
}
#[cfg(any(feature = "cli", feature = "server"))]
#[cfg_attr(feature = "cli", derive(ValueEnum))]
#[derive(Debug, Clone, Copy, PartialEq, Eq, Serialize)]
#[serde(rename_all = "lowercase")]
pub enum OutputFormat {
Text,
Json,
}
#[cfg(any(feature = "cli", feature = "server"))]
impl Default for OutputFormat {
fn default() -> Self {
Self::Text
}
}