NixOS: update config.nixpkgs.pkgs documentation

This commit is contained in:
Robert Hensing 2018-11-10 23:21:21 +01:00
parent b682778366
commit b60dccbf4f

View File

@ -75,11 +75,18 @@ in
type = pkgsType; type = pkgsType;
example = literalExample ''import <nixpkgs> {}''; example = literalExample ''import <nixpkgs> {}'';
description = '' description = ''
This is the evaluation of Nixpkgs that will be provided to If set, the pkgs argument to all NixOS modules is the value of
all NixOS modules. Defining this option has the effect of this option, extended with <code>nixpkgs.overlays</code>, if
ignoring the other options that would otherwise be used to that is also set. Either <code>nixpkgs.crossSystem</code> or
evaluate Nixpkgs, because those are arguments to the default <code>nixpkgs.localSystem</code> will be used in an assertion
value. The default value imports the Nixpkgs source files to check that the NixOS and Nixpkgs architectures match. Any
other options in <code>nixpkgs.*</code>, notably <code>config</code>,
will be ignored.
If unset, the pkgs argument to all NixOS modules is determined
as shown in the default value for this option.
The default value imports the Nixpkgs source files
relative to the location of this NixOS module, because relative to the location of this NixOS module, because
NixOS and Nixpkgs are distributed together for consistency, NixOS and Nixpkgs are distributed together for consistency,
so the <code>nixos</code> in the default value is in fact a so the <code>nixos</code> in the default value is in fact a
@ -140,9 +147,6 @@ in
If <code>nixpkgs.pkgs</code> is set, overlays specified here If <code>nixpkgs.pkgs</code> is set, overlays specified here
will be applied after the overlays that were already present will be applied after the overlays that were already present
in <code>nixpkgs.pkgs</code>. in <code>nixpkgs.pkgs</code>.
Note that other options such as <code>nixpkgs.config</code> will
be ignored when <code>nixpkgs.pkgs</code> is set.
''; '';
}; };