home *** CD-ROM | disk | FTP | other *** search
/ Bila Vrana / BILA_VRANA.iso / 003A / TBAV801.ZIP / INSTALL.BAT < prev    next >
DOS Batch File  |  1997-06-04  |  11KB  |  344 lines

  1. @echo off
  2. echo off
  3. echo        --- Thunderbyte Anti-Virus installation batch program ---
  4. echo.
  5.  
  6. rem     * Make sure that we can find the utilities in the current directory
  7. if not exist TBSCAN.EXE goto error1
  8.  
  9. rem     * Find out if we are upgrading a previous version in the current dir
  10. if exist TBSTART.BAT goto pathexists
  11.  
  12. rem     * Make sure that the user specified a destination path
  13. if %1X==X goto error2
  14.  
  15. rem     * Make sure the target path exists or can be created
  16. if exist %1\nul goto pathexists
  17. md %1
  18. if not exist %1\nul goto error3
  19. :pathexists
  20.  
  21. rem     * Make sure user did not type something like 'C:' :-)
  22. if exist %1\CONFIG.SYS goto error5
  23.  
  24. echo Please read the License.Txt file. By using the TBAV package you
  25. echo agree with our license agreement. You can print the License.Txt
  26. echo file by typing the following command on the DOS command line:
  27. echo    Copy License.Txt Lpt1
  28. echo Press Ctrl-C to abort this installation batch file, or
  29. pause
  30.  
  31. echo.
  32. echo This installation batch file of the shareware version of TBAV
  33. echo is not the same as the full featured installation program of the
  34. echo commercial version of TBAV. (The main reason for the omission of
  35. echo the installation program is to save disk space and to minimize
  36. echo download time). Therefore the installation procedure might
  37. echo differ from the procedure described in the manual.
  38. echo.
  39.  
  40. rem     * If TbScanX is active, de-activate it.
  41. if not exist SCANX goto notres
  42. if exist %1\tbscanx.exe %1\tbscanx /off
  43.  
  44. :notres
  45. rem     * Copy the TBAV utilities if necessary
  46. if exist dummy.tst del dummy.tst >nul
  47. if exist %1\dummy.tst del %1\dummy.tst >nul
  48. echo TEST >%1\dummy.tst
  49. if exist dummy.tst goto filesexists
  50. if not exist %1\dummy.tst goto error4
  51. echo TbSetup will now delete the Anti-Vir.Dat file of a previous
  52. echo TBAV version if it exists in directory %1
  53. pause
  54. rem     * If Anti-Vir.Dat already exists and is hidden, delete it...
  55. tbsetup %1 remove
  56. cls
  57. echo Copying files. Please wait...
  58. copy addendum.txt %1 >nul
  59. copy agents.txt %1 >nul
  60. copy anti-vir.dat %1 >nul
  61. copy appnotes.txt %1 >nul
  62. copy esass.pgp %1 >nul
  63. copy file_id.diz %1 >nul
  64. copy install.bat %1 >nul
  65. copy license.txt %1 >nul
  66. copy makeresc.bat %1 >nul
  67. copy register.exe %1 >nul
  68. copy report.txt %1 >nul
  69. copy security.txt %1 >nul
  70. copy tbav.txt %1 >nul
  71. copy tbav.exe %1 >nul
  72. copy tbav.lng %1 >nul
  73. copy tbav.msg %1 >nul
  74. copy tbcheck.exe %1 >nul
  75. copy tbclean.exe %1 >nul
  76. copy tbdel.com %1 >nul
  77. copy tbdisk.exe %1 >nul
  78. copy tbdriver.exe %1 >nul
  79. copy tbdriver.lng %1 >nul
  80. copy tbfile.exe %1 >nul
  81. copy tbkey.exe %1 >nul
  82. copy tblog.exe %1 >nul
  83. copy tbmem.exe %1 >nul
  84. copy tbscan.def %1 >nul
  85. copy tbscan.exe %1 >nul
  86. copy tbscan16.exe %1 >nul
  87. copy tbscan32.exe %1 >nul
  88. copy tbscan.lng %1 >nul
  89. copy tbscan.sig %1 >nul
  90. copy tbscanx.exe %1 >nul
  91. copy tbsetup.dat %1 >nul
  92. copy tbsetup.exe %1 >nul
  93. copy tbutil.exe %1 >nul
  94. copy tbutil.lng %1 >nul
  95. copy nvclean.* %1 >nul
  96. copy veldman.pgp %1 >nul
  97. copy esass.pgp %1 >nul
  98. copy tbav.faq %1 >nul
  99. copy tbmon.com %1 >nul
  100. copy whatsnew.* %1 >nul
  101. if %_4ver%x==x copy descript.ion %1 >nul
  102.  
  103. :filesexists
  104. del %1\dummy.tst >nul
  105. if not exist %1\docs.exe goto nopack
  106. %1\docs -o %1
  107. del %1\docs.exe >nul
  108. :nopack
  109.  
  110. rem     * DOS has no interactive batch file commands,
  111. rem     * so we create a special program to solve that!
  112. rem     * the 'garbage' in the echo command is program code
  113. rem     * to read a key into an errorlevel, the program code
  114. rem     * will be copied into an executable file.
  115. echo ═êα╧┤L═! >%1\ask.com
  116.  
  117. echo.
  118. echo TbSetup will now generate or update the Anti-Vir.Dat file
  119. echo of the directory %1
  120. pause
  121. rem     * create or update the Anti-Vir.Dat records of the TBAV utilities
  122. %1\TBSETUP %1
  123.  
  124. cls
  125. rem     * do not overwrite an existing TBAV setup.
  126. if exist %1\TBSTART.BAT goto upgrade
  127.  
  128. echo.
  129. echo The Thunderbyte Anti-Virus utilities have been copied to the destination
  130. echo directory. It is recommended to read the documentation of TBAV thoroughly
  131. echo and to make a customized setup. One of the advantages of the Thunderbyte
  132. echo Anti-Virus utilities is flexibility and the possibility to configure
  133. echo them to suit your needs in an optimal way.
  134. echo.
  135. echo This installation batch file helps you to setup the utilities in their
  136. echo most standard and non-customized way.
  137. echo Do you want to continue? (Y/n)
  138. %1\ask
  139. if not errorlevel 1 goto nosetup
  140.  
  141. rem     * make a backup of the AUTOEXEC.BAT file!
  142. echo.
  143. echo Backing up C:\AUTOEXEC.BAT to C:\AUTOEXEC.ORG...
  144. copy c:\autoexec.bat c:\autoexec.org >nul
  145.  
  146. rem     * create a TBSTART.BAT file in the TBAV directory.
  147. echo @echo off >%1\TBSTART.BAT
  148. echo echo off >>%1\TBSTART.BAT
  149.  
  150. echo.
  151. echo For easy access of the TBAV utilities it is recommended to put them
  152. echo into your PATH environment variable.
  153. echo Do you want to add %1 to your PATH statement? (Y/n)
  154. %1\ask
  155. if not errorlevel 1 goto dosetup
  156. rem     * add the PATH statement to the end of the AUTOEXEC.BAT file.
  157. echo PATH=%%PATH%%;%1 >>C:\AUTOEXEC.BAT
  158.  
  159. :dosetup
  160. echo.
  161. echo TbSetup will now process your drives to generate the Anti-Vir.Dat files.
  162. pause
  163. rem     * process the rest of the machine, but do not touch existing information!
  164. %1\TbSetup NewOnly AllDrives
  165.  
  166. :tbdriver
  167. cls
  168. echo.
  169. echo The TBAV package contains some utilities that can be installed in the memory
  170. echo of your PC. Do you want to add them to your AUTOEXEC.BAT file? (Y/n)
  171. %1\ask
  172. if not errorlevel 1 goto autoscan
  173. rem     * create a TBSTART.BAT file in the TBAV directory.
  174. echo %1\TbDriver >>%1\TBSTART.BAT
  175.  
  176. echo.
  177. echo TBSCANX is a memory resident virus scanner.
  178. echo Do you want to install it? (Y/n)
  179. %1\ask
  180. if not errorlevel 1 goto tbcheck
  181. rem     * add the TbScanX statement to the TBSTART.BAT file.
  182. echo %1\TbScanX EMS XMS >>%1\TBSTART.BAT
  183.  
  184. :tbcheck
  185. echo.
  186. echo TBCHECK is a memory resident integrity checker.
  187. echo Do you want to install it? (Y/n)
  188. %1\ask
  189. if not errorlevel 1 goto tbmem
  190. rem     * add the TbCheck statement to the TBSTART.BAT file.
  191. echo %1\TbCheck noavok=ab >>%1\TBSTART.BAT
  192.  
  193. :tbmem
  194. echo.
  195. echo TBMEM is a resident memory guard.
  196. echo Do you want to install it? (Y/n)
  197. %1\ask
  198. if not errorlevel 1 goto tbfile
  199. rem     * add the TbMem statement to the TBSTART.BAT file.
  200. echo %1\TbMem >>%1\TBSTART.BAT
  201.  
  202. :tbfile
  203. echo.
  204. echo TBFILE is a resident file guard.
  205. echo Do you want to install it? (Y/n)
  206. %1\ask
  207. if not errorlevel 1 goto autoscan
  208. rem     * add the TbFile statement to the TBSTART.BAT file.
  209. echo %1\TbFile >>%1\TBSTART.BAT
  210.  
  211. :autoscan
  212. echo.
  213. echo Do you want the system to be scanned automatically for viruses every day? (Y/n)
  214. %1\ask
  215. if not errorlevel 1 goto addcall
  216. rem     * add the TbScan statement to the TBSTART.BAT file.
  217. echo %1\TbScan Once AllDrives >>%1\TBSTART.BAT
  218.  
  219. :addcall
  220. if exist C:\TEMP.BAT del C:\TEMP.BAT >nul
  221. echo call %1\TBSTART.BAT >C:\TEMP.BAT
  222. copy /a C:\TEMP.BAT + C:\AUTOEXEC.BAT C:\TEMP2.BAT >nul
  223. copy C:\TEMP2.BAT C:\AUTOEXEC.BAT >nul
  224. del C:\TEMP.BAT >nul
  225. del C:\TEMP2.BAT >nul
  226.  
  227. :ready
  228. echo.
  229. echo Do you want to scan your drives now? (Y/n)
  230. %1\ask
  231. if not errorlevel 1 goto starttbav
  232. %1\TbScan AllDrives
  233.  
  234. :starttbav
  235. cls
  236. :nosetup
  237. echo.
  238. echo It is highly recommended to print the TBAV user manual.
  239. echo You can do this with the following DOS command:
  240. echo    Copy TBAV.TXT Lpt1
  241. echo.
  242. echo If you are upgrading from previous TBAV versions, it is recommended
  243. echo to print the WHATSNEW files and the Addendum.Txt.
  244. echo You can do this with the following DOS command:
  245. echo    Copy WHATSNEW.* Lpt1
  246. echo    Copy ADDENDUM.TXT Lpt1
  247. echo.
  248. echo The menu program TBAV.EXE can be used to read the documentation files.
  249. echo Do you want to start TBAV now? (Y/n)
  250. %1\ask
  251. if not errorlevel 1 goto flush
  252. %1\TBAV
  253. goto end
  254.  
  255. :upgrade
  256. echo.
  257. rem     * Delete all stuff we don't support anymore
  258. echo Install.Bat will delete some obsolete files from previous TBAV
  259. echo versions which are not supported anymore.
  260. echo.
  261. if exist %1\TbScan.Com del %1\TbScan.Com >nul
  262. if exist %1\TbScan.Msg del %1\TbScan.Msg >nul
  263. if exist %1\TbScan.ECI del %1\TbScan.ECI >nul
  264. if exist %1\VirScan.Dat del %1