Echo off
CLS
if "%1" == "" goto Noparms
if "%2" == "" goto NoDir
GOTO Proceed
:NoDir
Echo ÿ
Echo                           W A R N I N G
Echo                  You did not specify a directory
Echo ÿ
Echo If you proceed, The Guardian will be installed in the root directory
Echo of drive %1.  If you made a mistake and want to start over, then
Echo press Ctl-Brk now; otherwise
Echo ÿ
Pause
Cls
:Proceed
Echo      ÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ
Echo ÿ
Echo                            T H E  G U A R D I A N
Echo                       Hard Disk Installation Procedure
Echo ÿ
Echo             You have asked that The Guardian be installed on a drive and
Echo             directory specified by you. They are:
Echo ÿ
Echo                            DRIVE           DIRECTORY
Echo ÿ
Echo                             %1              %2
Echo ÿ
Echo             If this is not correct, press Ctl-Brk now. Then re-enter
Echo             the procedure with the correct drive letter and directory
Echo             according to the following format:
Echo ÿ
Echo                               INSTALL x: name
Echo ÿ
Echo             where "x" is the drive letter and "name" is the name of
Echo             the directory you wish to use. The current (default)
Echo             drive should be A:.
Echo ÿ
Echo      ÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ
pause
if "%2" == "" goto BypassMD
MD %1\%2
:BypassMD
%1
CD \%2
Echo Echo off > inst0.bat
Echo Cls >> inst0.bat
Echo HDINST2 %1 %2 >> inst0.bat
GOTO Cont1
:Noparms
Echo      ÉÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ»
Echo      º                                                                    º
Echo      º                      T H E  G U A R D I A N                        º
Echo      º                 Hard Disk Installation Procedure                   º
Echo      º                                                                    º
Echo      º      This procedure will install The Guardian on your hard disk    º
Echo      º      and set up the control files to simplify its operation.       º
Echo      º                                                                    º
Echo      º      It will create a sub-directory called GUARDIAN where the      º
Echo      º      programs and data files will be stored. It assumes that       º
Echo      º      your hard disk is drive C:. If this is not correct, or        º
Echo      º      if you want to use a different directory name, press          º
Echo      º      Ctl-Brk now. Then re-enter the procedure with the correct     º
Echo      º      drive letter and directory name according to the following    º
Echo      º      format:                                                       º
Echo      º                           INSTALL x: name                          º
Echo      º                                                                    º
Echo      º      where "x" is the drive letter and "name" is the name of       º
Echo      º      the directory you wish to use. The current (default)          º
Echo      º      drive should be A:.                                           º
Echo      º                                                                    º
Echo      ÈÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ¼
Echo ÿ
pause
MD C:\GUARDIAN
C:
CD \GUARDIAN
Echo Echo off > inst0.bat
Echo Cls >> inst0.bat
Echo HDINST2 C: GUARDIAN  >> inst0.bat
:Cont1
CLS
Echo        Copying files - one moment please .....
: Copy all the files except Guardian.Exe
Copy A:*.BAT > nul
Copy A:*.COM > nul
Copy A:*.TXT > nul
IF EXIST GUARDIAN.EXE del GUARDIAN.EXE
IF EXIST USERDOC.EXE del USERDOC.EXE
Echo ÿ
Echo        Extracting files/programs - one moment please .....
Echo ÿ
:    If a master already exists, rename it
IF EXIST GUARDIAN.MRE Ren GUARDIAN.MRE GUARDIAN.BAK
Copy A:GUARDIAN.MRE
A:GUARDIAN
A:USERDOC
:    Extract all files to the installation directory
IF NOT EXIST GUARDIAN.BAK Goto SkipRename
Del GUARDIAN.MRE
Ren GUARDIAN.BAK *.MRE
:SkipRename
INST0
