home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
RBBS in a Box Volume 1 #2
/
RBBS_vol1_no2.iso
/
add2
/
cvt_lzh1.zip
/
CVT-LZH!.BAT
< prev
next >
Wrap
DOS Batch File
|
1989-04-24
|
2KB
|
72 lines
@echo off
:START
if "%1" == "" goto ERROR
if "%arctype%" == "" goto ERROR
cd temp.$$$
if "%arctype%" == "?Q?" echo.
if "%arctype%" == "?Q?" alusq11 ..\%1
if errorlevel 1 goto BAD
if "%arctype%" == "ARC" pkunpak ..\%1
if errorlevel 1 goto BAD
if "%arctype%" == "DWC" dwc e ..\%1
if errorlevel 1 goto BAD
if "%arctype%" == "LBR" lue220 ..\%1
if errorlevel 1 goto BAD
if "%arctype%" == "L$H" lharc e ..\%1
if errorlevel 1 goto BAD
if "%arctype%" == "MD" mdcd d ..\%1
if errorlevel 1 goto BAD
if "%arctype%" == "PAK" echo.
if "%arctype%" == "PAK" pak e ..\%1
if errorlevel 1 goto BAD
if "%arctype%" == "ZIP" pkunzip ..\%1
if errorlevel 1 goto BAD
if "%arctype%" == "ZOO" zoo e ..\%1
if errorlevel 1 goto BAD
if not exist *.* goto BAD
:DOLZH
if exist *.lzh ren *.lzh *.l$h
if exist *.?q? set arctype=?Q?
if exist *.arc set arctype=ARC
if exist *.dwc set arctype=DWC
if exist *.lbr set arctype=LBR
if exist *.l$h set arctype=L$H
if exist *.md set arctype=MD
if exist *.pak set arctype=PAK
if exist *.zip set arctype=ZIP
if exist *.zoo set arctype=ZOO
if exist *.%arctype% goto NEST
del ..\%1
if exist *.l!h ren *.l!h *.lzh
echo y | lharc a ..\%1 *.*
ren ..\%1 *.l!h
goto DONE
:NEST
md temp.$$$
for %%g in (*.%arctype%) do call CVT-LZH! %%g
rd temp.$$$
goto DOLZH
:ERROR
echo.
echo ERROR! CVT-LZH! is not a stand alone application.
echo.
echo CVT-LZH is the correct file to use.
echo.
echo.
goto END
:BAD
echo.
echo ERROR! %1 has some type of error.
echo.
echo Now moving %1 to the BAD.$$$ subdirectory.
echo.
echo.
if not exist \bad.$$$\nul md \bad.$$$
copy ..\%1 \bad.$$$ > nul
del ..\%1
:DONE
echo y | del *.* > nul
cd ..
:END
exit