X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/259d88d94843fbce7c8100f8b337b7b8fb58b840..e93b4028825648bb29074a1422287e2cb435b0de:/doc/apt_preferences.5.xml diff --git a/doc/apt_preferences.5.xml b/doc/apt_preferences.5.xml index d8c3efab7..79132e007 100644 --- a/doc/apt_preferences.5.xml +++ b/doc/apt_preferences.5.xml @@ -1,15 +1,9 @@ <?xml version="1.0" encoding="utf-8" standalone="no"?> <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [ - -<!ENTITY % aptent SYSTEM "apt.ent"> -%aptent; - -<!ENTITY % aptverbatiment SYSTEM "apt-verbatim.ent"> -%aptverbatiment; - -<!ENTITY % aptvendor SYSTEM "apt-vendor.ent"> -%aptvendor; +<!ENTITY % aptent SYSTEM "apt.ent"> %aptent; +<!ENTITY % aptverbatiment SYSTEM "apt-verbatim.ent"> %aptverbatiment; +<!ENTITY % aptvendor SYSTEM "apt-vendor.ent"> %aptvendor; ]> <refentry> @@ -121,14 +115,17 @@ from archives which in their <filename>Release</filename> files are marked as "N <varlistentry> <term>priority 500</term> -<listitem><simpara>to the versions that are not installed and do not belong to the target release.</simpara></listitem> +<listitem><simpara>to the versions that do not belong to the target release.</simpara></listitem> </varlistentry> <varlistentry> <term>priority 990</term> -<listitem><simpara>to the versions that are not installed and belong to the target release.</simpara></listitem> +<listitem><simpara>to the versions that belong to the target release.</simpara></listitem> </varlistentry> </variablelist> + +The highest of those priorities whose description matches the version is assigned to the +version. </para> <para>If the target release has not been specified then APT simply assigns @@ -257,6 +254,11 @@ Pin-Priority: 500 </programlisting> </listitem> </itemizedlist> + +The effect of the comma operator is similar to an "and" in logic: All +conditions must be satisfied for the pin to match. There is one exception: +For any type of condition (such as two "a" conditions), only the last such +condition is checked. </para> </refsect2> @@ -273,7 +275,7 @@ expression surrounded by slashes). <programlisting> Package: gnome* /kde/ -Pin: release n=experimental +Pin: release a=experimental Pin-Priority: 500 </programlisting> @@ -345,14 +347,21 @@ only if there is no installed version of the package</simpara></listitem> <term>P < 0</term> <listitem><simpara>prevents the version from being installed</simpara></listitem> </varlistentry> +<varlistentry> +<term>P = 0</term> +<listitem><simpara>has undefined behaviour, do not use it.</simpara></listitem> +</varlistentry> </variablelist> </para> -<para>If any specific-form records match an available package version then the -first such record determines the priority of the package version. -Failing that, -if any general-form records match an available package version then the -first such record determines the priority of the package version.</para> +<para> +The first specific-form record matching an available package version determines +the priority of the package version. +Failing that, the priority of the package is defined as the maximum of all +priorities defined by generic-form records matching the version. +Records defined using patterns in the Pin field other than "*" are treated like +specific-form records. +</para> <para>For example, suppose the APT preferences file contains the three records presented earlier:</para>