@ECHO OFF
REM      This batch file can be customized to permit execution from any
REM   directory by editing it to add the path for INF52SM, and the
REM   path for the various COPY commands.  Alternatively, be in the
REM   MINOS(IIS) directory when you issue the command for data
REM   that is in another directory.
REM      %1 is the input filename, without the extensions.
REM   A filename.MPS is mandatory.  A filename.SPC file
REM   is recommended, but a default will be used if available.
REM   A filename.GUI file for the guide codes can also be input.
REM      Output appears in filename.PRN, and possibly filename.IIS.
IF NOT EXIST %1.MPS GOTO ERR
COPY %1.MPS MINOS.MPS
IF EXIST DEFAULT.SPC COPY DEFAULT.SPC MINOS.SPC
IF EXIST %1.SPC COPY %1.SPC MINOS.SPC
IF EXIST %1.GUI COPY %1.GUI IIS.GUI
IF EXIST MINOS.PRN ERASE MINOS.PRN
IF EXIST IIS.PRN ERASE IIS.PRN
IF EXIST %1.PRN ERASE %1.PRN
IF EXIST %1.IIS ERASE %1.IIS
REM  Now run MINOS(IIS)
inf52sm
REM  Clean up output
IF EXIST iis.GUI ERASE iis.GUI
IF EXIST MINOS.MPS ERASE MINOS.MPS
IF EXIST MINOS.SPC ERASE MINOS.SPC
IF EXIST iis.IIS copy iis.IIS %1.IIS
if exist iis.iis erase iis.iis
IF EXIST MINOS.PRN copy MINOS.PRN %1.PRN
if exist minos.prn erase minos.prn
IF EXIST IIS.PRN copy IIS.PRN %1.PRN
if exist iis.prn erase iis.prn
GOTO EXIT
:ERR
ECHO %1.MPS NOT FOUND. EXECUTION ABORTED.
:EXIT
