Package: apt Version: 0.7.21 Severity: wishlist Tags: patch Please add the below patch that adds configurable support for using debdelta to download packages in the apt cron job. It doesn't disrupt the cron job when debdelta is not installed and when it is installed, it defaults to on but can be turned off with a configuration option. debdelta uses binary diffs to reduce download sizes and produces bit-identical .deb files. People use it as a tradeoff between network and CPU usage. The cron job will use apt-get as usual after debdelta so that if debdelta fails or if it doesn't have the right files available then apt will download them as usual. debdelta failures are ignored, since they can happen occasionally. I didn't include a patch to the apt configuration documentation, just to the cron job, you can copy the doc line from the cron job to the docs though. --- /etc/cron.daily/apt.orig +++ /etc/cron.daily/apt @@ -11,6 +11,9 @@ # "APT::Periodic::Download-Upgradeable-Packages=0", # - Do "apt-get upgrade --download-only" every n-days (0=disable) # +# "APT::Periodic::Download-Upgradeable-Packages-Debdelta=1", +# - Use debdelta-upgrade to download updates if available (0=disable) +# # "APT::Periodic::AutocleanInterval" # - Do "apt-get autoclean" every n-days (0=disable) # @@ -194,6 +197,8 @@ eval $(apt-config shell AutocleanInterval APT::Periodic::AutocleanInterval) UnattendedUpgradeInterval=0 eval $(apt-config shell UnattendedUpgradeInterval APT::Periodic::Unattended-Upgrade) +Debdelta=1 +eval $(apt-config shell Debdelta APT::Periodic::Download-Upgradeable-Packages-Debdelta) # check if we actually have to do anything if [ $UpdateInterval -eq 0 ] && @@ -243,6 +248,9 @@ DOWNLOAD_UPGRADEABLE_STAMP=/var/lib/apt/periodic/download-upgradeable-stamp if check_stamp $DOWNLOAD_UPGRADEABLE_STAMP $DownloadUpgradeableInterval; then + if [ $Debdelta -eq 1 ] then ; + debdelta-upgrade >/dev/null 2>&1 || true + fi apt-get -qq -d dist-upgrade 2>/dev/null update_stamp $DOWNLOAD_UPGRADEABLE_STAMP fi -- bye, pabs http://wiki.debian.org/PaulWise
Attachment:
signature.asc
Description: This is a digitally signed message part