use serde::{Deserialize, Serialize};
#[derive(Debug, Default, Clone, Serialize, Deserialize)]
pub struct Manifest {
pub compiler: CompilerSection,
}
#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(default)]
pub struct CompilerSection {
#[serde(skip_serializing_if = "Option::is_none")]
pub version: Option<String>,
pub entrypoint: String,
#[serde(skip_serializing_if = "Option::is_none")]
pub std: Option<bool>,
#[serde(skip_serializing_if = "Option::is_none")]
pub dist_dir: Option<String>,
}
impl Default for CompilerSection {
fn default() -> Self {
Self {
version: Some(env!("CARGO_PKG_VERSION").to_string()),
entrypoint: "puzzles".to_string(),
std: None,
dist_dir: None,
}
}
}