source: main/trunk/greenstone3/ext-cli/get-selfcontained-nodejs.sh@ 36570

Last change on this file since 36570 was 36570, checked in by davidb, 20 months ago

Fixed missing word from echo/print statement

  • Property svn:executable set to *
File size: 1.5 KB
RevLine 
[36449]1#!/bin/bash
2
3OS_ALLCAPS=`uname | tr 'a-z' 'A-Z'`
4
5selfcon_ext=selfcontained-nodejs
6installed_dir=${selfcon_ext}/nodejs-64bit
7
8echo ""
9if [ ! -d $selfcon_ext ] ; then
[36570]10 echo "Checking out from svn: Greenstone3's $selfcon_ext extension"
[36449]11 svn co https://svn.greenstone.org/gs3-extensions/$selfcon_ext/trunk $selfcon_ext
12
13 if [ $? != 0 ] ; then
14 echo "Error encountered checking out: " 1>&2
15 echo " svn co https://svn.greenstone.org/gs3-extensions/$selfcon_ext/trunk $selfcon_ext" 1>&2
16 exit 1
17 fi
18else
19 echo "Detected directory '$selfcon_ext'"
20 echo "=> Taken to mean that the svn check-out command has already been run"
21fi
22
23echo ""
24if [ ! -d $installed_dir ] ; then
25 echo "Runing the $selfcon_ext/PREPARE-${OS_ALLCAPS}.sh"
26
27 cd $selfcon_ext && ./PREPARE-${OS_ALLCAPS}.sh
28
29 if [ $? != 0 ] ; then
30 echo "Error encountered running: " 1>&2
31 echo " cd $selfcon_ext && ./PREPARE-${OS_ALLCAPS}.sh" 1>&2
32 exit 1
33 fi
34
35else
36 echo "Detected directory '$installed_dir'"
37 echo "=> Taken to mean that the $selfcon_ext/PREPARE-${OS_ALLCAPS}.sh command has already been run"
38fi
39
40
41if [ "x$JAVA_HOME" != "x$PWD/$installed_dir" ] ; then
42 echo ""
43 echo "To use this installed version of Apache Ant, in the top-level Greenstone3 directory run:"
44 echo " source ./gs3-setup-cli.sh"
45 echo ""
46else
47 echo ""
48 echo "Detected JAVA_HOME set to \$PWD/$installed_dir"
49 echo "=> Taken to mean that the $selfcon_ext SETUP.sh file has been sourced"
50fi
51
52echo ""
Note: See TracBrowser for help on using the repository browser.