From 79c2e500cdc7bc5b17b2ed5e5e1bf674a586243e Mon Sep 17 00:00:00 2001 From: Sridhar Ratnakumar Date: Wed, 10 Sep 2025 20:47:06 -0400 Subject: [PATCH] nix: Fix path on ubuntu with official installer --- modules/home/all/nix.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/home/all/nix.nix b/modules/home/all/nix.nix index d674cb7..488f40c 100644 --- a/modules/home/all/nix.nix +++ b/modules/home/all/nix.nix @@ -6,9 +6,12 @@ home.file.".config/nix/nix.conf".text = ""; # Global session path for all shells - home.sessionPath = lib.mkIf pkgs.stdenv.isDarwin [ + # Normally, we do this on macOS only. And it is not necessary on NixOS. Yet, + # non-NixOS Linux will need it (when using the official Nix installer). + home.sessionPath = [ "/etc/profiles/per-user/$USER/bin" "/nix/var/nix/profiles/system/sw/bin" + "$HOME/.nix-profile/bin" "/usr/local/bin" ]; }