@ECHO OFF
REM MAPTZIP.BAT
REM Optional packer for MAPTSTA result files.
REM Requires ZIP.EXE in PATH or current directory.

F:
CD \MAPCMP

IF EXIST MAPTSTA.ZIP DEL MAPTSTA.ZIP
IF EXIST ZIP.LOG DEL ZIP.LOG

ECHO Creating MAPTSTA.ZIP > ZIP.LOG
ZIP -r MAPTSTA.ZIP RUN.LOG SUMMARY.TXT OUT >> ZIP.LOG


REM Cleanup generated test directories after ZIP.
REM Keep the CMP/result directory because it contains the ZIP and ZIP.LOG.
ECHO Cleaning generated test directories... >> ZIP.LOG
IF EXIST \MAPTEST\NUL DELTREE /Y \MAPTEST >> ZIP.LOG
CD \
ECHO.
ECHO ZIP step finished.
ECHO Check:
ECHO   F:\MAPCMP\MAPTSTA.ZIP
ECHO   F:\MAPCMP\ZIP.LOG
ECHO.
