martonsz of Tempus
11/29/2017 - 8:15 AM

List upgradable packages with APT

List upgradable packages with APT

# With apt
apt list --upgradable
#!/bin/bash
# With apt-get

# -------------------------
# alternative 1
# -------------------------
sudo apt-get upgrade -s | grep "Inst"

# -------------------------
# alternative 2
# -------------------------
apt-get --just-print upgrade

# -------------------------
# Alternative 3
# -------------------------

# apt-show-versions
# -u, --upgradeable
#     Print only upgradeable packages

# install apt-show-versions
sudo apt-get install apt-show-versions

# Run apt-show-versions and show only upgradable packages
apt-show-versions -u