mirror of
https://gitlab.com/TECHNOFAB/nix-gitlab-ci.git
synced 2025-12-11 17:50:08 +01:00
docs: add initial docs setup
This commit is contained in:
parent
aa1abf945e
commit
e7f7043012
7 changed files with 101 additions and 5 deletions
|
|
@ -2,7 +2,7 @@
|
|||
pkgs,
|
||||
lib,
|
||||
} @ args: let
|
||||
inherit (lib) types isAttrs filterAttrs mapAttrs mkOption mkOptionType isType;
|
||||
inherit (lib) types isAttrs filterAttrs mapAttrs mkOption mkOptionType isType literalExpression;
|
||||
in rec {
|
||||
prepend = key: arr: job: {
|
||||
${key} = arr ++ (job.${key} or []);
|
||||
|
|
@ -61,12 +61,17 @@ in rec {
|
|||
_type = "unset";
|
||||
};
|
||||
isUnset = isType "unset";
|
||||
unsetOr = types.either unsetType;
|
||||
unsetOr = typ:
|
||||
(types.either unsetType typ)
|
||||
// {
|
||||
description = typ.description;
|
||||
};
|
||||
mkUnsetOption = opts:
|
||||
mkOption (opts
|
||||
// {
|
||||
type = unsetOr opts.type;
|
||||
default = opts.default or unset;
|
||||
defaultText = literalExpression "unset";
|
||||
});
|
||||
|
||||
filterUnset = value:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue