I have two repositories with one package "libtidy-dev":
$ apt-cache policy libtidy-dev
libtidy-dev:
Installed: 20091223cvs-1.2ubuntu1.1
Candidate: 1:5.2.0-1+deb.sury.org~trusty+1
Фиксатор пакета: 1:5.2.0-1+deb.sury.org~trusty+1
Version table:
1:5.2.0-1+deb.sury.org~trusty+1 400
500 http://ppa.launchpad.net/ondrej/php/ubuntu/ trusty/main amd64 Packages
*** 20091223cvs-1.2ubuntu1.1 400
500 http://archive.ubuntu.com/ubuntu/ trusty-updates/main amd64 Packages
500 http://security.ubuntu.com/ubuntu/ trusty-security/main amd64 Packages
100 /var/lib/dpkg/status
20091223cvs-1.2ubuntu1 400
500 http://archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages
I want to set priority for package "libtidy-dev" of "ppa:ondrey/php" repository to 400. So I created /etc/apt/preferences.d/libtidy-dev.pref with this content:
Package: libtidy-dev
Pin: release o=LP-PPA-ondrej-php
Pin-Priority: 400
But it doesn't work. If i replace first row
Package: *
Pin: release o=LP-PPA-ondrej-php
Pin-Priority: 400
it will works but for all packages from this repo. I dont't need to reduce priority for all packages, I want to do this only for "libtidy-dev". So I tried another way. I wrote to pref file this:
Package: libtidy-dev
Pin: origin archive.ubuntu.com
Pin-Priority: 990
Package: libtidy-dev
Pin: origin security.ubuntu.com
Pin-Priority: 990
This config does the same thing. If first row has package name it not works, but if I specify asterisk instead of package name, it works but for all packaes of these repos. What I'm doing wrong? How to set priority for one package of one repository?