rsincronlib/
config.rs

1use crate::XDG;
2use serde::Deserialize;
3use std::path::{Path, PathBuf};
4
5#[derive(Deserialize, Clone, Debug)]
6pub struct Config {
7    pub watch_table_file: PathBuf,
8}
9
10impl Default for Config {
11    fn default() -> Self {
12        Self {
13            watch_table_file: XDG
14                .place_data_file(Path::new("rsincron.table"))
15                .expect("failed to create `rsincron.table`: is XDG_DATA_HOME set?"),
16        }
17    }
18}