From f9d17c3aa68e65529f424816c8b9346ae602d1de Mon Sep 17 00:00:00 2001 From: Sridhar Ratnakumar <3998+srid@users.noreply.github.com> Date: Tue, 6 Feb 2024 12:56:03 -0500 Subject: [PATCH] Make `devShell.tools` a lazyAttrsOf (#223) --- CHANGELOG.md | 4 +++- nix/modules/project/defaults.nix | 2 +- nix/modules/project/devshell.nix | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 799ba05..89eee34 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,9 @@ - #210: Add `extraLibraries` to `settings` module. - #215: Improved debug logging. - #216: Remove `debug` option (pass `--trace-verbose` to nix instead) -- #222: Improve `cabal.project` parser by handling files not ending with newline +- Fixes + - #222: Improve `cabal.project` parser by handling files not ending with newline + - #223 Make `devShell.tools` a `lazyAttrsOf` (lazy evaluation of values) - Breaking changes - #221: Switch to `buildFromSdist`, to allow using non-standard package sets (wherein `cabal-install` is otherwise built without using user's overrides) diff --git a/nix/modules/project/defaults.nix b/nix/modules/project/defaults.nix index f27e95b..4d87b9e 100644 --- a/nix/modules/project/defaults.nix +++ b/nix/modules/project/defaults.nix @@ -18,7 +18,7 @@ in }; devShell.tools = mkOption { - type = functionTo (types.attrsOf (types.nullOr types.package)); + type = functionTo (types.lazyAttrsOf (types.nullOr types.package)); description = ''Build tools always included in devShell''; default = hp: with hp; lib.optionalAttrs config.defaults.enable { inherit diff --git a/nix/modules/project/devshell.nix b/nix/modules/project/devshell.nix index cf4849b..431b52e 100644 --- a/nix/modules/project/devshell.nix +++ b/nix/modules/project/devshell.nix @@ -17,7 +17,7 @@ let default = true; }; tools = mkOption { - type = functionTo (types.attrsOf (types.nullOr types.package)); + type = functionTo (types.lazyAttrsOf (types.nullOr types.package)); description = '' Build tools for developing the Haskell project.