Issueing pacifier messages in run_all_releng about logged line
This commit is contained in:
parent
ccde6bec7c
commit
886388d919
@ -10,6 +10,28 @@ not_in_releng_exit() {
|
|||||||
exit 1
|
exit 1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Using only bash builtin commands.
|
||||||
|
# On 4 year old amd64 x2 3000 MHz, xterm local,it counts 22471 lines per second
|
||||||
|
# On 2 year old amd64 x4 2600 MHz, ssh remote, it counts 35348 lines per second
|
||||||
|
count_lines()
|
||||||
|
{
|
||||||
|
# $1 if not empty: start count
|
||||||
|
line=
|
||||||
|
if test -n "$1"
|
||||||
|
then
|
||||||
|
count="$1"
|
||||||
|
else
|
||||||
|
count=0
|
||||||
|
fi
|
||||||
|
while read line
|
||||||
|
do
|
||||||
|
count=$(($count + 1))
|
||||||
|
printf "\r %4d lines logged ... " "$count" >&2
|
||||||
|
printf "%s\n" "$line"
|
||||||
|
done
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
# It is not a good idea to include inc/releng_getopts.inc with the
|
# It is not a good idea to include inc/releng_getopts.inc with the
|
||||||
# master script as it calls the subordinate scripts and they include
|
# master script as it calls the subordinate scripts and they include
|
||||||
# this file too, and we want to avoid sharing variable with subshells
|
# this file too, and we want to avoid sharing variable with subshells
|
||||||
@ -29,7 +51,8 @@ next_is=
|
|||||||
for i in "$@"
|
for i in "$@"
|
||||||
do
|
do
|
||||||
if test "$next_is" = "ignore"
|
if test "$next_is" = "ignore"
|
||||||
then :
|
then
|
||||||
|
dummy=dummy
|
||||||
elif test "$next_is" = "x"
|
elif test "$next_is" = "x"
|
||||||
then
|
then
|
||||||
RELENG_XORRISO="$i"
|
RELENG_XORRISO="$i"
|
||||||
@ -90,10 +113,11 @@ fi
|
|||||||
for s in `ls | grep ^releng_ | grep -v ${SELF} | sort -n`; do
|
for s in `ls | grep ^releng_ | grep -v ${SELF} | sort -n`; do
|
||||||
if [ -x ${s} -a ! -d ${s} ]; then
|
if [ -x ${s} -a ! -d ${s} ]; then
|
||||||
echo -ne "\n\n_STARTING_TEST_________________________________________________________" >> ${CLOG}
|
echo -ne "\n\n_STARTING_TEST_________________________________________________________" >> ${CLOG}
|
||||||
echo -ne "\n${SELF}: Running ./${s} ${PASSED_OPTIONS}..." | tee -a ${CLOG}
|
echo -ne "\n${SELF}: Running ./${s} ${PASSED_OPTIONS} :\n" \
|
||||||
|
| tee -a ${CLOG}
|
||||||
T1=`date '+%s'`
|
T1=`date '+%s'`
|
||||||
set +e
|
set +e
|
||||||
./${s} ${PASSED_OPTIONS} &>> ${CLOG}
|
./${s} ${PASSED_OPTIONS} 2>&1 | count_lines >> ${CLOG}
|
||||||
RET=$?
|
RET=$?
|
||||||
T2=`date '+%s'`
|
T2=`date '+%s'`
|
||||||
let TS="${T2} - ${T1}"
|
let TS="${T2} - ${T1}"
|
||||||
|
Loading…
Reference in New Issue
Block a user