diff --git a/lib/bool.nix b/lib/bool.nix deleted file mode 100644 index 30a44842..00000000 --- a/lib/bool.nix +++ /dev/null @@ -1,8 +0,0 @@ -{lib}: { - mkBool = value: description: - lib.mkOption { - type = lib.types.bool; - default = value; - inherit description; - }; -} diff --git a/lib/default.nix b/lib/default.nix index ccc81059..fc5aca13 100644 --- a/lib/default.nix +++ b/lib/default.nix @@ -1,5 +1,5 @@ {lib}: { - bool = import ./bool.nix {inherit lib;}; + modules = import ./modules.nix {inherit lib;}; dag = import ./dag.nix {inherit lib;}; types = import ./types {inherit lib;}; languages = import ./languages.nix {inherit lib;}; diff --git a/lib/modules.nix b/lib/modules.nix new file mode 100644 index 00000000..909a9f4b --- /dev/null +++ b/lib/modules.nix @@ -0,0 +1,13 @@ +{lib}: let + inherit (lib.options) mkOption; + inherit (lib.types) bool; +in { + # mkBoolOption: bool -> string -> option + # e.g. mkBoolOption true "Enable feature X" + mkBoolOption = value: description: + mkOption { + type = bool; + default = value; + inherit description; + }; +} diff --git a/lib/nmd.nix b/lib/nmd.nix deleted file mode 100644 index fd945f1c..00000000 --- a/lib/nmd.nix +++ /dev/null @@ -1,17 +0,0 @@ -# Copied from nmd master: https://gitlab.com/rycee/nmd/-/blob/master/default.nix?ref_type=heads -# Allows asciiDoc in options. It is easier to copy & keep updated then figure out how to pass the nmd input -# along to user modules -{ - # Indicates that the given text should be interpreted as AsciiDoc markup. - asciiDoc = text: { - _type = "asciiDoc"; - inherit text; - }; - - # Indicates that the given text should be interpreted as AsciiDoc markup and - # used in a literal context. - literalAsciiDoc = text: { - _type = "literalAsciiDoc"; - inherit text; - }; -}