anchor.diff:      # open luksRoot and scan for logical volumes
       cryptsetup luksOpen ${device} ${name}
     '';
  +
  +  isPreLVM = f: f.preLVM;
  +  preLVM = filter isPreLVM luks.devices;
  +  postLVM = filter (f: !(isPreLVM f)) luks.devices;
   
   in
   {
  
positive.code:       $out/bin/cryptsetup --version
      '';
  
      boot.initrd.preLVMCommands = concatMapStrings openCommand luks.devices;
    };
  }
  
negative.code: 
      boot.initrd.luks.devices = mkOption {
        default = [ ];
        example = [ { name = "luksroot"; device = "/dev/sda3"; preLVM = true; } ];
        description = '';
          The list of devices that should be decrypted using LUKS before trying to mount the
          root partition. This works for both LVM-over-LUKS and LUKS-over-LVM setups.
  