[Fai-commit] r4778 - trunk/lib

lange at alioth.debian.org lange at alioth.debian.org
Wed Nov 21 16:34:56 UTC 2007


Author: lange
Date: 2007-11-21 16:34:56 +0000 (Wed, 21 Nov 2007)
New Revision: 4778

Modified:
   trunk/lib/updatebase
Log:
do not use strings command to check if safe-upgrade is supported, use --help


Modified: trunk/lib/updatebase
===================================================================
--- trunk/lib/updatebase	2007-11-21 16:09:35 UTC (rev 4777)
+++ trunk/lib/updatebase	2007-11-21 16:34:56 UTC (rev 4778)
@@ -32,10 +32,10 @@
 # using the above value, causes an error: "dpkg need action"
 export aptopt=
 # this may be removed in lenny
-if strings $FAI_ROOT/usr/bin/aptitude | grep -q safe-upgrade; then
+if $FAI_ROOT/usr/bin/aptitude --help | grep -q safe-upgrade; then
+    $ROOTCMD aptitude -y upgrade
+else
     $ROOTCMD aptitude -y safe-upgrade
-else
-    $ROOTCMD aptitude -y upgrade
 fi
 
 $ROOTCMD aptitude $aptopt -f -y dist-upgrade </dev/null




More information about the Fai-commit mailing list