apt-upgrade

I used to use a 2 command 1 liner to update my system:

sudo apt-get update && sudo apt-get dist-upgrade

That was easy enough to type out now and then. But over time it grew to include removing and cleaning downloaded packages as well.

Then there’s the matter of knowing if an update requires a system restart.

The lazy me put it all into one bash script and made it globally accessible and executable:

Placed it in  /usr/local/bin/apt-upgrade  and made it executable with  sudo chmod +x /usr/local/bin/apt-upgrade .

Now I can run  sudo apt-upgrade on all of my servers and it’ll update things as well as letting me know if a reboot is required.

Leave a Reply

Your email address will not be published. Required fields are marked *