To view all available repositories and PPAs configured on Ubuntu, you can use apt-cache command. This command is typically used to query local APT package cache to obtain various package/repository related meta data.
In particular, used with policy option, apt-cache command retrieves priorities associated with each repository resource. From its output, you can infer a list of all available repositories and PPAs.
The above output shows a list of repository sources and their priorities (first column). This output lists duplicate sources (e.g., for 32-bit and 64-bit packages).
To discount the duplicates and get a more human-readable list of repositories, you can refine the above output as follows.
As exemplified above, the repository list includes third party repositories, PPAs and base repositories.
Subscribe to Ask Xmodulo
Do you want to receive Linux related questions & answers published at Ask Xmodulo? Enter your email address below, and we will deliver our Linux Q&A straight to your email box, for free. Delivery powered by Google Feedburner.
Did you find this tutorial helpful? Then please be generous and support Xmodulo!