Further refinement.
This commit is contained in:
parent
bbfb511322
commit
972692cb1c
19
TakeAction
19
TakeAction
|
@ -23,6 +23,7 @@ do
|
||||||
xname) SYS="$2"
|
xname) SYS="$2"
|
||||||
ACTION='make $PAR'
|
ACTION='make $PAR'
|
||||||
DIR=.
|
DIR=.
|
||||||
|
FM=no
|
||||||
FAIL='Failed for $SYS, see $DIR/Out'
|
FAIL='Failed for $SYS, see $DIR/Out'
|
||||||
SUCC='$SYS -- done'
|
SUCC='$SYS -- done'
|
||||||
ATYPE=
|
ATYPE=
|
||||||
|
@ -31,11 +32,16 @@ do
|
||||||
;;
|
;;
|
||||||
xfatal) FATAL=yes ;;
|
xfatal) FATAL=yes ;;
|
||||||
xaction|xindir) case x$ATYPE in
|
xaction|xindir) case x$ATYPE in
|
||||||
x) ACTION=$2 ; ATYPE=$1 ;;
|
x) ACTION=$2 ; ATYPE=$1
|
||||||
|
case $ATYPE$FM in
|
||||||
|
indirno) FAIL='Failed for $SYS' ;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
*) echo Already specified an $ATYPE for this name
|
*) echo Already specified an $ATYPE for this name
|
||||||
RETC=-1 ;;
|
RETC=65 ;;
|
||||||
esac ;;
|
esac ;;
|
||||||
xfailure) FAIL="$2" ;;
|
xfailure) FM=yes
|
||||||
|
FAIL="$2" ;;
|
||||||
xsuccess) SUCC="$2" ;;
|
xsuccess) SUCC="$2" ;;
|
||||||
xdir) DIR="$2" ;;
|
xdir) DIR="$2" ;;
|
||||||
xsystem) case `ack_sys` in
|
xsystem) case `ack_sys` in
|
||||||
|
@ -48,7 +54,7 @@ do
|
||||||
no) continue ;;
|
no) continue ;;
|
||||||
esac
|
esac
|
||||||
case x$SYS in
|
case x$SYS in
|
||||||
x) echo Missing name line; RETC=-1 ;;
|
x) echo Missing name line; RETC=65 ;;
|
||||||
*) if test -d $DIR
|
*) if test -d $DIR
|
||||||
then (
|
then (
|
||||||
cd $DIR
|
cd $DIR
|
||||||
|
@ -80,7 +86,7 @@ do
|
||||||
esac
|
esac
|
||||||
else
|
else
|
||||||
echo Directory $DIR for $SYS is inaccessible
|
echo Directory $DIR for $SYS is inaccessible
|
||||||
RETC=-2
|
RETC=66
|
||||||
fi ;;
|
fi ;;
|
||||||
esac
|
esac
|
||||||
case $FATAL$RETC in
|
case $FATAL$RETC in
|
||||||
|
@ -91,9 +97,10 @@ do
|
||||||
SYS=
|
SYS=
|
||||||
;;
|
;;
|
||||||
*) echo Unknown keyword "$1"
|
*) echo Unknown keyword "$1"
|
||||||
RETC=-3 ;;
|
RETC=67 ;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
exit $RETC
|
||||||
} <$CMD
|
} <$CMD
|
||||||
RETX=$?
|
RETX=$?
|
||||||
case $RETX in
|
case $RETX in
|
||||||
|
|
Loading…
Reference in a new issue