···22 xmlns:xlink="http://www.w3.org/1999/xlink"
33 xml:id="chap-packageconfig">
4455-<title><filename>~/.nixpkgs/config.nix</filename>: global configuration</title>
55+<title>Global configuration</title>
6677<para>Nix packages can be configured to allow or deny certain options.</para>
8899<para>To apply the configuration edit
1010-<filename>~/.nixpkgs/config.nix</filename> and set it like
1010+<filename>~/.config/nixpkgs/config.nix</filename> and set it like
11111212<programlisting>
1313{
···89899090<para>You can define a function called
9191<varname>packageOverrides</varname> in your local
9292-<filename>~/.nixpkgs/config.nix</filename> to overide nix packages. It
9292+<filename>~/.config/nixpkgs/config.nix</filename> to overide nix packages. It
9393must be a function that takes pkgs as an argument and return modified
9494set of packages.
9595
+1-1
doc/functions.xml
···119119 evaluation-per-function application incurs a performance penalty,
120120 which can become a problem if many overrides are used.
121121 It is only intended for ad-hoc customisation, such as in
122122- <filename>~/.nixpkgs/config.nix</filename>.
122122+ <filename>~/.config/nixpkgs/config.nix</filename>.
123123 </para>
124124 </warning>
125125
+4-4
doc/languages-frameworks/haskell.md
···195195 mtl-2.2.1
196196197197This function allows users to define their own development environment by means
198198-of an override. After adding the following snippet to `~/.nixpkgs/config.nix`,
198198+of an override. After adding the following snippet to `~/.config/nixpkgs/config.nix`,
199199200200 {
201201 packageOverrides = super: let self = super.pkgs; in
···522522 $ cd ~/src/foo && cabal2nix . >default.nix
523523 $ cd ~/src/bar && cabal2nix . >default.nix
524524525525-Then edit your `~/.nixpkgs/config.nix` file to register those builds in the
525525+Then edit your `~/.config/nixpkgs/config.nix` file to register those builds in the
526526default Haskell package set:
527527528528 {
···554554to manipulate the package as much as you please. One useful application of this
555555feature is to replace the default `mkDerivation` function with one that enables
556556library profiling for all packages. To accomplish that, add configure the
557557-following snippet in your `~/.nixpkgs/config.nix` file:
557557+following snippet in your `~/.config/nixpkgs/config.nix` file:
558558559559 {
560560 packageOverrides = super: let self = super.pkgs; in
···583583584584 $ cabal2nix cabal://ghc-events-0.4.3.0 >~/.nixpkgs/ghc-events-0.4.3.0.nix
585585586586-Then add the override in `~/.nixpkgs/config.nix`:
586586+Then add the override in `~/.config/nixpkgs/config.nix`:
587587588588 {
589589 packageOverrides = super: let self = super.pkgs; in
+1-1
doc/package-notes.xml
···278278</screen>
279279280280 to your Nixpkgs configuration
281281- (<filename>~/.nixpkgs/config.nix</filename>) and install it by
281281+ (<filename>~/.config/nixpkgs/config.nix</filename>) and install it by
282282 running <command>nix-env -f '<nixpkgs>' -iA
283283 myEclipse</command> and afterward run Eclipse as usual. It is
284284 possible to find out which plugins are available for installation
+4-4
lib/customisation.nix
···1515 the original derivation attributes.
16161717 `overrideDerivation' allows certain "ad-hoc" customisation
1818- scenarios (e.g. in ~/.nixpkgs/config.nix). For instance, if you
1919- want to "patch" the derivation returned by a package function in
2020- Nixpkgs to build another version than what the function itself
2121- provides, you can do something like this:
1818+ scenarios (e.g. in ~/.config/nixpkgs/config.nix). For instance,
1919+ if you want to "patch" the derivation returned by a package
2020+ function in Nixpkgs to build another version than what the
2121+ function itself provides, you can do something like this:
22222323 mySed = overrideDerivation pkgs.gnused (oldAttrs: {
2424 name = "sed-4.2.2-pre";
+2-2
nixos/modules/services/editors/emacs.xml
···316316 <para>
317317 If you are not on NixOS or want to install this particular
318318 Emacs only for yourself, you can do so by adding it to your
319319- <filename>~/.nixpkgs/config.nix</filename>
319319+ <filename>~/.config/nixpkgs/config.nix</filename>
320320 (see <link xlink:href="http://nixos.org/nixpkgs/manual/#sec-modify-via-packageOverrides">Nixpkgs manual</link>):
321321 <example>
322322- <title>Custom Emacs in <filename>~/.nixpkgs/system.nix</filename></title>
322322+ <title>Custom Emacs in <filename>~/.config/nixpkgs/config.nix</filename></title>
323323 <programlisting><![CDATA[
324324{
325325 packageOverrides = super: let self = super.pkgs; in {
+1-1
pkgs/development/r-modules/README.md
···44## Installation
5566Define an environment for R that contains all the libraries that you'd like to
77-use by adding the following snippet to your $HOME/.nixpkgs/config.nix file:
77+use by adding the following snippet to your $HOME/.config/nixpkgs/config.nix file:
8899```nix
1010{
+1-1
pkgs/games/planetaryannihilation/default.nix
···66assert ((config.planetary_annihilation or null).sha256 or null) != null;
7788/* to setup:
99- $ cat ~/.nixpkgs/config.nix
99+ $ cat ~/.config/nixpkgs/config.nix
1010 {
1111 planetary_annihilation = {
1212 url = "file:///home/user/PA_Linux_62857.tar.bz2";
+1-1
pkgs/stdenv/adapters.nix
···183183184184 This adapter can be defined on the defaultStdenv definition. You can
185185 use it by patching the all-packages.nix file or by using the override
186186- feature of ~/.nixpkgs/config.nix .
186186+ feature of ~/.config/nixpkgs/config.nix .
187187 */
188188 validateLicenses = licensePred: stdenv: stdenv //
189189 { mkDerivation = args:
+1-1
pkgs/stdenv/generic/default.nix
···153153154154 b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
155155 { allow${up reason} = true; }
156156- to ~/.nixpkgs/config.nix.
156156+ to ~/.config/nixpkgs/config.nix.
157157 ''));
158158159159 # Check if a derivation is valid, that is whether it passes checks for
+5-3
pkgs/top-level/impure.nix
···1717 system ? builtins.currentSystem
18181919, # Fallback: The contents of the configuration file found at $NIXPKGS_CONFIG or
2020- # $HOME/.nixpkgs/config.nix.
2020+ # $HOME/.config/nixpkgs/config.nix.
2121 config ? let
2222 configFile = getEnv "NIXPKGS_CONFIG";
2323- configFile2 = homeDir + "/.nixpkgs/config.nix";
2323+ configFile2 = homeDir + "/.config/nixpkgs/config.nix";
2424+ configFile3 = homeDir + "/.nixpkgs/config.nix"; # obsolete
2425 in
2526 if configFile != "" && pathExists configFile then import configFile
2627 else if homeDir != "" && pathExists configFile2 then import configFile2
2828+ else if homeDir != "" && pathExists configFile3 then import configFile3
2729 else {}
28302931, # Overlays are used to extend Nixpkgs collection with additional
···3133 # fix-point made by Nixpkgs.
3234 overlays ? let
3335 dirPath = try (if pathExists <nixpkgs-overlays> then <nixpkgs-overlays> else "") "";
3434- dirHome = homeDir + "/.nixpkgs/overlays";
3636+ dirHome = homeDir + "/.config/nixpkgs/overlays";
3537 dirCheck = dir: dir != "" && pathExists (dir + "/.");
3638 overlays = dir:
3739 let content = readDir dir; in