From 58f0bd61e6e7b1a10e7460d8fe39921909ac216e Mon Sep 17 00:00:00 2001 From: Ellie Huxtable Date: Tue, 14 May 2024 10:23:05 +0700 Subject: [PATCH] fix: alias enable/enabled in settings (#2021) --- crates/atuin-client/src/settings.rs | 1 + crates/atuin-client/src/settings/dotfiles.rs | 1 + crates/atuin-server/src/settings.rs | 1 + 3 files changed, 3 insertions(+) diff --git a/crates/atuin-client/src/settings.rs b/crates/atuin-client/src/settings.rs index ed1c0a29..98a40496 100644 --- a/crates/atuin-client/src/settings.rs +++ b/crates/atuin-client/src/settings.rs @@ -346,6 +346,7 @@ pub struct Preview { pub struct Daemon { /// Use the daemon to sync /// If enabled, requires a running daemon with `atuin daemon` + #[serde(alias = "enable")] pub enabled: bool, /// The daemon will handle sync on an interval. How often to sync, in seconds. diff --git a/crates/atuin-client/src/settings/dotfiles.rs b/crates/atuin-client/src/settings/dotfiles.rs index dd852781..bbaf914f 100644 --- a/crates/atuin-client/src/settings/dotfiles.rs +++ b/crates/atuin-client/src/settings/dotfiles.rs @@ -2,5 +2,6 @@ use serde::{Deserialize, Serialize}; #[derive(Debug, Serialize, Deserialize, Clone, Default)] pub struct Settings { + #[serde(alias = "enable")] pub enabled: bool, } diff --git a/crates/atuin-server/src/settings.rs b/crates/atuin-server/src/settings.rs index 2d00df36..286b5688 100644 --- a/crates/atuin-server/src/settings.rs +++ b/crates/atuin-server/src/settings.rs @@ -104,6 +104,7 @@ pub fn example_config() -> &'static str { #[derive(Clone, Debug, Default, Deserialize, Serialize)] pub struct Tls { + #[serde(alias = "enabled")] pub enable: bool, pub cert_path: PathBuf,