diff options
Diffstat (limited to 'doc/manual/command-ref')
-rw-r--r-- | doc/manual/command-ref/conf-file.xml | 38 | ||||
-rw-r--r-- | doc/manual/command-ref/env-common.xml | 15 | ||||
-rw-r--r-- | doc/manual/command-ref/nix-env.xml | 7 | ||||
-rw-r--r-- | doc/manual/command-ref/nix-shell.xml | 6 | ||||
-rw-r--r-- | doc/manual/command-ref/nix-store.xml | 2 | ||||
-rw-r--r-- | doc/manual/command-ref/opt-common-syn.xml | 6 | ||||
-rw-r--r-- | doc/manual/command-ref/opt-common.xml | 31 |
7 files changed, 74 insertions, 31 deletions
diff --git a/doc/manual/command-ref/conf-file.xml b/doc/manual/command-ref/conf-file.xml index 48dce7c95..1fa74a143 100644 --- a/doc/manual/command-ref/conf-file.xml +++ b/doc/manual/command-ref/conf-file.xml @@ -19,26 +19,30 @@ <refsection><title>Description</title> -<para>Nix reads settings from two configuration files:</para> +<para>By default Nix reads settings from the following places:</para> + +<para>The system-wide configuration file +<filename><replaceable>sysconfdir</replaceable>/nix/nix.conf</filename> +(i.e. <filename>/etc/nix/nix.conf</filename> on most systems), or +<filename>$NIX_CONF_DIR/nix.conf</filename> if +<envar>NIX_CONF_DIR</envar> is set. Values loaded in this file are not forwarded to the Nix daemon. The +client assumes that the daemon has already loaded them. +</para> -<itemizedlist> +<para>User-specific configuration files:</para> - <listitem> - <para>The system-wide configuration file - <filename><replaceable>sysconfdir</replaceable>/nix/nix.conf</filename> - (i.e. <filename>/etc/nix/nix.conf</filename> on most systems), or - <filename>$NIX_CONF_DIR/nix.conf</filename> if - <envar>NIX_CONF_DIR</envar> is set.</para> - </listitem> +<para> + If <envar>NIX_USER_CONF_FILES</envar> is set, then each path separated by + <literal>:</literal> will be loaded in reverse order. +</para> - <listitem> - <para>The user configuration file - <filename>$XDG_CONFIG_HOME/nix/nix.conf</filename>, or - <filename>~/.config/nix/nix.conf</filename> if - <envar>XDG_CONFIG_HOME</envar> is not set.</para> - </listitem> +<para> + Otherwise it will look for <filename>nix/nix.conf</filename> files in + <envar>XDG_CONFIG_DIRS</envar> and <envar>XDG_CONFIG_HOME</envar>. -</itemizedlist> + The default location is <filename>$HOME/.config/nix.conf</filename> if + those environment variables are unset. +</para> <para>The configuration files consist of <literal><replaceable>name</replaceable> = @@ -382,7 +386,7 @@ false</literal>.</para> <programlisting> builtins.fetchurl { - url = https://example.org/foo-1.2.3.tar.xz; + url = "https://example.org/foo-1.2.3.tar.xz"; sha256 = "2c26b46b68ffc68ff99b453c1d30413413422d706483bfa0f98a5e886266e7ae"; } </programlisting> diff --git a/doc/manual/command-ref/env-common.xml b/doc/manual/command-ref/env-common.xml index 696d68c34..8466cc463 100644 --- a/doc/manual/command-ref/env-common.xml +++ b/doc/manual/command-ref/env-common.xml @@ -33,7 +33,7 @@ will cause Nix to look for paths relative to <filename>/home/eelco/Dev</filename> and - <filename>/etc/nixos</filename>, in that order. It is also + <filename>/etc/nixos</filename>, in this order. It is also possible to match paths against a prefix. For example, the value <screen> @@ -53,13 +53,13 @@ nixpkgs=/home/eelco/Dev/nixpkgs-branch:/etc/nixos</screen> <envar>NIX_PATH</envar> to <screen> -nixpkgs=https://github.com/NixOS/nixpkgs-channels/archive/nixos-15.09.tar.gz</screen> +nixpkgs=https://github.com/NixOS/nixpkgs/archive/nixos-15.09.tar.gz</screen> tells Nix to download the latest revision in the Nixpkgs/NixOS 15.09 channel.</para> <para>A following shorthand can be used to refer to the official channels: - + <screen>nixpkgs=channel:nixos-15.09</screen> </para> @@ -137,12 +137,19 @@ $ mount -o bind /mnt/otherdisk/nix /nix</screen> <varlistentry><term><envar>NIX_CONF_DIR</envar></term> - <listitem><para>Overrides the location of the Nix configuration + <listitem><para>Overrides the location of the system Nix configuration directory (default <filename><replaceable>prefix</replaceable>/etc/nix</filename>).</para></listitem> </varlistentry> +<varlistentry><term><envar>NIX_USER_CONF_FILES</envar></term> + + <listitem><para>Overrides the location of the user Nix configuration files + to load from (defaults to the XDG spec locations). The variable is treated + as a list separated by the <literal>:</literal> token.</para></listitem> + +</varlistentry> <varlistentry><term><envar>TMPDIR</envar></term> diff --git a/doc/manual/command-ref/nix-env.xml b/doc/manual/command-ref/nix-env.xml index 9c03ccce1..2b95b6819 100644 --- a/doc/manual/command-ref/nix-env.xml +++ b/doc/manual/command-ref/nix-env.xml @@ -526,13 +526,10 @@ these paths will be fetched (0.04 MiB download, 0.19 MiB unpacked): 14.12 channel: <screen> -$ nix-env -f https://github.com/NixOS/nixpkgs-channels/archive/nixos-14.12.tar.gz -iA firefox +$ nix-env -f https://github.com/NixOS/nixpkgs/archive/nixos-14.12.tar.gz -iA firefox </screen> -(The GitHub repository <literal>nixpkgs-channels</literal> is updated -automatically from the main <literal>nixpkgs</literal> repository -after certain tests have succeeded and binaries have been built and -uploaded to the binary cache at <uri>cache.nixos.org</uri>.)</para> +</para> </refsection> diff --git a/doc/manual/command-ref/nix-shell.xml b/doc/manual/command-ref/nix-shell.xml index 766482460..2fef323c5 100644 --- a/doc/manual/command-ref/nix-shell.xml +++ b/doc/manual/command-ref/nix-shell.xml @@ -258,7 +258,7 @@ path. You can override it by passing <option>-I</option> or setting containing the Pan package from a specific revision of Nixpkgs: <screen> -$ nix-shell -p pan -I nixpkgs=https://github.com/NixOS/nixpkgs-channels/archive/8a3eea054838b55aca962c3fbde9c83c102b8bf2.tar.gz +$ nix-shell -p pan -I nixpkgs=https://github.com/NixOS/nixpkgs/archive/8a3eea054838b55aca962c3fbde9c83c102b8bf2.tar.gz [nix-shell:~]$ pan --version Pan 0.139 @@ -352,7 +352,7 @@ following Haskell script uses a specific branch of Nixpkgs/NixOS (the <programlisting><![CDATA[ #! /usr/bin/env nix-shell #! nix-shell -i runghc -p "haskellPackages.ghcWithPackages (ps: [ps.HTTP ps.tagsoup])" -#! nix-shell -I nixpkgs=https://github.com/NixOS/nixpkgs-channels/archive/nixos-18.03.tar.gz +#! nix-shell -I nixpkgs=https://github.com/NixOS/nixpkgs/archive/nixos-18.03.tar.gz import Network.HTTP import Text.HTML.TagSoup @@ -370,7 +370,7 @@ If you want to be even more precise, you can specify a specific revision of Nixpkgs: <programlisting> -#! nix-shell -I nixpkgs=https://github.com/NixOS/nixpkgs-channels/archive/0672315759b3e15e2121365f067c1c8c56bb4722.tar.gz +#! nix-shell -I nixpkgs=https://github.com/NixOS/nixpkgs/archive/0672315759b3e15e2121365f067c1c8c56bb4722.tar.gz </programlisting> </para> diff --git a/doc/manual/command-ref/nix-store.xml b/doc/manual/command-ref/nix-store.xml index 1ddb5408d..d71f9d8e4 100644 --- a/doc/manual/command-ref/nix-store.xml +++ b/doc/manual/command-ref/nix-store.xml @@ -936,7 +936,7 @@ $ nix-store --add ./foo.c <para>The operation <option>--add-fixed</option> adds the specified paths to the Nix store. Unlike <option>--add</option> paths are registered using the -specified hashing algorithm, resulting in the same output path as a fixed output +specified hashing algorithm, resulting in the same output path as a fixed-output derivation. This can be used for sources that are not available from a public url or broke since the download expression was written. </para> diff --git a/doc/manual/command-ref/opt-common-syn.xml b/doc/manual/command-ref/opt-common-syn.xml index b610b54b9..2660e3bb1 100644 --- a/doc/manual/command-ref/opt-common-syn.xml +++ b/doc/manual/command-ref/opt-common-syn.xml @@ -1,5 +1,5 @@ <nop xmlns="http://docbook.org/ns/docbook"> - + <arg><option>--help</option></arg> <arg><option>--version</option></arg> <arg rep='repeat'> @@ -12,6 +12,10 @@ <arg choice='plain'><option>--quiet</option></arg> </arg> <arg> + <option>--log-format</option> + <replaceable>format</replaceable> +</arg> +<arg> <group choice='plain'> <arg choice='plain'><option>--no-build-output</option></arg> <arg choice='plain'><option>-Q</option></arg> diff --git a/doc/manual/command-ref/opt-common.xml b/doc/manual/command-ref/opt-common.xml index 0383bfaed..a68eef1d0 100644 --- a/doc/manual/command-ref/opt-common.xml +++ b/doc/manual/command-ref/opt-common.xml @@ -92,6 +92,37 @@ </varlistentry> +<varlistentry xml:id="opt-log-format"><term><option>--log-format</option> <replaceable>format</replaceable></term> + + <listitem> + + <para>This option can be used to change the output of the log format, with + <replaceable>format</replaceable> being one of:</para> + + <variablelist> + + <varlistentry><term>raw</term> + <listitem><para>This is the raw format, as outputted by nix-build.</para></listitem> + </varlistentry> + + <varlistentry><term>internal-json</term> + <listitem><para>Outputs the logs in a structured manner. NOTE: the json schema is not guarantees to be stable between releases.</para></listitem> + </varlistentry> + + <varlistentry><term>bar</term> + <listitem><para>Only display a progress bar during the builds.</para></listitem> + </varlistentry> + + <varlistentry><term>bar-with-logs</term> + <listitem><para>Display the raw logs, with the progress bar at the bottom.</para></listitem> + </varlistentry> + + </variablelist> + + </listitem> + +</varlistentry> + <varlistentry><term><option>--no-build-output</option> / <option>-Q</option></term> <listitem><para>By default, output written by builders to standard |