Merge pull request #5588 from tweag/balsoft/xdg

Follow XDG Base Directory standard
This commit is contained in:
Théophane Hufschmitt
2023-02-10 18:05:50 +01:00
committed by GitHub
16 changed files with 153 additions and 20 deletions
+1 -1
View File
@@ -2496,7 +2496,7 @@ Strings EvalSettings::getDefaultNixPath()
res.push_back(s ? *s + "=" + p : p);
};
add(getHome() + "/.nix-defexpr/channels");
add(settings.useXDGBaseDirectories ? getStateDir() + "/nix/defexpr/channels" : getHome() + "/.nix-defexpr/channels");
add(settings.nixStateDir + "/profiles/per-user/root/channels/nixpkgs", "nixpkgs");
add(settings.nixStateDir + "/profiles/per-user/root/channels");