Linux – List all packages from a repository

aptcommand linelinux

I have been looking how to list all packages from a repository and I couldn't find it.

For example, I add a repository (sudo add-apt-repository ppa:noobslab/icons) and I want to list all its packages (from console).

I want to do it in a Debian based distro.

Best Answer

The packages list are in /var/lib/apt/lists/.

Check the name of the repository there.

For example, if the repository is called ppa.launchpad.net_autostatic_doubango then:

grep ^Package: /var/lib/apt/lists/ppa.launchpad.net_autostatic*_Packages

will give you the list.

You have to make an apt-get update before issuing this command to be sure that the list is updated to the latest status of the repository.