]> git.saurik.com Git - apt.git/blobdiff - debian/apt.cron.daily
* test/versions.lst:
[apt.git] / debian / apt.cron.daily
index 8ace14a31e5770ae3932821f02555bcf809b1722..75986f5f5f52c6f60e61e44e1f09e080abadafc8 100644 (file)
@@ -417,6 +417,13 @@ do_cache_backup $BackupArchiveInterval
 # mirrors at the same time
 random_sleep
 
+# include default system language so that "apt-get update" will
+# fetch the right translated package descriptions
+if [ -r /etc/default/locale ]; then
+    . /etc/default/locale
+    export LANG LANGUAGE LC_MESSAGES LC_ALL
+fi
+
 # update package lists
 UPDATED=0
 UPDATE_STAMP=/var/lib/apt/periodic/update-stamp
@@ -459,7 +466,7 @@ fi
 
 # auto upgrade all upgradeable packages
 UPGRADE_STAMP=/var/lib/apt/periodic/upgrade-stamp
-if [ $UPDATED -eq 1 ] && which unattended-upgrade >/dev/null && check_stamp $UPGRADE_STAMP $UnattendedUpgradeInterval; then
+if which unattended-upgrade >/dev/null && check_stamp $UPGRADE_STAMP $UnattendedUpgradeInterval; then
     if unattended-upgrade $XUUPOPT; then
        update_stamp $UPGRADE_STAMP
        debug_echo "unattended-upgrade (success)"