diff options
author | Philip Taron <philip.taron@gmail.com> | 2024-03-11 08:38:14 -0700 |
---|---|---|
committer | Philip Taron <philip.taron@gmail.com> | 2024-03-11 08:38:14 -0700 |
commit | 0426125c537b198e5d6db3f57e404e3f6954b85f (patch) | |
tree | bcc55de1a9c5bb0a2219b137f0d8dbc310db1843 /lib/tests/modules | |
parent | dd46445adc028cd627dcf4686e74f464fb4b7c2e (diff) | |
download | nixlib-0426125c537b198e5d6db3f57e404e3f6954b85f.tar nixlib-0426125c537b198e5d6db3f57e404e3f6954b85f.tar.gz nixlib-0426125c537b198e5d6db3f57e404e3f6954b85f.tar.bz2 nixlib-0426125c537b198e5d6db3f57e404e3f6954b85f.tar.lz nixlib-0426125c537b198e5d6db3f57e404e3f6954b85f.tar.xz nixlib-0426125c537b198e5d6db3f57e404e3f6954b85f.tar.zst nixlib-0426125c537b198e5d6db3f57e404e3f6954b85f.zip |
Avoid top-level `with ...;` in lib/tests/modules/alias-with-priority.nix
Diffstat (limited to 'lib/tests/modules')
-rw-r--r-- | lib/tests/modules/alias-with-priority.nix | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/lib/tests/modules/alias-with-priority.nix b/lib/tests/modules/alias-with-priority.nix index a35a06fc6974..c64a586ab2d1 100644 --- a/lib/tests/modules/alias-with-priority.nix +++ b/lib/tests/modules/alias-with-priority.nix @@ -6,12 +6,19 @@ { config, lib, ... }: -with lib; +let + inherit (lib) + mkAliasOptionModule + mkDefault + mkOption + types + ; +in { options = { # A simple boolean option that can be enabled or disabled. - enable = lib.mkOption { + enable = mkOption { type = types.nullOr types.bool; default = null; example = true; @@ -41,7 +48,7 @@ with lib; # should be able to be overridden by the next import. ( { config, lib, ... }: { - enableAlias = lib.mkDefault false; + enableAlias = mkDefault false; } ) |