Ubuntu – How to get a list of all apps in the Ubuntu Software Center

application-developmentsoftware-center

I´am playing with Software Center's API, after seeing this post on askubuntu.

My question is: how can I get a list of all Ubuntu Software Center's apps?

From the other question I get this endpoint for retrieving all apps: http://software-center.ubuntu.com/api/2.0/applications/any/ubuntu/any/any/

But the problem is it looks like it only returns 580 apps.

But on appnr.com it seems their a lot more apps in the Ubuntu Software Center?
like 30204 packages?

So then how can I get all Ubuntu Software Center's apps?

Best Answer

On local system

Using your local package management caches a simple use of some shell scripting:

apt-cache dumpavail | grep ^Package | cut -d " " -f 2 | sort | uniq

This just lists package names, so it's not the same as using the Software Centre API, but it will list all package names you can use later to query the API with, I guess. This lists 38820 packages on my system. Be aware that it may contain non-Ubuntu repository backed packages, so not all of them might be available in the SC.

Note: on amd64 systems with Multiarch enabled apt-cache will list many double ones, so that's why the uniq tool is used.


Online

Go to packages.ubuntu.com, see the section Browse through the lists of packages:, follow the link of the distribution (version), then click the link at the bottom of the page (All packages), e.g. packages.ubuntu.com/quantal/allpackages.