The apt package manager allows management of all installed packages and the installation of new software on a Linux system. It also allows the retrieval of information about installed packages.
To list all installed packages, run this command. This does not require sudo or su.
jason$ apt list --installed |
This will be a very long listing, so maybe redirect it into a text file for later reading.
jason$ apt list --installed > packages.txt WARNING: apt does not have a stable CLI interface. Use with caution in scripts. |
This is a sample of what you will get.
jason$ head -n 20 packages.txt Listing... a11y-profile-manager-indicator/xenial,now 0.1.10-0ubuntu3 amd64 [installed,automatic] account-plugin-facebook/xenial,xenial,now 0.12+16.04.20160126-0ubuntu1 all [installed,automatic] account-plugin-flickr/xenial,xenial,now 0.12+16.04.20160126-0ubuntu1 all [installed,automatic] account-plugin-google/xenial,xenial,now 0.12+16.04.20160126-0ubuntu1 all [installed,automatic] accountsservice/xenial-updates,now 0.6.40-2ubuntu11.2 amd64 [installed,automatic] acl/xenial,now 2.2.52-3 amd64 [installed,automatic] acpi-support/xenial,now 0.142 amd64 [installed,automatic] acpid/xenial,now 1:2.0.26-1ubuntu2 amd64 [installed,automatic] activity-log-manager/xenial,now 0.9.7-0ubuntu23 amd64 [installed,automatic] adduser/xenial,xenial,now 3.113+nmu3ubuntu4 all [installed] adium-theme-ubuntu/xenial-updates,xenial-updates,now 0.3.4-0ubuntu1.1 all [installed,automatic] adwaita-icon-theme/xenial-updates,xenial-updates,now 3.18.0-2ubuntu3.1 all [installed,automatic] aften/xenial,now 0.0.8+git20100105-0ubuntu2 amd64 [installed,automatic] aircrack-ng/xenial,now 1:1.2-0~beta3-4 amd64 [installed,automatic] aisleriot/xenial,now 1:3.18.2-1ubuntu1 amd64 [installed,automatic] alsa-base/xenial,xenial,now 1.0.25+dfsg-0ubuntu5 all [installed,automatic] alsa-utils/xenial,now 1.1.0-0ubuntu5 amd64 [installed,automatic] anacron/xenial,now 2.3-23 amd64 [installed,automatic] apache2-bin/xenial-updates,xenial-security,now 2.4.18-2ubuntu3.1 amd64 [installed,automatic] |
This is how to print just the package names in a very long listing.
jason$ apt list --installed | sed 's/\|/ /'|awk '{print $1}' | perl -n -e 'print unless $. == 1' > packages.txt WARNING: apt does not have a stable CLI interface. Use with caution in scripts. |