summaryrefslogtreecommitdiffstats
path: root/src/configuration.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/configuration.rs')
-rw-r--r--src/configuration.rs19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/configuration.rs b/src/configuration.rs
new file mode 100644
index 0000000..165b503
--- /dev/null
+++ b/src/configuration.rs
@@ -0,0 +1,19 @@
+use std::path::PathBuf;
+use serde::Deserialize;
+
+#[derive(Debug, Deserialize)]
+pub struct Configuration {
+ notmuch_database_path: PathBuf,
+ notmuch_default_query: String,
+}
+
+impl Configuration {
+ pub fn notmuch_database_path(&self) -> &PathBuf {
+ &self.notmuch_database_path
+ }
+
+ pub fn notmuch_default_query(&self) -> &String {
+ &self.notmuch_default_query
+ }
+}
+