mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2024-12-30 10:26:58 +01:00
new test script
This commit is contained in:
parent
d5f2a72227
commit
1cd2d542f7
1 changed files with 38 additions and 0 deletions
38
xwords4/linux/scripts/newrelay.sh
Executable file
38
xwords4/linux/scripts/newrelay.sh
Executable file
|
@ -0,0 +1,38 @@
|
|||
#!/bin/sh
|
||||
|
||||
DICT=./dict.xwd
|
||||
COOKIE=${COOKIE:-foo}
|
||||
NGAMES=${NGAMES:-1}
|
||||
NPLAYERS=${NPLAYERS:-2}
|
||||
|
||||
usage() {
|
||||
echo "usage: [env=val *] $0" 1>&2
|
||||
echo " current env variables and their values: " 1>&2
|
||||
for VAR in COOKIE NGAMES NPLAYERS; do
|
||||
echo "$VAR:" $(eval "echo \$${VAR}") 1>&2
|
||||
done
|
||||
exit 0
|
||||
}
|
||||
|
||||
while [ -n "$1" ]; do
|
||||
case $1 in
|
||||
*) usage
|
||||
;;
|
||||
esac
|
||||
shift
|
||||
done
|
||||
|
||||
for II in $(seq $NGAMES); do
|
||||
REMOTES=""
|
||||
for JJ in $(seq $((NPLAYERS-1))); do
|
||||
REMOTES="${REMOTES} -N"
|
||||
done
|
||||
for JJ in $(seq $NPLAYERS); do
|
||||
./obj_linux_memdbg/xwords -u -0 -d $DICT -r Eric $REMOTES -C $COOKIE \
|
||||
-q 2 2>log_${II}_${JJ}.txt >/dev/null &
|
||||
done
|
||||
done
|
||||
|
||||
wait
|
||||
|
||||
echo "$0 done"
|
Loading…
Reference in a new issue