Changeset 24829 for main/trunk/greenstone2/gs2-web-server.bat
- Timestamp:
- 2011-11-30T17:48:15+13:00 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone2/gs2-web-server.bat
r24508 r24829 1 1 @echo off 2 SETLOCAL 2 SETLOCAL enabledelayedexpansion 3 3 4 4 if "%serverlang%" == "" set serverlang=en … … 21 21 :: Some users may set the above line manually 22 22 if "%gsdl2path%" == "" ( 23 set GSDLHOME= %CD%24 set gsdl2path= %CD%23 set GSDLHOME=!CD! 24 set gsdl2path=!CD! 25 25 ) 26 26 … … 29 29 echo Checking if the Greenstone log directory is writable ... 30 30 if not exist "%GSDLHOME%\etc\logs-gsi" goto missingLogDir 31 (echo This is a temporary file. It is safe to delete it. > " %GSDLHOME%\etc\logs-gsi\testing.tmp" ) 2>nul31 (echo This is a temporary file. It is safe to delete it. > "!GSDLHOME!\etc\logs-gsi\testing.tmp" ) 2>nul 32 32 if exist "%GSDLHOME%\etc\logs-gsi\testing.tmp" goto deleteTempFile 33 33 if "%1" == "Elevated" goto printWarning 34 34 echo ... FAILED 35 echo The Greenstone server cannot write to the log directory ( %GSDLHOME%\etc\logs-gsi)35 echo The Greenstone server cannot write to the log directory (!GSDLHOME!\etc\logs-gsi) 36 36 echo Requesting elevated status to become admin user to continue. 37 37 "%GSDLHOME%\bin\windows\gstart.exe" %0 Elevated %1 %2 %3 %4 %5 %6 %7 %8 %9 … … 40 40 :missingLogDir 41 41 echo ... FAILED 42 echo The Greenstone log directory does not exist ( %GSDLHOME%\etc\logs-gsi). Please reinstall Greenstone.42 echo The Greenstone log directory does not exist (!GSDLHOME!\etc\logs-gsi). Please reinstall Greenstone. 43 43 pause 44 44 goto exit … … 46 46 :printWarning 47 47 echo ... FAILED 48 echo The Greenstone server cannot write to the log directory ( %GSDLHOME%\etc\logs-gsi).48 echo The Greenstone server cannot write to the log directory (!GSDLHOME!\etc\logs-gsi). 49 49 echo Attempting to continue without permissions. 50 50 goto shiftElevated … … 64 64 :: If either GSDLHOME or GSDLOS is not set, need to run setup.bat first 65 65 :: OR operations in an IF stmt: http://fixunix.com/ms-dos/21057-how-implement-if-condition-batch-file.html 66 for %%i in (" %GSDLOS%" "%GSDLHOME%") do if %%i == "" set OR=True66 for %%i in ("!GSDLOS!" "!GSDLHOME!") do if %%i == "" set OR=True 67 67 if "%OR%" == "True" ( 68 pushd " %gsdl2path%"68 pushd "!gsdl2path!" 69 69 call setup.bat 70 70 rem echo **** GSDLOS: %GSDLOS% and GSDLHOME: %GSDLHOME% … … 97 97 if exist "%GSDLHOME%\llssite.cfg" goto cfgfile 98 98 if exist "%GSDLHOME%\llssite.cfg.in" ( 99 copy " %GSDLHOME%\llssite.cfg.in" "%GSDLHOME%\llssite.cfg"99 copy "!GSDLHOME!\llssite.cfg.in" "!GSDLHOME!\llssite.cfg" 100 100 ) else ( 101 101 echo Warning: could not find llssite.cfg.in to create llssite.cfg from. … … 129 129 if not "%CLASSPATH%" == "" if not "%CLASSPATH%" == "%test_cpath%" ( 130 130 echo - CLASSPATH already correct: 131 echo %CLASSPATH%131 echo !CLASSPATH! 132 132 goto :eof 133 133 ) … … 173 173 echo. 174 174 echo Server log messages go to: 175 echo " %GSDLHOME%\etc\logs-gsi\server.log"175 echo "!GSDLHOME!\etc\logs-gsi\server.log" 176 176 echo. 177 177 echo Using Apache web server located at: 178 echo " %GSDLHOME%\apache-httpd\%GSDLOS%\bin\httpd"178 echo "!GSDLHOME!\apache-httpd\!GSDLOS!\bin\httpd" 179 179 echo The Apache error log is at: 180 echo " %GSDLHOME%\apache-httpd\%GSDLOS%\logs\error_log"180 echo "!GSDLHOME!\apache-httpd\!GSDLOS!\logs\error_log" 181 181 echo The Apache configuration file template is at: 182 echo " %GSDLHOME%\apache-httpd\%GSDLOS%\conf\httpd.conf.in"182 echo "!GSDLHOME!\apache-httpd\!GSDLOS!\conf\httpd.conf.in" 183 183 echo This is used to generate: 184 echo " %GSDLHOME%\apache-httpd\%GSDLOS%\conf\httpd.conf"184 echo "!GSDLHOME!\apache-httpd\!GSDLOS!\conf\httpd.conf" 185 185 echo each time Enter Library is pressed or otherwise activated. 186 186 echo ***************************************************************
Note:
See TracChangeset
for help on using the changeset viewer.