1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-13 17:10:47 +02:00

<replaceable> -> <emphasis>

Pandoc doesn't know <replaceable> so let's force it to be rendered as
italics.
This commit is contained in:
Eelco Dolstra 2020-07-23 14:28:05 +02:00
parent ee05108472
commit 802150f987
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE
76 changed files with 1029 additions and 1020 deletions

View file

@ -91,12 +91,12 @@ disallowedRequisites = [ foobar ];
references graph of their inputs. The attribute is a list of
inputs in the Nix store whose references graph the builder needs
to know. The value of this attribute should be a list of pairs
<literal>[ <replaceable>name1</replaceable>
<replaceable>path1</replaceable> <replaceable>name2</replaceable>
<replaceable>path2</replaceable> <replaceable>...</replaceable>
<literal>[ <emphasis>name1</emphasis>
<emphasis>path1</emphasis> <emphasis>name2</emphasis>
<emphasis>path2</emphasis> <emphasis>...</emphasis>
]</literal>. The references graph of each
<replaceable>pathN</replaceable> will be stored in a text file
<replaceable>nameN</replaceable> in the temporary build directory.
<emphasis>pathN</emphasis> will be stored in a text file
<emphasis>nameN</emphasis> in the temporary build directory.
The text files have the format used by <command>nix-store
--register-validity</command> (with the deriver fields left
empty). For example, when the following derivation is built:
@ -135,7 +135,7 @@ derivation {
Nixpkgs has the line
<programlisting>
impureEnvVars = [ "http_proxy" "https_proxy" <replaceable>...</replaceable> ];
impureEnvVars = [ "http_proxy" "https_proxy" <emphasis>...</emphasis> ];
</programlisting>
to make it use the proxy server configuration specified by the
@ -297,11 +297,11 @@ big = "a very long string";
<literal>bigPath</literal> will contain the absolute path to a
temporary file containing <literal>a very long
string</literal>. That is, for any attribute
<replaceable>x</replaceable> listed in
<emphasis>x</emphasis> listed in
<varname>passAsFile</varname>, Nix will pass an environment
variable <literal><replaceable>x</replaceable>Path</literal> holding
variable <literal><emphasis>x</emphasis>Path</literal> holding
the path of the file containing the value of attribute
<replaceable>x</replaceable>. This is useful when you need to pass
<emphasis>x</emphasis>. This is useful when you need to pass
large strings to a builder, since most operating systems impose a
limit on the size of the environment (typically, a few hundred
kilobyte).</para></listitem>

View file

@ -58,7 +58,7 @@ steps:</para>
the <literal>PATH</literal>. The <literal>perl</literal> environment
variable points to the location of the Perl package (since it
was passed in as an attribute to the derivation), so
<filename><replaceable>$perl</replaceable>/bin</filename> is the
<filename><emphasis>$perl</emphasis>/bin</filename> is the
directory containing the Perl interpreter.</para>
</listitem>

File diff suppressed because it is too large Load diff

View file

@ -50,7 +50,7 @@ the single Nix expression in that directory
<para>Nix functions generally have the form <literal>{ x, y, ...,
z }: e</literal> where <varname>x</varname>, <varname>y</varname>,
etc. are the names of the expected arguments, and where
<replaceable>e</replaceable> is the body of the function. So
<emphasis>e</emphasis> is the body of the function. So
here, the entire remainder of the file is the body of the
function; when given the required arguments, the body should
describe how to build an instance of the Hello package.</para>
@ -69,10 +69,10 @@ the single Nix expression in that directory
<emphasis>attributes</emphasis>. A set is just a list of
key/value pairs where each key is a string and each value is an
arbitrary Nix expression. They take the general form <literal>{
<replaceable>name1</replaceable> =
<replaceable>expr1</replaceable>; <replaceable>...</replaceable>
<replaceable>nameN</replaceable> =
<replaceable>exprN</replaceable>; }</literal>.</para>
<emphasis>name1</emphasis> =
<emphasis>expr1</emphasis>; <emphasis>...</emphasis>
<emphasis>nameN</emphasis> =
<emphasis>exprN</emphasis>; }</literal>.</para>
</listitem>

View file

@ -44,7 +44,7 @@ genericBuild ③</programlisting>
subdirectory, it's added to GCC's header search path; and so
on.<footnote><para>How does it work? <filename>setup</filename>
tries to source the file
<filename><replaceable>pkg</replaceable>/nix-support/setup-hook</filename>
<filename><emphasis>pkg</emphasis>/nix-support/setup-hook</filename>
of all dependencies. These “setup hooks” can then set up whatever
environment variables they want; for instance, the setup hook for
Perl sets the <literal>PERL5LIB</literal> environment variable to

View file

@ -137,7 +137,7 @@ while defining a set.</para>
<para>Functions have the following form:
<programlisting>
<replaceable>pattern</replaceable>: <replaceable>body</replaceable></programlisting>
<emphasis>pattern</emphasis>: <emphasis>body</emphasis></programlisting>
The pattern specifies what the argument of the function must look
like, and binds variables in the body to (parts of) the
@ -190,9 +190,9 @@ map (concat "foo") [ "bar" "bla" "abc" ]</programlisting>
<para>It is possible to provide <emphasis>default values</emphasis>
for attributes, in which case they are allowed to be missing. A
default value is specified by writing
<literal><replaceable>name</replaceable> ?
<replaceable>e</replaceable></literal>, where
<replaceable>e</replaceable> is an arbitrary expression. For example,
<literal><emphasis>name</emphasis> ?
<emphasis>e</emphasis></literal>, where
<emphasis>e</emphasis> is an arbitrary expression. For example,
<programlisting>
{ x, y ? "foo", z ? "bar" }: z + y + x</programlisting>
@ -256,9 +256,9 @@ in concat { x = "foo"; y = "bar"; }</programlisting>
<para>Conditionals look like this:
<programlisting>
if <replaceable>e1</replaceable> then <replaceable>e2</replaceable> else <replaceable>e3</replaceable></programlisting>
if <emphasis>e1</emphasis> then <emphasis>e2</emphasis> else <emphasis>e3</emphasis></programlisting>
where <replaceable>e1</replaceable> is an expression that should
where <emphasis>e1</emphasis> is an expression that should
evaluate to a Boolean value (<literal>true</literal> or
<literal>false</literal>).</para>
@ -271,11 +271,11 @@ evaluate to a Boolean value (<literal>true</literal> or
on or between features and dependencies hold. They look like this:
<programlisting>
assert <replaceable>e1</replaceable>; <replaceable>e2</replaceable></programlisting>
assert <emphasis>e1</emphasis>; <emphasis>e2</emphasis></programlisting>
where <replaceable>e1</replaceable> is an expression that should
where <emphasis>e1</emphasis> is an expression that should
evaluate to a Boolean value. If it evaluates to
<literal>true</literal>, <replaceable>e2</replaceable> is returned;
<literal>true</literal>, <emphasis>e2</emphasis> is returned;
otherwise expression evaluation is aborted and a backtrace is printed.</para>
<para>Here is a Nix expression for the Subversion package that shows
@ -358,10 +358,10 @@ stdenv.mkDerivation {
<para>A <emphasis>with-expression</emphasis>,
<programlisting>
with <replaceable>e1</replaceable>; <replaceable>e2</replaceable></programlisting>
with <emphasis>e1</emphasis>; <emphasis>e2</emphasis></programlisting>
introduces the set <replaceable>e1</replaceable> into the lexical
scope of the expression <replaceable>e2</replaceable>. For instance,
introduces the set <emphasis>e1</emphasis> into the lexical
scope of the expression <emphasis>e2</emphasis>. For instance,
<programlisting>
let as = { x = "foo"; y = "bar"; };

View file

@ -25,48 +25,48 @@ weakest binding).</para>
<tbody>
<row>
<entry>Select</entry>
<entry><replaceable>e</replaceable> <literal>.</literal>
<replaceable>attrpath</replaceable>
[ <literal>or</literal> <replaceable>def</replaceable> ]
<entry><emphasis>e</emphasis> <literal>.</literal>
<emphasis>attrpath</emphasis>
[ <literal>or</literal> <emphasis>def</emphasis> ]
</entry>
<entry>none</entry>
<entry>Select attribute denoted by the attribute path
<replaceable>attrpath</replaceable> from set
<replaceable>e</replaceable>. (An attribute path is a
<emphasis>attrpath</emphasis> from set
<emphasis>e</emphasis>. (An attribute path is a
dot-separated list of attribute names.) If the attribute
doesnt exist, return <replaceable>def</replaceable> if
doesnt exist, return <emphasis>def</emphasis> if
provided, otherwise abort evaluation.</entry>
<entry>1</entry>
</row>
<row>
<entry>Application</entry>
<entry><replaceable>e1</replaceable> <replaceable>e2</replaceable></entry>
<entry><emphasis>e1</emphasis> <emphasis>e2</emphasis></entry>
<entry>left</entry>
<entry>Call function <replaceable>e1</replaceable> with
argument <replaceable>e2</replaceable>.</entry>
<entry>Call function <emphasis>e1</emphasis> with
argument <emphasis>e2</emphasis>.</entry>
<entry>2</entry>
</row>
<row>
<entry>Arithmetic Negation</entry>
<entry><literal>-</literal> <replaceable>e</replaceable></entry>
<entry><literal>-</literal> <emphasis>e</emphasis></entry>
<entry>none</entry>
<entry>Arithmetic negation.</entry>
<entry>3</entry>
</row>
<row>
<entry>Has Attribute</entry>
<entry><replaceable>e</replaceable> <literal>?</literal>
<replaceable>attrpath</replaceable></entry>
<entry><emphasis>e</emphasis> <literal>?</literal>
<emphasis>attrpath</emphasis></entry>
<entry>none</entry>
<entry>Test whether set <replaceable>e</replaceable> contains
the attribute denoted by <replaceable>attrpath</replaceable>;
<entry>Test whether set <emphasis>e</emphasis> contains
the attribute denoted by <emphasis>attrpath</emphasis>;
return <literal>true</literal> or
<literal>false</literal>.</entry>
<entry>4</entry>
</row>
<row>
<entry>List Concatenation</entry>
<entry><replaceable>e1</replaceable> <literal>++</literal> <replaceable>e2</replaceable></entry>
<entry><emphasis>e1</emphasis> <literal>++</literal> <emphasis>e2</emphasis></entry>
<entry>right</entry>
<entry>List concatenation.</entry>
<entry>5</entry>
@ -74,7 +74,7 @@ weakest binding).</para>
<row>
<entry>Multiplication</entry>
<entry>
<replaceable>e1</replaceable> <literal>*</literal> <replaceable>e2</replaceable>,
<emphasis>e1</emphasis> <literal>*</literal> <emphasis>e2</emphasis>,
</entry>
<entry>left</entry>
<entry>Arithmetic multiplication.</entry>
@ -83,7 +83,7 @@ weakest binding).</para>
<row>
<entry>Division</entry>
<entry>
<replaceable>e1</replaceable> <literal>/</literal> <replaceable>e2</replaceable>
<emphasis>e1</emphasis> <literal>/</literal> <emphasis>e2</emphasis>
</entry>
<entry>left</entry>
<entry>Arithmetic division.</entry>
@ -92,7 +92,7 @@ weakest binding).</para>
<row>
<entry>Addition</entry>
<entry>
<replaceable>e1</replaceable> <literal>+</literal> <replaceable>e2</replaceable>
<emphasis>e1</emphasis> <literal>+</literal> <emphasis>e2</emphasis>
</entry>
<entry>left</entry>
<entry>Arithmetic addition.</entry>
@ -101,7 +101,7 @@ weakest binding).</para>
<row>
<entry>Subtraction</entry>
<entry>
<replaceable>e1</replaceable> <literal>-</literal> <replaceable>e2</replaceable>
<emphasis>e1</emphasis> <literal>-</literal> <emphasis>e2</emphasis>
</entry>
<entry>left</entry>
<entry>Arithmetic subtraction.</entry>
@ -110,7 +110,7 @@ weakest binding).</para>
<row>
<entry>String Concatenation</entry>
<entry>
<replaceable>string1</replaceable> <literal>+</literal> <replaceable>string2</replaceable>
<emphasis>string1</emphasis> <literal>+</literal> <emphasis>string2</emphasis>
</entry>
<entry>left</entry>
<entry>String concatenation.</entry>
@ -118,19 +118,19 @@ weakest binding).</para>
</row>
<row>
<entry>Not</entry>
<entry><literal>!</literal> <replaceable>e</replaceable></entry>
<entry><literal>!</literal> <emphasis>e</emphasis></entry>
<entry>none</entry>
<entry>Boolean negation.</entry>
<entry>8</entry>
</row>
<row>
<entry>Update</entry>
<entry><replaceable>e1</replaceable> <literal>//</literal>
<replaceable>e2</replaceable></entry>
<entry><emphasis>e1</emphasis> <literal>//</literal>
<emphasis>e2</emphasis></entry>
<entry>right</entry>
<entry>Return a set consisting of the attributes in
<replaceable>e1</replaceable> and
<replaceable>e2</replaceable> (with the latter taking
<emphasis>e1</emphasis> and
<emphasis>e2</emphasis> (with the latter taking
precedence over the former in case of equally named
attributes).</entry>
<entry>9</entry>
@ -138,7 +138,7 @@ weakest binding).</para>
<row>
<entry>Less Than</entry>
<entry>
<replaceable>e1</replaceable> <literal>&lt;</literal> <replaceable>e2</replaceable>,
<emphasis>e1</emphasis> <literal>&lt;</literal> <emphasis>e2</emphasis>,
</entry>
<entry>none</entry>
<entry>Arithmetic comparison.</entry>
@ -147,7 +147,7 @@ weakest binding).</para>
<row>
<entry>Less Than or Equal To</entry>
<entry>
<replaceable>e1</replaceable> <literal>&lt;=</literal> <replaceable>e2</replaceable>
<emphasis>e1</emphasis> <literal>&lt;=</literal> <emphasis>e2</emphasis>
</entry>
<entry>none</entry>
<entry>Arithmetic comparison.</entry>
@ -156,7 +156,7 @@ weakest binding).</para>
<row>
<entry>Greater Than</entry>
<entry>
<replaceable>e1</replaceable> <literal>&gt;</literal> <replaceable>e2</replaceable>
<emphasis>e1</emphasis> <literal>&gt;</literal> <emphasis>e2</emphasis>
</entry>
<entry>none</entry>
<entry>Arithmetic comparison.</entry>
@ -165,7 +165,7 @@ weakest binding).</para>
<row>
<entry>Greater Than or Equal To</entry>
<entry>
<replaceable>e1</replaceable> <literal>&gt;=</literal> <replaceable>e2</replaceable>
<emphasis>e1</emphasis> <literal>&gt;=</literal> <emphasis>e2</emphasis>
</entry>
<entry>none</entry>
<entry>Arithmetic comparison.</entry>
@ -174,7 +174,7 @@ weakest binding).</para>
<row>
<entry>Equality</entry>
<entry>
<replaceable>e1</replaceable> <literal>==</literal> <replaceable>e2</replaceable>
<emphasis>e1</emphasis> <literal>==</literal> <emphasis>e2</emphasis>
</entry>
<entry>none</entry>
<entry>Equality.</entry>
@ -183,7 +183,7 @@ weakest binding).</para>
<row>
<entry>Inequality</entry>
<entry>
<replaceable>e1</replaceable> <literal>!=</literal> <replaceable>e2</replaceable>
<emphasis>e1</emphasis> <literal>!=</literal> <emphasis>e2</emphasis>
</entry>
<entry>none</entry>
<entry>Inequality.</entry>
@ -191,28 +191,28 @@ weakest binding).</para>
</row>
<row>
<entry>Logical AND</entry>
<entry><replaceable>e1</replaceable> <literal>&amp;&amp;</literal>
<replaceable>e2</replaceable></entry>
<entry><emphasis>e1</emphasis> <literal>&amp;&amp;</literal>
<emphasis>e2</emphasis></entry>
<entry>left</entry>
<entry>Logical AND.</entry>
<entry>12</entry>
</row>
<row>
<entry>Logical OR</entry>
<entry><replaceable>e1</replaceable> <literal>||</literal>
<replaceable>e2</replaceable></entry>
<entry><emphasis>e1</emphasis> <literal>||</literal>
<emphasis>e2</emphasis></entry>
<entry>left</entry>
<entry>Logical OR.</entry>
<entry>13</entry>
</row>
<row>
<entry>Logical Implication</entry>
<entry><replaceable>e1</replaceable> <literal>-></literal>
<replaceable>e2</replaceable></entry>
<entry><emphasis>e1</emphasis> <literal>-></literal>
<emphasis>e2</emphasis></entry>
<entry>none</entry>
<entry>Logical implication (equivalent to
<literal>!<replaceable>e1</replaceable> ||
<replaceable>e2</replaceable></literal>).</entry>
<literal>!<emphasis>e1</emphasis> ||
<emphasis>e2</emphasis></literal>).</entry>
<entry>14</entry>
</row>
</tbody>

View file

@ -30,7 +30,7 @@
<para>You can include the result of an expression into a string by
enclosing it in
<literal>${<replaceable>...</replaceable>}</literal>, a feature
<literal>${<emphasis>...</emphasis>}</literal>, a feature
known as <emphasis>antiquotation</emphasis>. The enclosed
expression must evaluate to something that can be coerced into a
string (meaning that it must be a string, a path, or a
@ -93,7 +93,7 @@ configureFlags = "
text on the initial line.</para>
<para>Antiquotation
(<literal>${<replaceable>expr</replaceable>}</literal>) is
(<literal>${<emphasis>expr</emphasis>}</literal>) is
supported in indented strings.</para>
<para>Since <literal>${</literal> and <literal>''</literal> have
@ -119,7 +119,7 @@ configureFlags = "
<programlisting>
stdenv.mkDerivation {
<replaceable>...</replaceable>
<emphasis>...</emphasis>
postInstall =
''
mkdir $out/bin $out/etc
@ -127,7 +127,7 @@ stdenv.mkDerivation {
echo "Hello World" > $out/etc/foo.conf
${if enableBar then "cp bar $out/bin" else ""}
'';
<replaceable>...</replaceable>
<emphasis>...</emphasis>
}
</programlisting>

View file

@ -19,7 +19,7 @@ building path `/nix/store/632d2b22514d...-hello-2.1.1'
hello-2.1.1/
hello-2.1.1/intl/
hello-2.1.1/intl/ChangeLog
<replaceable>...</replaceable>
<emphasis>...</emphasis>
$ ls -l result
lrwxrwxrwx ... 2006-09-29 10:43 result -> /nix/store/632d2b22514d...-hello-2.1.1