Linux/Ubuntu: Get ordered list of all installed packages

PHOTO EMBED

Sun Aug 28 2022 12:00:14 GMT+0000 (Coordinated Universal Time)

Saved by @marcopinero #bash

$ comm -13 \
  <(gzip -dc /var/log/installer/initial-status.gz | sed -n 's/^Package: //p' | sort) \
  <(comm -23 \
    <(dpkg-query -W -f='${Package}\n' | sed 1d | sort) \
    <(apt-mark showauto | sort) \
  )
content_copyCOPY

In Ubuntu, with this command you can list all packages installed. If you write something like: " > user-installed-packages.txt" at the end of command the output can be saved in text file.