From 2524d92e2b47dc9425a583e7d84fd41c470aca6f Mon Sep 17 00:00:00 2001 From: Cornelius Mika Date: Wed, 6 Sep 2017 10:17:26 +0200 Subject: [PATCH] home-environment: allow arbitrary paths as home file names By not using the home file name in a derivation name, the home file name is no longer exposed to the naming restrictions for nix store paths. For example, it's now possible to define home files with spaces in their names without providing a target or source attribute. --- modules/home-environment.nix | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/home-environment.nix b/modules/home-environment.nix index 5db2fbd6..45f8135f 100644 --- a/modules/home-environment.nix +++ b/modules/home-environment.nix @@ -134,8 +134,7 @@ in config = { target = mkDefault name; source = mkIf (config.text != null) ( - let name' = "user-etc-" + baseNameOf name; - in mkDefault (pkgs.writeText name' config.text) + mkDefault (pkgs.writeText "home-file" config.text) ); }; })