diff options
author | Robert Hensing <robert@roberthensing.nl> | 2018-10-15 13:47:36 +0200 |
---|---|---|
committer | Robert Hensing <robert@roberthensing.nl> | 2018-10-18 10:48:43 +0200 |
commit | 9b7654f6ff326a7e35b48ce3c54d7f8bb71d9a13 (patch) | |
tree | 7f7e370ec8a7c287e9c44eb7e5d70ebc7937f8d5 /doc/functions | |
parent | ba8b54fa4a91cd94e8c42095d4f82d4a93cd01d1 (diff) |
nixpkgs docs: Point to pkgs.extend, pkgs.appendOverlays and improve override section
Diffstat (limited to 'doc/functions')
-rw-r--r-- | doc/functions/overrides.xml | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/doc/functions/overrides.xml b/doc/functions/overrides.xml index 99e2a63631a7..30cc6f3f6b1d 100644 --- a/doc/functions/overrides.xml +++ b/doc/functions/overrides.xml @@ -6,8 +6,16 @@ <para> Sometimes one wants to override parts of <literal>nixpkgs</literal>, e.g. - derivation attributes, the results of derivations or even the whole package - set. + derivation attributes, the results of derivations. + </para> + + <para> + These overriding functions let you focus on one part of Nixpkgs and give you + back the requested variation. This is orthogonal but related to overlays and + the extending functions. Those also let you make modifications but return the + whole package set instead of just what you modified. When used together, the + override functions make the changes and overlays or extending functions add + those changes to the package sets. </para> <section xml:id="sec-pkg-override"> @@ -25,6 +33,9 @@ <para> Example usages: <programlisting>pkgs.foo.override { arg1 = val1; arg2 = val2; ... }</programlisting> +<!-- TODO: move below programlisting to a new section about extending and overlays + and reference it + --> <programlisting> import pkgs.path { overlays = [ (self: super: { foo = super.foo.override { barSupport = true ; }; |