aboutsummaryrefslogtreecommitdiff
path: root/src/pomo
diff options
context:
space:
mode:
Diffstat (limited to 'src/pomo')
-rw-r--r--src/pomo/state.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/pomo/state.rs b/src/pomo/state.rs
index 0e2037f..f2e65dc 100644
--- a/src/pomo/state.rs
+++ b/src/pomo/state.rs
@@ -91,9 +91,15 @@ pub struct Config {
pub short_break_mins: u64,
pub long_break_mins: u64,
pub tasks: Vec<Task>,
+
+ #[serde(default = "default_auto_switch")]
pub auto_switch_sessions: bool,
}
+fn default_auto_switch() -> bool {
+ true
+}
+
#[derive(Serialize, Deserialize, Clone)]
pub struct Task {
pub title: String,