Knowledge Base - Debian/Ubuntu Package Management Commands1

Use dpkg-query to see if a package is installed

dpkg-query --show some_package

To find the packages that were installed or upgraded during your last update session,

awk '/^Start-Date:/{print "\n" $0; next} /^Commandline:|^Requested-By:|^Install:|^Upgrade:|^Remove:/{print}' /var/log/apt/history.log | tail -n 20
NULL