No X11 output for gnuplot
[idzebra-moved-to-github.git] / test / dmoz / update.sh
1 #!/bin/sh
2 # $Id: update.sh,v 1.5 2002-06-19 12:38:47 adam Exp $
3 t=$1
4 test -n "$t" || exit 1
5 rm -f *.mf *.LCK *.tmp
6 ../../index/zebraidx -l zebraidx-$t.log init 
7 i=0
8 rm -f times-$t.log stat-$t.log
9 while test -f dmoz.$i.xml; do
10         echo -n "$i " >>times-$1.log
11         rm -f zebraidx-$t.log
12         ../../index/zebraidx -l zebraidx-$t.log -c zebra-$t.cfg -f 10 update dmoz.$i.xml 
13         grep ' zebraidx times:' zebraidx-$t.log | sed 's/.*zebraidx times://g' >>times-$t.log
14         ../../index/zebraidx -l zebraidx-$t.log -c zebra-$t.cfg stat >>stat-$t.log 
15         i=`expr $i + 1`
16         if test $i = 30; then
17                 break
18         fi
19 done
20
21 cat >plot.dem <<ENDOFMESSAGE
22 set output "times-$t.ps"
23 set terminal postscript
24 set xlabel "runs"
25 set ylabel "seconds"
26 plot [0:] [0:] \
27         'times-$t.log' using 2 title 'ISAM-$t(real)' with linespoints, \
28         'times-$t.log' using 3 title 'ISAM-$t(user)' with linespoints, \
29         'times-$t.log' using 4 title 'ISAM-$t(sys)' with linespoints
30 ENDOFMESSAGE
31
32 gnuplot plot.dem
33
34