Some updates

This commit is contained in:
Nikolai Rodionov 2024-06-15 20:54:19 +02:00
parent f40fea7955
commit 055072f491
Signed by: allanger
GPG Key ID: 0AA46A90E25592AD
2 changed files with 8 additions and 1 deletions

View File

@ -18,6 +18,12 @@ pub(crate) enum SupportedIncludes {
Charts, Charts,
} }
#[derive(Serialize, Deserialize, PartialEq, Debug, Clone, Default)]
pub(crate) struct Hooks{
pre_hooks: Option<Vec<String>>,
post_hooks: Option<Vec<String>>
}
#[derive(Serialize, Deserialize, PartialEq, Debug, Clone, Default)] #[derive(Serialize, Deserialize, PartialEq, Debug, Clone, Default)]
pub(crate) struct ChartExtended { pub(crate) struct ChartExtended {
#[serde(flatten)] #[serde(flatten)]
@ -52,6 +58,7 @@ pub(crate) struct Config {
pub(crate) patches: Option<Vec<Patch>>, pub(crate) patches: Option<Vec<Patch>>,
#[serde(default = "empty_vec")] #[serde(default = "empty_vec")]
pub(crate) mirrors: Vec<Mirror>, pub(crate) mirrors: Vec<Mirror>,
pub(crate) hooks: Hooks,
} }
fn empty_vec<T>() -> Vec<T> { fn empty_vec<T>() -> Vec<T> {