List packages installed in snap or apt repositories
Problem:
How to know if a app is installed in my computer, using Ubuntu.
Solution:
To solve it, you should get installed app list from both package managers: snap and apt.
Step by step:
- Using snap:
snap list - Using apt:
apt list --installed - For older versions of Ubuntu 14.04:
dpkg --get-selections | grep -v deinstallAnd list packages for a specific package; this example is for the postgres package:
dpkg --get-selections | grep postgres
Source:
https://manpages.ubuntu.com/manpages/noble/man8/apt.8.html
https://askubuntu.com/questions/17823/how-to-list-all-installed-packages