jehanne/qa/check

26 lines
405 B
Plaintext
Raw Normal View History

#!/cmd/rc
rfork
dir=$1
if(~ $dir '') dir=/qa
l = `{du -a /arch/$objtype/$dir|awk '{print $2}'|sort}
failed = ()
ce=.check
for(t in $l){
if(test -x $t) {
echo -n $t:
$t > /tmp/qa.log >[2=1]
st = $status
if(~ `{echo $st|field 3} PASS) {
if( test -x $t$ce ) { cp /tmp/qa.log /tmp/qa.previous.log }
rm /tmp/qa.log && echo PASS
}
if not { echo $st && cat /tmp/qa.log; exit $st}
}
}