]> git.saurik.com Git - apt.git/blobdiff - dselect/install
replace direct calls to egrep with grep -E
[apt.git] / dselect / install
index 3ef213550d3ed28653d6e1d20c77e279047c855a..ef8de9b730e06d01950e14ac468b6a045e1cc264 100755 (executable)
@@ -5,7 +5,8 @@ TEXTDOMAIN="apt"
 
 # Get the configuration from /etc/apt/apt.conf
 CLEAN="prompt"
-OPTS="-f"
+OPTS=""
+DSELECT_UPGRADE_OPTS="-f"
 APTGET="/usr/bin/apt-get"
 DPKG="/usr/bin/dpkg"
 DPKG_OPTS="--admindir=$1"
@@ -47,12 +48,12 @@ yesno() {
 }
 
 if [ "$WAIT" = "true" ]; then
-   $APTGET $OPTS "$APT_OPT0" "$APT_OPT1" -d dselect-upgrade
+   $APTGET $DSELECT_UPGRADE_OPTS $OPTS "$APT_OPT0" "$APT_OPT1" -d dselect-upgrade
    echo $"Press enter to continue." && read RES
-   $APTGET $OPTS "$APT_OPT0" "$APT_OPT1" dselect-upgrade
+   $APTGET $DSELECT_UPGRADE_OPTS $OPTS "$APT_OPT0" "$APT_OPT1" dselect-upgrade
    RES=$?
 else
-   $APTGET $OPTS "$APT_OPT0" "$APT_OPT1" dselect-upgrade
+   $APTGET $DSELECT_UPGRADE_OPTS $OPTS "$APT_OPT0" "$APT_OPT1" dselect-upgrade
    RES=$?
 fi
 
@@ -64,7 +65,7 @@ fi
 # Finished OK
 if [ $RES -eq 0 ]; then
 
-   if [ $(ls $ARCHIVES $ARCHIVES/partial | egrep -v "^lock$|^partial$" | wc -l) \
+   if [ $(ls $ARCHIVES $ARCHIVES/partial | grep -E -v "^lock$|^partial$" | wc -l) \
         -eq 0 ]; then
       exit 0
    fi