summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Vogt <mvo@debian.org>2013-07-11 07:52:34 +0200
committerMichael Vogt <mvo@debian.org>2013-07-11 07:52:34 +0200
commit90b9659c9a959601d5ed1cc77f7c8b9e0d5b8939 (patch)
tree7a3290bb820acd6cad60b4482c2cfe2e16f5fa08
parent50dba2a9ad755f2ce476576f54698128df9ba327 (diff)
downloadapt-90b9659c9a959601d5ed1cc77f7c8b9e0d5b8939.tar.gz
debian/apt.auto-removal.sh: merge the remaining bits
-rw-r--r--debian/apt.auto-removal.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/debian/apt.auto-removal.sh b/debian/apt.auto-removal.sh
index 8b0f1cf69..4ada56556 100644
--- a/debian/apt.auto-removal.sh
+++ b/debian/apt.auto-removal.sh
@@ -22,7 +22,6 @@ set -e
# will overwrite the db when it exits.
-#
eval $(apt-config shell APT_CONF_D Dir::Etc::parts/d)
test -n "${APT_CONF_D}" || APT_CONF_D="/etc/apt/apt.conf.d"
config_file=${APT_CONF_D}/01autoremove-kernels
@@ -43,7 +42,7 @@ version_test_gt ()
return "$?"
}
-list=$($DPKG -l 'linux-image-[0-9]*'|awk '/^ii/ { print $2 }' | sed -e's/linux-image-//')
+list=$(${DPKG} -l 'linux-image-[0-9]*'|awk '/^ii/ { print $2 }' | sed -e's/linux-image-//')
latest_version=""
previous_version=""
@@ -74,7 +73,7 @@ EOF
)
cat > "$config_file".dpkg-new <<EOF
-# File autogenerated by $0, do not edit
+// File autogenerated by $0, do not edit
APT
{
NeverAutoRemove
@@ -85,6 +84,7 @@ for kernel in $kernels; do
echo " \"^linux-image-extra-${kernel}$\";" >> "$config_file".dpkg-new
echo " \"^linux-signed-image-${kernel}$\";" >> "$config_file".dpkg-new
echo " \"^linux-backports-modules-.*-${kernel}$\";" >> "$config_file".dpkg-new
+ echo " \"^linux-headers-${kernel}$\";" >> "$config_file".dpkg-new
done
cat >> "$config_file".dpkg-new <<EOF
};