I want a list of the applications installed in my system, however, I only want the ones listed as per the start menu.
I am not interested in a list of packages / dependencies etc so the following is not that helpful:
dpkg --get-selections | grep -v deinstall
This is a bit closer.
for app in /usr/share/applications/*.desktop; do echo "${app:24:-8}"; done
However, the names don't match exactly what is in the menu and it doesn't meet my other criterion of grouping them.
e.g. I want to see
Graphics
GIMP Image Editor
not
gimp
So to summarise, what I am looking for is a way to save to a text file what Alacarte displays.
Best Answer
The python script below reads the (English or international*) interface names from all desktop files in
/usr/share/applications
, as well as theirCategories
-section. It lists all found applications, according to their categories. Since many applications do have multiple categories, applications can appear in more than one category.If the application has no
Categories=
mention, it is mentioned in theUncategorized
-section down in the list.*Note Some applications (like Thunderbird) have an extensive list of interface names, for each and every language. This script, as it is, reads the first interface name, which is the internationally used one. The script can be altered to read the name in a specific language (if present), or automatically read the system's language, but that would need a bit more extensive coding :)
To use it:
Copy the script below, past it into an empty file, save it as
applist.py
. run it by the command (in a terminal window):The script:
To give an impression of the output:
A small section of my output: