PDA

View Full Version : [all variants] Repos, sources.list, package list



m666
February 27th, 2013, 02:49 PM
How can I list all packages from certain repository?
I'd like to check what packages are in partner or extras repos

deb http://archive.canonical.com/ubuntu quantal partner

deb http://extras.ubuntu.com/ubuntu quantal main

I think there must be some 'apt-something' command to do this :confused:

dino99
February 27th, 2013, 02:51 PM
the easiest way: use synaptic

schragge
February 27th, 2013, 03:40 PM
+1 to use synaptic.
Anything involving command-line would be pretty well... involved, even if using tools like grep-dctrl(1) (http://manpages.ubuntu.com/manpages/precise/en/man1/grep-dctrl.1.html) or dpkg-awk(1) (http://manpages.ubuntu.com/manpages/precise/en/man1/dpkg-awk.1.html).

E.g. for partner this should be something like


sed -n 's/^Package: *//p' /var/lib/apt/lists/*partner_binary-*_Packages|sort -u


For extras,


sed -n 's/^Package: *//p' /var/lib/apt/lists/extras.*main_binary-*_Packages|sort -u


The exact syntax depends on what you have in your /etc/apt/sources.list

m666
February 27th, 2013, 04:08 PM
It's minimal CLI-install. No synaptic.


@schragge


sed -n 's/^Package: *//p' /var/lib/apt/lists/liquorix.net_debian_dists_sid_main_binary-i386_Packages|sort -u

Thanks! I don't understand the syntax hahaha but it works.