summary refs log tree commit diff
path: root/lib/attrsets.nix
diff options
context:
space:
mode:
authorVladimír Čunát <vcunat@gmail.com>2016-01-13 11:49:19 +0100
committerVladimír Čunát <vcunat@gmail.com>2016-01-13 12:03:18 +0100
commitb9f6dfe8c5c8da09b6c2d8a8e168bdcf50a0aabd (patch)
tree497355a44e942909921a8c2e5f76ec211f85d883 /lib/attrsets.nix
parent7dba3bafba219ec6dc2c3a1b44f9d574837b5fe5 (diff)
downloadnixlib-b9f6dfe8c5c8da09b6c2d8a8e168bdcf50a0aabd.tar
nixlib-b9f6dfe8c5c8da09b6c2d8a8e168bdcf50a0aabd.tar.gz
nixlib-b9f6dfe8c5c8da09b6c2d8a8e168bdcf50a0aabd.tar.bz2
nixlib-b9f6dfe8c5c8da09b6c2d8a8e168bdcf50a0aabd.tar.lz
nixlib-b9f6dfe8c5c8da09b6c2d8a8e168bdcf50a0aabd.tar.xz
nixlib-b9f6dfe8c5c8da09b6c2d8a8e168bdcf50a0aabd.tar.zst
nixlib-b9f6dfe8c5c8da09b6c2d8a8e168bdcf50a0aabd.zip
nixos manuals: allow displaying package references
The manuals are now evaluated with each derivation in `pkgs` (recursively)
replaced by a fake with path "\${pkgs.path.to.the.attribute}".
It isn't perfect, but it seems to cover a vast majority of use cases.
Caveat: even if the package is reached by a different means,
the path above will be shown and not e.g. `${config.services.foo.package}`.

As before, defaults created by `mkDefault` aren't displayed,
but documentation shouldn't (mostly) be a reason to use that anymore.

Note: t wouldn't be enough to just use `lib.mapAttrsRecursive`,
because derivations are also (special) attribute sets.
Diffstat (limited to 'lib/attrsets.nix')
-rw-r--r--lib/attrsets.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/attrsets.nix b/lib/attrsets.nix
index 84f6cb3658b9..e3721bd1e94c 100644
--- a/lib/attrsets.nix
+++ b/lib/attrsets.nix
@@ -207,7 +207,7 @@ rec {
 
 
   /* Like `mapAttrsRecursive', but it takes an additional predicate
-     function that tells it whether to recursive into an attribute
+     function that tells it whether to recurse into an attribute
      set.  If it returns false, `mapAttrsRecursiveCond' does not
      recurse, but does apply the map function.  It is returns true, it
      does recurse, and does not apply the map function.