@echo off
REM #############################################################################
REM #       								        #
REM #                             NGM 2.00 UPGRADE                              #
REM #                              March 31, 1993                               #
REM #		   					     		        #
REM #############################################################################

: This batch file must be copied to and run from the root NGM directory
: (EX: \NGM)


if not exist .\patch.exe goto nopatch
if not exist .\ngm20.rtp goto nopatch
cls
echo The NetWare Global MHS patch v2.00 process may take upwards of 20
echo minutes, depending on your system type and the number of files 
echo to be updated. Review the file RESULTS.TXT upon completion.
echo ÿ
echo PATCHING in progress - WORKING !!!

if exist results.txt copy results.txt results.bak

PATCH /S  ngm20.rtp   > results.txt
if errorlevel 1 goto FAIL
goto DONE


:NOPATCH
cls
echo ÿ
echo ERROR - Please verify the following files exist in the root NGM directory.
echo ÿ
echo         1. PATCH.EXE
echo         2. NGM20.RTP
echo         3. PATCHNGM.BAT
echo ÿ
echo         Change to the NGM root directory and type 'PATCHNGM'.
echo ÿ
goto end

:DONE
cls
echo ÿ
echo The NGM 2.00 Upgrade has completed. Please examine the file 'RESULTS.TXT'
echo to verify the successful completion of this upgrade procedure.
goto end

:FAIL
echo ÿ
echo ERROR - An error has occurred which has caused this NGM v2.00 upgrade to
echo         FAIL. If the .\BACKUP directory exists on your system you must 
echo         perform the following before attempting to install the patch
echo         again. 
echo ÿ
echo                  1.  From the .\BACKUP directory copy UNPATCH.BAK to
echo                      UNPATCH.BAT.
echo                  2.  Type UNPATCH.BAT.
echo                  3.  After the system is restored, delete the .\BACKUP
echo                      directory and its contents. 
echo ÿ               
echo         Check your system configuration and rerun "PATCHNGM.BAT". If you
echo         continue to experience problems, contact your local Novell representative.
echo ÿ

:END
