X-Git-Url: https://git.saurik.com/apt.git/blobdiff_plain/1b4560fec66a6e7b2dff9aaa19095fb8423f69a0..7c1dca1439b956a085b09c73fdbe5a66af20241b:/doc/apt_preferences.5.xml?ds=inline diff --git a/doc/apt_preferences.5.xml b/doc/apt_preferences.5.xml index d8c3efab7..cac9a96e1 100644 --- a/doc/apt_preferences.5.xml +++ b/doc/apt_preferences.5.xml @@ -1,15 +1,9 @@ -%aptent; - - -%aptverbatiment; - - -%aptvendor; + %aptent; + %aptverbatiment; + %aptvendor; ]> @@ -19,7 +13,7 @@ &apt-email; &apt-product; - 2012-06-09T00:00:00Z + 2015-08-15T00:00:00Z @@ -121,14 +115,17 @@ from archives which in their Release files are marked as "N priority 500 -to the versions that are not installed and do not belong to the target release. +to the versions that do not belong to the target release. priority 990 -to the versions that are not installed and belong to the target release. +to the versions that belong to the target release. + +The highest of those priorities whose description matches the version is assigned to the +version. If the target release has not been specified then APT simply assigns @@ -238,25 +235,30 @@ Pin-Priority: 50 The following record assigns a high priority to all package versions -belonging to any distribution whose Codename is "&testing-codename;". +belonging to any distribution whose Codename is "&debian-testing-codename;". Package: * -Pin: release n=&testing-codename; +Pin: release n=&debian-testing-codename; Pin-Priority: 900 The following record assigns a high priority to all package versions belonging to any release whose Archive name is "stable" -and whose release Version number is "&stable-version;". +and whose release Version number is "&debian-stable-version;". Package: * -Pin: release a=stable, v=&stable-version; +Pin: release a=stable, v=&debian-stable-version; Pin-Priority: 500 + +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. @@ -273,7 +275,7 @@ expression surrounded by slashes). Package: gnome* /kde/ -Pin: release n=experimental +Pin: release a=experimental Pin-Priority: 500 @@ -345,14 +347,21 @@ only if there is no installed version of the package P < 0 prevents the version from being installed + +P = 0 +has undefined behaviour, do not use it. + -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. + +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. + For example, suppose the APT preferences file contains the three records presented earlier: @@ -419,7 +428,7 @@ APT priorities: The Release file is normally found in the directory .../dists/dist-name: for example, .../dists/stable/Release, -or .../dists/&stable-codename;/Release. +or .../dists/&debian-stable-codename;/Release. It consists of a single multi-line record which applies to all of the packages in the directory tree below its parent. Unlike the Packages file, nearly all of the lines in a Release @@ -447,14 +456,14 @@ Pin: release a=stable the Codename: line names the codename to which all the packages in the directory tree belong. For example, the line -"Codename: &testing-codename;" +"Codename: &debian-testing-codename;" specifies that all of the packages in the directory tree below the parent of the Release file belong to a version named -&testing-codename;. Specifying this value in the APT preferences file +&debian-testing-codename;. Specifying this value in the APT preferences file would require the line: -Pin: release n=&testing-codename; +Pin: release n=&debian-testing-codename; @@ -463,16 +472,16 @@ Pin: release n=&testing-codename; the Version: line names the release version. For example, the packages in the tree might belong to Debian release -version &stable-version;. Note that there is normally no version number for the +version &debian-stable-version;. Note that there is normally no version number for the testing and unstable distributions because they have not been released yet. Specifying this in the APT preferences file would require one of the following lines. -Pin: release v=&stable-version; -Pin: release a=stable, v=&stable-version; -Pin: release &stable-version; +Pin: release v=&debian-stable-version; +Pin: release a=stable, v=&debian-stable-version; +Pin: release &debian-stable-version; @@ -654,9 +663,9 @@ the example configurations above. Explanation: Uninstall or do not install any Debian-originated package versions -Explanation: other than those in the distribution codenamed with &testing-codename; or sid +Explanation: other than those in the distribution codenamed with &debian-testing-codename; or sid Package: * -Pin: release n=&testing-codename; +Pin: release n=&debian-testing-codename; Pin-Priority: 900 Explanation: Debian unstable is always codenamed with sid @@ -672,7 +681,7 @@ Pin-Priority: -10 With a suitable &sources-list; file and the above preferences file, any of the following commands will cause APT to upgrade to the -latest version(s) in the release codenamed with &testing-codename;. +latest version(s) in the release codenamed with &debian-testing-codename;. apt-get install package-name @@ -684,7 +693,7 @@ apt-get dist-upgrade The following command will cause APT to upgrade the specified package to the latest version from the sid distribution. Thereafter, apt-get upgrade will upgrade -the package to the most recent &testing-codename; version if that is +the package to the most recent &debian-testing-codename; version if that is more recent than the installed version, otherwise, to the most recent sid version if that is more recent than the installed version.