anchor.diff:      }
     '';
   
  +  zedConf = generators.toKeyValue {
  +    mkKeyValue = generators.mkKeyValueDefault {
  +      mkValueString = v:
  +        if isInt           v then toString v
  +        else if isString   v then "\"${v}\""
  +        else if true  ==   v then "1"
  +        else if false ==   v then "0"
  +        else if isList     v then "\"" + (concatStringsSep " " v) + "\""
  +        else err "this value is" (toString v);
  +    } "=";
  +  } cfgZED.settings;
   in
   
   {
  
positive.code:         zfsSupport = true;
        };
  
        environment.etc."zfs/zed.d".source = "${packages.zfsUser}/etc/zfs/zed.d/";
        environment.etc."zfs/zpool.d".source = "${packages.zfsUser}/etc/zfs/zpool.d/";
  
        system.fsPackages = [ packages.zfsUser ]; # XXX: needed? zfs doesn't have (need) a fsck
        environment.systemPackages = [ packages.zfsUser ]
  
negative.code:   cfgSnapFlags = cfgSnapshots.flags;
    cfgScrub = config.services.zfs.autoScrub;
    cfgTrim = config.services.zfs.trim;
    cfgZED = config.services.zfs.zed;
  
    inInitrd = any (fs: fs == "zfs") config.boot.initrd.supportedFilesystems;
    inSystem = any (fs: fs == "zfs") config.boot.supportedFilesystems;
  