feat: add config loader to parse json configs

This commit is contained in:
2024-02-18 18:40:11 +01:00
parent 41824bd04b
commit fc772f4b6a
5 changed files with 27 additions and 0 deletions

View File

@@ -1,3 +1,5 @@
use std::fmt::Error;
use serde::{Deserialize, Serialize};
#[derive(Debug, Serialize, Deserialize)]
@@ -13,4 +15,8 @@ impl Config {
database_path: String::from("/tmp/rustysearch.db"),
}
}
pub(crate) fn load_from_file(config_path: &str) -> Result<Config, Error> {
unimplemented!();
}
}