From 725a7dc2f64c69bada9da1e234ddf091066d8249 Mon Sep 17 00:00:00 2001 From: Igor Pashev Date: Wed, 15 Aug 2018 22:05:48 +0300 Subject: Fix weird evalutation error in raid0.nix Propably due to "implicit imports" which is unwise anyway. The error was: while evaluating the attribute 'physical' at ..../nixpkgs/lib/modules.nix:198:7: while evaluating 'evalOptionValue' at ..../nixpkgs/lib/modules.nix:286:31, called from ..../nixpkgs/lib/modules.nix:221:16: while evaluating 'fixupOptionType' at ..../nixpkgs/lib/modules.nix:454:26, called from ..../nixpkgs/lib/modules.nix:220:23: while evaluating the attribute 'type.getSubModules' at ..../nixpkgs/lib/types.nix:91:14: value is a built-in function while a set was expected, at ..../nixpkgs/lib/types.nix:254:23 --- modules/system/raid0.nix | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/modules/system/raid0.nix b/modules/system/raid0.nix index d260e29..ed946d2 100644 --- a/modules/system/raid0.nix +++ b/modules/system/raid0.nix @@ -1,10 +1,20 @@ { config, pkgs, lib, ... }: -with lib; -with lib.types; -with builtins; - let + + inherit (builtins) + attrNames + ; + + inherit (lib) + concatStringsSep filterAttrs foldl genAttrs mapAttrs' mapAttrsToList + mkOption nameValuePair removePrefix replaceStrings + ; + + inherit (lib.types) + attrsOf enum int listOf path submodule + ; + groups = filterAttrs (n: _: n != "_module") config.nixsap.system.lvm.raid0; createLV = vg: lv: s: opts: -- cgit v1.2.3