From: hackbard Date: Fri, 12 Aug 2005 12:41:50 +0000 (+0000) Subject: hdw-get improvements X-Git-Url: https://hackdaworld.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6a4a665751ecc7199f813268265094006359319d;p=hdw-linux%2Fhdw-linux.git hdw-get improvements --- diff --git a/doc/CHANGELOG b/doc/CHANGELOG index 2e84e9a..361f8c9 100644 --- a/doc/CHANGELOG +++ b/doc/CHANGELOG @@ -1,4 +1,4 @@ -*) 2005-08-11 +*) 2005-08-12 - more hdw-get improvements diff --git a/misc/hdw-tools/hdw-get b/misc/hdw-tools/hdw-get index 7f2d1e6..0ee4ba7 100644 --- a/misc/hdw-tools/hdw-get +++ b/misc/hdw-tools/hdw-get @@ -29,7 +29,6 @@ verbose="" ; no_dep="" auto_resolve_deps="" simulate="" base="" -answer="y" FL_DIR="var/adm/flists" DEPS_DIR="var/adm/deps/run" @@ -194,9 +193,8 @@ elif [ "$install" = "1" ] ; then udeps="" tudeps="" for dep in $deps; do - [ ! -f $inst_root/$FL_DIR/$dep-[0-9]* ] && \ - [ "$pkg" != "$dep" ] && \ - udeps="$dep $udeps" + [ ! -f $inst_root/$FL_DIR/$dep-* ] && \ + udeps="$dep $udeps" done while [ "$udeps" != "$tudeps" ] ; do tudeps="$udeps" @@ -210,29 +208,26 @@ elif [ "$install" = "1" ] ; then [ "$i" = "$dep" ] && exists=1 done [ "$exists" = "0" ] && \ - [ "$dep" != "$pkg" ] && \ - udeps="$udeps $dep" + udeps="$udeps $dep" done done done - if [ -n "$udeps" ] ; then - echo "$pkg has unresolved dependencies:" - echo "-> $udeps <-" - echo - echo "continue? [y,n] (default 'n')" - if [ -z $auto_resolve_deps ] ; then - read answer - if [ "$answer" = "y" ] ; then - for i in $udeps; do - [ "$simulate" != "1" ] && \ - $0 -no-dep install $inst_root $i - done - fi + echo "$pkg depends on the following uninstalled packages:" + echo "$udeps" + echo + echo "continue? [y,n] (default 'n')" + if [ -z $auto_resolve_deps ] ; then + read answer + if [ "$answer" = "y" ] ; then + for i in $udeps; do + [ "$simulate" != "1" ] && \ + $0 -no-dep install $inst_root $i + done fi fi fi - if [ "$simulate" != "1" -a "$answer" != "n" ] ; then + if [ "$simulate" != "1" ] ; then # check/install package if [ -f $package ] ; then