Clean up some option examples

This commit is contained in:
Eelco Dolstra
2013-10-30 16:19:07 +01:00
parent 0f8b1b1a5c
commit be5d3a59dd
8 changed files with 53 additions and 53 deletions

View File

@@ -98,7 +98,8 @@ rec {
representation of derivations is very large (on the order of
megabytes) and is not actually used by the manual generator. */
scrubOptionValue = x:
if isDerivation x then { type = "derivation"; drvPath = x.name; outPath = x.name; name = x.name; }
if isDerivation x then
{ type = "derivation"; drvPath = x.name; outPath = x.name; name = x.name; }
else if isList x then map scrubOptionValue x
else if isAttrs x then mapAttrs (n: v: scrubOptionValue v) (removeAttrs x ["_args"])
else x;