-<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
- "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd" [
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
+ "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
APT assigns a priority to each version that is available.
Subject to dependency constraints, <command>apt-get</command> selects the
version with the highest priority for installation.
APT assigns a priority to each version that is available.
Subject to dependency constraints, <command>apt-get</command> selects the
version with the highest priority for installation.
package versions by default, thus giving the user control over which
one is selected for installation.</para>
package versions by default, thus giving the user control over which
one is selected for installation.</para>
the &sources-list; file contains references to more than one source.
In this case <command>apt-get</command> downloads the instance listed
earliest in the &sources-list; file.
the &sources-list; file contains references to more than one source.
In this case <command>apt-get</command> downloads the instance listed
earliest in the &sources-list; file.
the choice of version.</para>
<para>Preferences are a strong power in the hands of a system administrator
but they can become also their biggest nightmare if used without care!
the choice of version.</para>
<para>Preferences are a strong power in the hands of a system administrator
but they can become also their biggest nightmare if used without care!
-Packages included in a specific release aren't tested in and
-therefore doesn't always work as expected in older or newer releases or
+Packages included in a specific release aren't tested in (and
+therefore don't always work as expected in) older or newer releases, or
together with other packages from different releases.
You have been warned.</para>
<para>Note that the files in the <filename>/etc/apt/preferences.d</filename>
directory are parsed in alphanumeric ascending order and need to obey the
together with other packages from different releases.
You have been warned.</para>
<para>Note that the files in the <filename>/etc/apt/preferences.d</filename>
directory are parsed in alphanumeric ascending order and need to obey the
-following naming convention: The files have no or "<literal>pref</literal>"
-as filename extension and which only contain alphanumeric, hyphen (-),
+following naming convention: The files have either no or "<literal>pref</literal>"
+as filename extension and only contain alphanumeric, hyphen (-),
-Otherwise APT will print a notice that it has ignored a file if the file
-doesn't match a pattern in the <literal>Dir::Ignore-Files-Silently</literal>
-configuration list - in this case it will be silently ignored.</para>
+Otherwise APT will print a notice that it has ignored a file, unless that
+file matches a pattern in the <literal>Dir::Ignore-Files-Silently</literal>
+configuration list - in which case it will be silently ignored.</para>
<term>priority 1</term>
<listitem><simpara>to the versions coming from archives which in their <filename>Release</filename>
files are marked as "NotAutomatic: yes" but <emphasis>not</emphasis> as "ButAutomaticUpgrades: yes"
<term>priority 1</term>
<listitem><simpara>to the versions coming from archives which in their <filename>Release</filename>
files are marked as "NotAutomatic: yes" but <emphasis>not</emphasis> as "ButAutomaticUpgrades: yes"
</varlistentry>
<varlistentry>
<term>priority 100</term>
<listitem><simpara>to the version that is already installed (if any) and to the versions coming
from archives which in their <filename>Release</filename> files are marked as "NotAutomatic: yes" and
</varlistentry>
<varlistentry>
<term>priority 100</term>
<listitem><simpara>to the version that is already installed (if any) and to the versions coming
from archives which in their <filename>Release</filename> files are marked as "NotAutomatic: yes" and
<simpara>The following record assigns a high priority to all package versions
belonging to any release whose Archive name is "<literal>stable</literal>"
<simpara>The following record assigns a high priority to all package versions
belonging to any release whose Archive name is "<literal>stable</literal>"
-APT also supports pinning by glob() expressions and regular
-expressions surrounded by /. For example, the following
+APT also supports pinning by &glob; expressions, and regular
+expressions surrounded by slashes. For example, the following
-experimental where the name starts with gnome (as a glob()-like
-expression or contains the word kde (as a POSIX extended regular
+experimental where the name starts with gnome (as a &glob;-like
+expression) or contains the word kde (as a POSIX extended regular
-where a string can occur. Those, the following pin assigns the
-priority 990 to all packages from a release starting with karmic.
+where a string can occur. Thus, the following pin assigns the
+priority 990 to all packages from a release starting with &ubuntu-codename;.
If a regular expression occurs in a <literal>Package</literal> field,
the behavior is the same as if this regular expression were replaced
with a list of all package names it matches. It is undecided whether
If a regular expression occurs in a <literal>Package</literal> field,
the behavior is the same as if this regular expression were replaced
with a list of all package names it matches. It is undecided whether
pins first, so later specific pins override it.
The pattern "<literal>*</literal>" in a Package field is not considered
pins first, so later specific pins override it.
The pattern "<literal>*</literal>" in a Package field is not considered
<listitem><simpara>causes a version to be installed even if this
constitutes a downgrade of the package</simpara></listitem>
</varlistentry>
<varlistentry>
<listitem><simpara>causes a version to be installed even if this
constitutes a downgrade of the package</simpara></listitem>
</varlistentry>
<varlistentry>
<listitem><simpara>causes a version to be installed
even if it does not come from the target release,
unless the installed version is more recent</simpara></listitem>
</varlistentry>
<varlistentry>
<listitem><simpara>causes a version to be installed
even if it does not come from the target release,
unless the installed version is more recent</simpara></listitem>
</varlistentry>
<varlistentry>
<listitem><simpara>causes a version to be installed
unless there is a version available belonging to the target release
or the installed version is more recent</simpara></listitem>
</varlistentry>
<varlistentry>
<listitem><simpara>causes a version to be installed
unless there is a version available belonging to the target release
or the installed version is more recent</simpara></listitem>
</varlistentry>
<varlistentry>
<listitem><simpara>causes a version to be installed
unless there is a version available belonging to some other
distribution or the installed version is more recent</simpara></listitem>
</varlistentry>
<varlistentry>
<listitem><simpara>causes a version to be installed
unless there is a version available belonging to some other
distribution or the installed version is more recent</simpara></listitem>
</varlistentry>
<varlistentry>
<listitem><simpara>causes a version to be installed
only if there is no installed version of the package</simpara></listitem>
</varlistentry>
<listitem><simpara>causes a version to be installed
only if there is no installed version of the package</simpara></listitem>
</varlistentry>
<itemizedlist>
<listitem><simpara>The most recent available version of the <literal>perl</literal>
package will be installed, so long as that version's version number begins
<itemizedlist>
<listitem><simpara>The most recent available version of the <literal>perl</literal>
package will be installed, so long as that version's version number begins
-with "<literal>5.8</literal>". If <emphasis>any</emphasis> 5.8* version of <literal>perl</literal> is
-available and the installed version is 5.9*, then <literal>perl</literal> will be
+with "<literal>&good-perl;</literal>". If <emphasis>any</emphasis> &good-perl;* version of <literal>perl</literal> is
+available and the installed version is &bad-perl;*, then <literal>perl</literal> will be
downgraded.</simpara></listitem>
<listitem><simpara>A version of any package other than <literal>perl</literal>
that is available from the local system has priority over other versions,
downgraded.</simpara></listitem>
<listitem><simpara>A version of any package other than <literal>perl</literal>
that is available from the local system has priority over other versions,
<varlistentry>
<term>the <literal>Version:</literal> line</term>
<listitem><simpara>names the release version. For example, the
<varlistentry>
<term>the <literal>Version:</literal> line</term>
<listitem><simpara>names the release version. For example, the
-packages in the tree might belong to Debian GNU/Linux release
-version 3.0. Note that there is normally no version number for the
+packages in the tree might belong to Debian release
+version &stable-version;. Note that there is normally no version number for the
<literal>testing</literal> and <literal>unstable</literal> distributions because they
have not been released yet. Specifying this in the APT preferences
file would require one of the following lines.
</simpara>
<programlisting>
<literal>testing</literal> and <literal>unstable</literal> distributions because they
have not been released yet. Specifying this in the APT preferences
file would require one of the following lines.
</simpara>
<programlisting>
-Pin: release v=3.0
-Pin: release a=stable, v=3.0
-Pin: release 3.0
+Pin: release v=&stable-version;
+Pin: release a=stable, v=&stable-version;
+Pin: release &stable-version;