From b60dccbf4f021596913ad595dc43a3dff9f44ad4 Mon Sep 17 00:00:00 2001 From: Robert Hensing Date: Sat, 10 Nov 2018 23:21:21 +0100 Subject: [PATCH] NixOS: update config.nixpkgs.pkgs documentation --- nixos/modules/misc/nixpkgs.nix | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/nixos/modules/misc/nixpkgs.nix b/nixos/modules/misc/nixpkgs.nix index 2bebbdcad94..93fbf16841e 100644 --- a/nixos/modules/misc/nixpkgs.nix +++ b/nixos/modules/misc/nixpkgs.nix @@ -75,11 +75,18 @@ in type = pkgsType; example = literalExample ''import {}''; description = '' - This is the evaluation of Nixpkgs that will be provided to - all NixOS modules. Defining this option has the effect of - ignoring the other options that would otherwise be used to - evaluate Nixpkgs, because those are arguments to the default - value. The default value imports the Nixpkgs source files + If set, the pkgs argument to all NixOS modules is the value of + this option, extended with nixpkgs.overlays, if + that is also set. Either nixpkgs.crossSystem or + nixpkgs.localSystem will be used in an assertion + to check that the NixOS and Nixpkgs architectures match. Any + other options in nixpkgs.*, notably config, + 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 NixOS and Nixpkgs are distributed together for consistency, so the nixos in the default value is in fact a @@ -140,9 +147,6 @@ in If nixpkgs.pkgs is set, overlays specified here will be applied after the overlays that were already present in nixpkgs.pkgs. - - Note that other options such as nixpkgs.config will - be ignored when nixpkgs.pkgs is set. ''; };