From: Valentin Vidic Date: Mon, 10 Mar 2008 09:37:36 +0000 (+0100) Subject: Fixed display of action conditions. X-Git-Tag: debian/4.0.1~25 X-Git-Url: http://ftp.carnet.hr/pub/carnet-debian/scm?a=commitdiff_plain;h=70cc5dc9921d2e8c4af89e922bc85e244ee6ac85;p=carnet-upgrade.git Fixed display of action conditions. --- diff --git a/src/functions.sh b/src/functions.sh index 22ba7a6..27c6133 100644 --- a/src/functions.sh +++ b/src/functions.sh @@ -229,8 +229,8 @@ run_actions() { check=$(echo "$line" | sed 's/ */ /g'| awk -F' ' '{print $1}') action=$(echo "$line" | sed 's/ */ /g'| awk -F' ' '{print $2}') checkmsg="" - [ "$test" != "true" ] && checkmsg="if '$test'" - if eval $test; then + [ "$check" != "true" ] && checkmsg="if '$check'" + if eval $check; then log "$(printf 'action %02d' $lineno) starting: '${action}' $checkmsg " eval $action log "$(printf 'action %02d' $lineno) finished: '${action}' $checkmsg"