How to tell which repositories provide which packages?

Ralf Mardorf kde.lists at yahoo.com
Wed Jan 6 04:58:41 UTC 2021


On Wed, 2021-01-06 at 05:35 +0100, Ralf Mardorf via ubuntu-users wrote:
> I guess this does the job:
> 
> apt-cache policy $(awk '$1 == "Package:" { print $2 }' /var/lib/apt/lists/*webupd8*amd64_Packages) | grep -E Installed:\ [[:digit:]] -B1
> 
> Replace "*webupd8*amd64" by the wanted PPA.

I don't know the policy for package versioning. Perhaps it's better to
replace "[:digit:]" by "[:alnum:]", juts in case it should be allowed to
start with a letter. The main point is to get rid of packages
"Installed: (none)". It's probably not allowed to start the versioning
with a char that is neither a number, nor a letter.

[weremouse at moonstudio ~]$ apt-cache policy $(awk '$1 == "Package:" { print $2 }' /var/lib/apt/lists/*webupd8*amd64_Packages) | grep -E Installed:\ [[:alnum:]] -B1
audacious:
  Installed: 3.10-1~webupd8~xenial0
--
audacious-plugins:
  Installed: 3.10-1~webupd8~xenial0
--
audacious-plugins-data:
  Installed: 3.10-1~webupd8~xenial0
--
libampache-browser:
  Installed: 0~git20160805-1~webupd8~xenial3
--
libaudcore5:
  Installed: 3.10-1~webupd8~xenial0
--
libaudgui5:
  Installed: 3.10-1~webupd8~xenial0
--
libaudqt2:
  Installed: 3.10-1~webupd8~xenial0
--
libaudtag3:
  Installed: 3.10-1~webupd8~xenial0
--
python-twodict:
  Installed: 1.2-1~webupd8~xenial0
--
youtube-dlg:
  Installed: 0.4-1~webupd8~xenial4





More information about the ubuntu-users mailing list