I understand that in apt
, the command update
, updates the list of available packages, but it does not upgrade software that was already installed from these packages.
I also understand that upgrade
upgrades any software that I already installed from a package I updated with update
as described above.
What was the reason of the Ubuntu/Debian developers to do this splitting of update
and upgrade
instead work with one command to do both tasks?
This is more of a question on the architectural philosophy of the Ubuntu developers.
Best Answer
An upgrade is not the only time you might need to
apt-get update
, and I do not want to upgrade each time I simply want to update the package lists.An
apt-get upgrade
working well may depend onapt-get update
being run not long ago, but then that is true ofapt-get remove
andapt-get install
as well! Should all of these implyapt-get update
? Of course not! As a simple matter of resource efficiency and design cleanness, if an operation is common to multiple other operations, it should be factored out.Conversely, given that
apt-get remove
andapt-get install
may also depend onapt-get update
being recently run to successfully finish, does it make sense toapt-get upgrade
for each run ofapt-get update
? No, again, since what I intend to do may well conflict with whatapt-get upgrade
will do.