mirror of
https://github.com/nix-community/home-manager.git
synced 2024-12-14 11:57:55 +00:00
home-manager: avoid import to improve error messages
When using `import` to inject the configuration into the module system we lose the location in error messages, i.e., it just says ``<unknown-file>'`.
This commit is contained in:
parent
bfb5a678d2
commit
fa4f9197ee
1 changed files with 3 additions and 4 deletions
|
@ -11,10 +11,9 @@ let
|
|||
|
||||
env = import <home-manager/modules> {
|
||||
configuration =
|
||||
let
|
||||
conf = import confPath;
|
||||
in
|
||||
if confAttr == "" then conf else conf.${confAttr};
|
||||
if confAttr == ""
|
||||
then confPath
|
||||
else (import confPath).${confAttr};
|
||||
pkgs = pkgs;
|
||||
check = check;
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue