how to determine which packages from official Ubuntu repositories need to be updated (in respect to current state) and to download these packages Thanks.
Hey Denarsson, your script was very helpful thank you.
The command apt-get update -o Dir::Etc::sourcelist='sources.list' \ -o Dir::Etc::sourceparts='-' -o APT::Get::List-Cleanup='0' update the package lists from official Ubuntu repositories.
Yes it is fine but what equally I need first, before updating the data, is to see the list of packages (name of packages) from official Ubuntu repositories that need to be update and after that to confirm to update.
For example like this command : apt-get upgrade --show-upgraded that print out a list of all packages that are to be upgraded.
Output: The following packages will be upgraded:
apache2 apache2-mpm-prefork apache2-utils apache2.2-bin apache2.2-common apparmor apport apport-symptoms apt apt-transport-https apt-utils apt-xapian-index aptitude avahi-daemon cups-client cups-common cups-driver-gutenprint cups-filters cups-ppdc curl dbus dmsetup dnsutils dosfstools dovecot-core dovecot-imapd dovecot-pop3d dpkg file fontconfig-config …….
Or for example with sudo /usr/lib/update-notifier/update-motd-updates-available
Out for ex:
35 packages can be updated.
22 updates are security updates.
As output is the number of packages that can be updated but I need also to see the list of packages with the name for example.
So which combination of command do you think is appropriate to print first the list of packages need to be updated and after that to confirm to update that list?
Thank for your time.