From e952e94955dcc6fa2120c1430789fc41363f5237 Mon Sep 17 00:00:00 2001 From: Manuel Mendez Date: Mon, 9 Dec 2024 13:28:59 -0500 Subject: [PATCH] atuin: Prepare for daemon socket path in 18.4.0 The path is changing in 18.4.0 to XDG_RUNTIME_DIR over XDG_DATA_DIR so update the specifier. See https://github.com/atuinsh/atuin/pull/2171. --- modules/programs/atuin.nix | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/modules/programs/atuin.nix b/modules/programs/atuin.nix index 32898c7cb..b57cc142a 100644 --- a/modules/programs/atuin.nix +++ b/modules/programs/atuin.nix @@ -195,11 +195,16 @@ in { }; }; - systemd.user.sockets.atuin-daemon = { + systemd.user.sockets.atuin-daemon = let + socket_dir = if versionAtLeast cfg.package.version "18.4.0" then + "%t" + else + "%D/atuin"; + in { Unit = { Description = "Atuin daemon socket"; }; Install = { WantedBy = [ "sockets.target" ]; }; Socket = { - ListenStream = "%D/atuin/atuin.sock"; + ListenStream = "${socket_dir}/atuin.sock"; SocketMode = "0600"; RemoveOnStop = true; };