#!/bin/sh # CRONFILE FOR ARCHIVE IN DIRECTORY /home/onetan/onetan-www quiet="" if [ "$1" = "-q" ] ; then quiet="-q" fi # create a file to insure that no one searches during an index touch /home/onetan/onetan-www/indexing-in-progress # delete the search boxes in all current files (filelist may change) /home/onetan/onetan-www/addsearch /home/onetan/onetan-www -r $quiet # Do the retrieving /home/onetan/onetan-www/makenh /home/onetan/onetan-www $quiet # put the search box in the html files -- will check config file # and will not do anything if not wanted /home/onetan/onetan-www/addsearch /home/onetan/onetan-www # Do the indexing if [ "$quiet" = "-q" ] ; then /bin/cat /home/onetan/onetan-www/.wg_toindex | /home/onetan/onetan-www/glimpse-4.1-bin-Linux-2.0.30-i486/bin/glimpseindex -H /home/onetan/onetan-www -o -t -h -X -U -f -C -F > /dev/null else /bin/cat /home/onetan/onetan-www/.wg_toindex | /home/onetan/onetan-www/glimpse-4.1-bin-Linux-2.0.30-i486/bin/glimpseindex -H /home/onetan/onetan-www -o -t -h -X -U -f -C -F fi # Compress neighborhood files if [ "$quiet" = "-q" ] ; then /bin/cat /home/onetan/onetan-www/.wg_madenh | /home/onetan/onetan-www/glimpse-4.1-bin-Linux-2.0.30-i486/bin/wgconvert -H /home/onetan/onetan-www -U -P .nh. -F -ni | grep -v "^hash_misses=0" else /bin/cat /home/onetan/onetan-www/.wg_madenh | /home/onetan/onetan-www/glimpse-4.1-bin-Linux-2.0.30-i486/bin/wgconvert -H /home/onetan/onetan-www -U -P .nh. -F -ni fi # now change the directory and set the permissions cd /home/onetan/onetan-www chmod a+r .glimpse_* # remove the locking file /bin/rm -f /home/onetan/onetan-www/indexing-in-progress