Changeset 22576

Show
Ignore:
Timestamp:
05.08.2010 14:16:18 (9 years ago)
Author:
sjm84
Message:

These files will now print an error and quit if the log directory is missing

Location:
main/trunk/greenstone2
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/gs2-server.bat

    r22572 r22576  
    77:checkUserPermissions 
    88    echo Checking if the Greenstone log directory is writable ... 
     9    if not exist "%GSDLHOME%\etc\logs-gsi" goto missingLogDir 
    910    (echo This is a temporary file. It is safe to delete it. > "%GSDLHOME%\etc\logs-gsi\testing.tmp" ) 2>nul 
    1011    if exist "%GSDLHOME%\etc\logs-gsi\testing.tmp" goto deleteTempFile  
     
    1415    echo Requesting elevated status to become admin user to continue. 
    1516    "%GSDLHOME%\bin\windows\gstart.exe" %0 Elevated %1 %2 %3 %4 %5 %6 %7 %8 %9 
     17    goto done 
     18     
     19:missingLogDir 
     20    echo ... FAILED 
     21    echo The Greenstone log directory does not exist (%GSDLHOME%\etc\logs-gsi). Please reinstall Greenstone. 
     22    pause 
    1623    goto done 
    1724     
  • main/trunk/greenstone2/gs2-web-server.bat

    r22572 r22576  
    2626 
    2727:checkUserPermissions 
     28    echo. 
    2829    echo Checking if the Greenstone log directory is writable ... 
     30    if not exist "%GSDLHOME%\etc\logs-gsi" goto missingLogDir 
    2931    (echo This is a temporary file. It is safe to delete it. > "%GSDLHOME%\etc\logs-gsi\testing.tmp" ) 2>nul 
    3032    if exist "%GSDLHOME%\etc\logs-gsi\testing.tmp" goto deleteTempFile   
     
    3436    echo Requesting elevated status to become admin user to continue. 
    3537    "%GSDLHOME%\bin\windows\gstart.exe" %0 Elevated %1 %2 %3 %4 %5 %6 %7 %8 %9 
    36     goto done 
     38    goto exit 
     39     
     40:missingLogDir 
     41    echo ... FAILED 
     42    echo The Greenstone log directory does not exist (%GSDLHOME%\etc\logs-gsi). Please reinstall Greenstone. 
     43    pause 
     44    goto exit 
    3745     
    3846:printWarning