Annotation of badi/public_scripts/initialindexer/initialindexer, revision 1.1.1.1
1.1 adi 1: #!/bin/sh
2:
3: #
4: # Runs the InitialIndexer application which writes the file indexes to
5: # the SQL server.
6: #
7:
8: echo " _____________________________________"
9: echo " | |"
10: echo " | FileLister v0.5.1: InitialIndexer |"
11: echo " |_____________________________________|"
12: echo
13:
14: JAVA_HOME="/usr/lib/sablevm"
15: INSTFILE=`readlink -f $0`
16: INSTDIR=`dirname $0`
17: INSTDIR=`readlink -f $INSTDIR`
18:
19: if [ -z $INSTFILE ]; then
20: # file is no link
21: if [ -z $INSTDIR ]; then
22: # directory is no link
23: cd `dirname $0`
24: else
25: # directory is a link
26: cd `dirname $INSTDIR`
27: fi
28: else
29: # file is a link
30: cd `dirname $INSTFILE`
31: fi
32:
33: if [ ! -x "./filelister_env.sh" ]; then
34: echo " filelister_env.sh is missing or not executable! Please make sure you"
35: echo " use the original distribution."
36: exit 3
37: fi
38:
39: . ./filelister_env.sh
40:
41: echo "FileLister classpath: $FILELISTERCLASSPATH"
42:
43: exec $JAVA_HOME/bin/java -classpath "$FILELISTERCLASSPATH" org.alltimeflashdreamer.filelister.InitialIndexer $PROPERTYFILEDIR $1
44: iierr=$?
45: echo -e "\n"
46:
47: # unfortunately, after java we are no more
48: if [ $iierr = 0 ]; then
49: echo "$(basename $0) terminated successfully."
50: exit 0
51: else
52: echo "$(basename $0) exited with error $iierr. You may need to clean up the temporary tables in the DB."
53: exit 1
54: fi
55:
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>