source: trunk/gsdl/setup.bash@ 6762

Last change on this file since 6762 was 6762, checked in by mdewsnip, 20 years ago

Now with Spanish strings.

  • Property svn:executable set to *
  • Property svn:keywords set to Author Date Id Revision
File size: 2.5 KB
Line 
1# if this file is executed, /bin/sh is used, as we don't start with #!
2# this should work under ash, bash, zsh, ksh, sh style shells.
3gsdllang=es
4
5# make sure we are sourced, and not run
6
7if test "$0" != "`echo $0 | sed s/setup\.bash//`" ; then
8# if $0 contains "setup.bash" we've been run... $0 is shellname if sourced.
9# One exception is zsh has an option to set it temporarily to the script name
10 if test -z "$ZSH_NAME" ; then
11 # we aren't using zsh
12 gsdl_not_sourced=true
13 fi
14fi
15
16if test -n "$gsdl_not_sourced" ; then
17 if [ "$gsdllang" == "es" ]; then
18 echo " Error: Asegúrese de compilar este guión, no de ejecutarlo. P. ej.:"
19 echo " $ source setup.bash"
20 echo " o"
21 echo " $ . ./setup.bash"
22 echo " no"
23 echo " $ ./setup.bash"
24 elif [ "$gsdllang" == "fr" ]; then
25 echo "-- Still coming --"
26 else
27 echo " Error: Make sure you source this script, not execute it. Eg:"
28 echo " $ source setup.bash"
29 echo " or"
30 echo " $ . ./setup.bash"
31 echo " not"
32 echo " $ ./setup.bash"
33 fi
34elif test -n "$GSDLHOME" ; then
35 if [ "$gsdllang" == "es" ]; then
36 echo "¡Su ambiente ya está listo para Greenstone!"
37 elif [ "$gsdllang" == "fr" ]; then
38 echo "Votre environnement est déjà préparé pour Greenstone!"
39 else
40 echo "Your environment is already set up for Greenstone!"
41 fi
42elif test ! -f setup.bash ; then
43 if [ "$gsdllang" == "es" ]; then
44 echo "Usted debe compilar el guión desde el interior del directorio de inicio"
45 echo "de Greenstone."
46 elif [ "$gsdllang" == "fr" ]; then
47 echo "Vous devez trouver la source du script dans le répertoire de base de Greenstone"
48 else
49 echo "You must source the script from within the Greenstone home directory"
50 fi
51else
52 GSDLHOME=`pwd`
53 export GSDLHOME
54 GSDLOS=`uname -s | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
55 # check for running bash under cygwin
56 if test "`echo $GSDLOS | sed 's/cygwin//'`" != "$GSDLOS" ;
57 then
58 GSDLOS=windows
59 fi
60 export GSDLOS
61
62 PATH=$PATH:$GSDLHOME/bin/script:$GSDLHOME/bin/$GSDLOS
63 export PATH
64 MANPATH=$MANPATH:$GSDLHOME/packages/mg/man
65 export MANPATH
66 if [ "$gsdllang" == "es" ]; then
67 echo "Su ambiente ha sido configurado para correr los programas Greenstone."
68 elif [ "$gsdllang" == "fr" ]; then
69 echo "Votre environnement a été configuére avec succès pour exécuter Greenstone"
70 else
71 echo "Your environment has successfully been set up to run Greenstone"
72 fi
73fi
74unset gsdl_not_sourced
Note: See TracBrowser for help on using the repository browser.