From d8b1ba8940638e82628a19d719383bdf115da5cd Mon Sep 17 00:00:00 2001 From: ItsDrike Date: Thu, 4 Apr 2024 23:59:46 +0200 Subject: [PATCH] Make nix use xdg base dirs --- system/nix/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/system/nix/default.nix b/system/nix/default.nix index ebadc3e..bac6426 100644 --- a/system/nix/default.nix +++ b/system/nix/default.nix @@ -26,6 +26,13 @@ # Give these users/groups additional rights when connecting to the Nix daemon # like specifying extra binary caches trusted-users = [ "root" "@wheel" ]; + + # Tell nix to use xdg base directories + # If you're just setting this, you will need to move the directories + # manually, nix won't do it for you: + # - mv "$HOME/.nix-defexpr" "$XDG_STATE_HOME/nix/defexpr" + # - mv "$HOME/.nix-profile" "$XDG_STATE_HOME/nix/profile" + use-xdg-base-directories = true; }; };