source: greenstone3/trunk/gs3-admin.sh@ 14643

Last change on this file since 14643 was 10944, checked in by kjdon, 18 years ago

gai.sh renamed to gs3-admin.sh. can't decide whether it should live here or in bin/script

  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 2.2 KB
Line 
1#!/bin/sh
2gailang=en
3
4echo
5 echo "Greenstone Administrator Interface (GAI)"
6 echo "Copyright (C) 2005, New Zealand Digital Library Project, University Of Waikato"
7 echo "GAI comes with ABSOLUTELY NO WARRANTY; for details see LICENSE.txt"
8 echo "This is free software, and you are welcome to redistribute it"
9echo
10
11## -------- Run the Greenstone Administrator Interface --------
12
13# This script must be run from within the directory in which it lives
14thisdir=`pwd`
15if [ ! -f "${thisdir}/gs3-admin.sh" ]; then
16 if [ "$gailang" == "es" ]; then
17 echo "Este guión deberá ejecutarse desde el directorio en el que reside."
18 elif [ "$gailang" == "fr" ]; then
19 echo "Ce script doit être exécuté à partir du répertoire dans lequel il se trouve."
20 elif [ "$gailang" == "ru" ]; then
21 echo "üÔÏÔ ÓËÒÉÐÔ ÄÏÌÖÅÎ ÂÙÔØ ×ÚÑÔ ÉÚ ÄÉÒÅËÔÏÒÉÉ, × ËÏÔÏÒÏÊ ÏÎ ÒÁÓÐÏÌÏÖÅÎ"
22 else
23 echo "This script must be run from the directory in which it resides."
24 fi
25 exit 1
26fi
27
28
29## ---- Determine GSDL3HOME ----
30gsdl3path=
31
32# Some users may set the above line manually
33if [ "$gsdl3path" == "" ]; then
34 # Check the environment variable first
35 if [ "$GSDL3SRCHOME" != "" ]; then
36 gsdl3path=$GSDL3SRCHOME
37
38 # If it is not set, assume that the GAI is installed as a subdirectory of Greenstone
39 else
40# pushd .. > /dev/null
41 gsdl3path=`pwd`
42# popd > /dev/null
43 fi
44fi
45
46# Setup Greenstone3, unless it has already been done
47if [ "$GSDL3HOME" == "" ]; then
48 pushd $gsdl3path > /dev/null
49 source gs3-setup.sh
50 popd > /dev/null
51fi
52
53# Other arguments you can provide to GLI to work around memory limitations, or debug
54# -Xms<number>M To set minimum memory (by default 32MB)
55# -Xmx<number>M To set maximum memory (by default the nearest 2^n to the total remaining physical memory)
56# -verbose:gc To set garbage collection messages
57# -Xincgc For incremental garbage collection (significantly slows performance)
58# -Xprof Function call profiling
59# -Xloggc:<file> Write garbage collection log
60
61# $javapath -classpath classes/:GLI.jar:lib/apache.jar:lib/qfslib.jar:lib/mail.jar:lib/activation.jar org.greenstone.gatherer.GathererProg -gsdl $GSDLHOME -wget $wgetpath $*
62
63java -cp $CLASSPATH org.greenstone.admin.GAI $GSDL3SRCHOME $GSDL3HOME
Note: See TracBrowser for help on using the repository browser.