hooked/hooked-config/source/config/general.rs

26 lines
534 B
Rust
Raw Normal View History

2022-10-28 10:23:05 +00:00
//! General configuration definitions.
use std::path::PathBuf;
use serde::{Deserialize, Serialize};
/// General Hooked configuration.
#[derive(Debug, Deserialize, Serialize)]
#[serde(default, deny_unknown_fields)]
pub struct General {
2022-11-01 12:38:52 +00:00
/// Path to the Hooked configuration file.
pub config: PathBuf,
2022-10-28 10:23:05 +00:00
/// The directory to use for hooks.
pub directory: PathBuf,
}
impl Default for General {
fn default() -> Self {
Self {
2022-11-01 12:38:52 +00:00
config: PathBuf::from("Hooked.toml"),
2022-10-28 10:23:05 +00:00
directory: PathBuf::from("hooks"),
}
}
}