Skip to content

Instantly share code, notes, and snippets.

@ryantm
Created June 5, 2018 18:47
Show Gist options
  • Save ryantm/4232ce9bc7e02b29eab11118744b40cd to your computer and use it in GitHub Desktop.
Save ryantm/4232ce9bc7e02b29eab11118744b40cd to your computer and use it in GitHub Desktop.
{ config, lib, pkgs, ... }:
{
options.our.test = {
enable = lib.mkEnableOption "test";
opt = lib.mkOption {
type = lib.types.attrs;
default = {};
};
};
config = lib.mkIf config.our.test.enable
# (lib.mkMerge []); # works
(lib.mkMerge (map (d: {}) (lib.attrValues config.our.test.opt))); # infinte recursion
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment