home *** CD-ROM | disk | FTP | other *** search
/ Boston 2 / boston-2.iso / DOS / PROGRAM / BASIC / POWBASIC / LIBRARY3 / OPSYS1.ZIP / INSTALL.BAT < prev    next >
DOS Batch File  |  1990-11-15  |  10KB  |  171 lines

  1. @echo off
  2. rem
  3. rem +-----------------------------------------+
  4. rem !   OPSYS Install Batch File              !
  5. rem !   Copyright (c) 1990 mcTRONic Systems   !
  6. rem !   Revised on: August 31, 1990           !
  7. rem !   File Name: INSTALL.BAT                !
  8. rem +-----------------------------------------+
  9. rem
  10. cls
  11. echo    ╔═══════════════════════════════════════════════════════════════════════╗
  12. echo    ║                                                                       ║
  13. echo    ║          ▒▒▒▒▒▄     ▒▒▒▒▒▄     ▒▒▒▒▒▄     ▒▄  ▒▄     ▒▒▒▒▒▄           ║
  14. echo    ║          ▒█▀▀▒█     ▒█▀▀▒█     ▒▀▀▀▀▀     ▒█▄▄▒█     ▒▀▀▀▀▀           ║
  15. echo    ║          ▒█  ▒█     ▒▒▒▒▒█      ▀▀▀▒▄      ▒▒▒█▀      ▀▀▀▒▄           ║
  16. echo    ║          ▒▒▒▒▒█     ▒█▀▀▀▀     ▒▒▒▒▒█       ▒█▀      ▒▒▒▒▒█           ║
  17. echo    ║           ▀▀▀▀▀      ▀           ▀▀▀▀        ▀        ▀▀▀▀▀           ║
  18. echo    ║                                                                       ║
  19. echo    ║         An Operating System Multi-Configuration Menu Utility          ║
  20. echo    ║                                                                       ║
  21. :dosok
  22. if NOT exist INSTALL.BAT goto c_error
  23. if "%1"=="" goto a_error
  24. for %%c in (a: A: b: B:) do if %1==%%c goto d_error
  25. for %%c in (Help HELP help ) do if %1==%%c goto help
  26. if NOT exist %1\nul goto b_error
  27. :start
  28. echo    ╠═══════════════════════════════════════════════════════════════════════╝
  29. echo    ║   Install OPSYS in: %1\OPSYS
  30. echo    ╠═══════════════════════════════════════════════════════════════════════╗
  31. echo    ║                                                                       ║
  32. echo    ║ This batch file will install  OPSYS and all of its files on the Hard  ║
  33. echo    ║ Disk you have specified above.  Would you like to continue with this  ║
  34. echo    ║ installation? (Yes/No)                                                ║
  35. echo    ║                                                                       ║
  36. echo    ╚═══════════════════════════════════════════════════════════════════════╝
  37. bh YN
  38. if errorlevel 2 install help
  39. cls
  40. echo    ╔═══════════════════════════════════════════════════════════════════════╗
  41. echo    ║                                                                       ║
  42. echo    ║          ▒▒▒▒▒▄     ▒▒▒▒▒▄     ▒▒▒▒▒▄     ▒▄  ▒▄     ▒▒▒▒▒▄           ║
  43. echo    ║          ▒█▀▀▒█     ▒█▀▀▒█     ▒▀▀▀▀▀     ▒█▄▄▒█     ▒▀▀▀▀▀           ║
  44. echo    ║          ▒█  ▒█     ▒▒▒▒▒█      ▀▀▀▒▄      ▒▒▒█▀      ▀▀▀▒▄           ║
  45. echo    ║          ▒▒▒▒▒█     ▒█▀▀▀▀     ▒▒▒▒▒█       ▒█▀      ▒▒▒▒▒█           ║
  46. echo    ║           ▀▀▀▀▀      ▀           ▀▀▀▀        ▀        ▀▀▀▀▀           ║
  47. echo    ║                                                                       ║
  48. echo    ║         An Operating System Multi-Configuration Menu Utility          ║
  49. echo    ║                                                                       ║
  50. echo    ╠═══════════════════════════════════════════════════════════════════════╣
  51. echo    ║                                                                       ║
  52. if exist %1\opsys\OPSYS.EXE goto update
  53. echo    ║       OPSYS installation now in progress.  Please stand by ....       ║
  54. echo    ║                                                                       ║
  55. echo    ╚═══════════════════════════════════════════════════════════════════════╝
  56. goto cont
  57. :update
  58. echo    ║          OPSYS update now in progress.  Please stand by ....          ║
  59. echo    ║                                                                       ║
  60. echo    ╚═══════════════════════════════════════════════════════════════════════╝
  61. :cont
  62. if NOT exist %1\OPSYS\nul md %1\OPSYS >nul
  63. copy *.* %1\OPSYS >nul
  64. %1\OPSYS\
  65. cd %1\OPSYS
  66. IF EXIST INSTALL.BAT DEL INSTALL.BAT
  67. IF EXIST OPSYS.EXE DEL OPSYS.EXE
  68. if exist OPSYS.BIN RENAME OPSYS.BIN OPSYS.EXE
  69. CLS
  70. echo    ╔═══════════════════════════════════════════════════════════════════════╗
  71. echo    ║                                                                       ║
  72. echo    ║          ▒▒▒▒▒▄     ▒▒▒▒▒▄     ▒▒▒▒▒▄     ▒▄  ▒▄     ▒▒▒▒▒▄           ║
  73. echo    ║          ▒█▀▀▒█     ▒█▀▀▒█     ▒▀▀▀▀▀     ▒█▄▄▒█     ▒▀▀▀▀▀           ║
  74. echo    ║          ▒█  ▒█     ▒▒▒▒▒█      ▀▀▀▒▄      ▒▒▒█▀      ▀▀▀▒▄           ║
  75. echo    ║          ▒▒▒▒▒█     ▒█▀▀▀▀     ▒▒▒▒▒█       ▒█▀      ▒▒▒▒▒█           ║
  76. echo    ║           ▀▀▀▀▀      ▀           ▀▀▀▀        ▀        ▀▀▀▀▀           ║
  77. echo    ║                                                                       ║
  78. echo    ║         An Operating System Multi-Configuration Menu Utility          ║
  79. echo    ║                                                                       ║
  80. echo    ╠═══════════════════════════════════════════════════════════════════════╣
  81. echo    ║                                                                       ║
  82. echo    ║ OPSYS  is  now installed  on your  hard drive  along with  all of its ║
  83. echo    ║ support files.    To print out the OPSYS manual type "DOCUTIL" at the ║
  84. echo    ║ DOS prompt.  If this is a Shareware copy please register your copy if ║
  85. echo    ║ you  decide to use  OPSYS.    To run  OPSYS  you must  change  to the ║
  86. echo    ║ installed directory and enter "OPSYS".    See the OPSYS Documentation ║
  87. echo    ║ for more information.  Thank You !                                    ║
  88. echo    ║                                                                       ║
  89. echo    ╚═══════════════════════════════════════════════════════════════════════╝
  90. echo       CHANGE TO "%1\OPSYS" AND ENTER "OPSYS"
  91. echo    ═════════════════════════════════════════════════════════════════════════
  92. pause
  93. OPSYS /p:%1\opsys
  94. :wantdoc
  95. cls
  96. echo    ╔══════════════════════════════════════════════════════╗
  97. echo    ║                                                      ║
  98. echo    ║  Would you like to run the  OPSYS Document, Display  ║
  99. echo    ║  and Print Utility DOCUTIL NOW (Yes/No)?             ║
  100. echo    ║                                                      ║
  101. echo    ╚══════════════════════════════════════════════════════╝
  102. bh yn
  103. if errorlevel 2 goto done
  104. if errorlevel 1 docutil
  105. GOTO DONE
  106. :help
  107. echo    ╠═══════════════════════════════════════════════════════════════════════╣
  108. goto e_error
  109. :a_error
  110. echo    ╠═══════════════════════════════════════════════════════════════════════╣
  111. echo    ║                                                                       ║
  112. echo    ║   This INSTALL.BAT file needs to know what  Hard Drive you want to    ║
  113. echo    ║   install OPSYS on.  ALL Hard Disk Drive Letters can be entered at    ║
  114. echo    ║   the DOS prompt.  If your HARD DRIVE is C:, D:, E:, F:, or G: and    ║
  115. echo    ║   the predefined  subdirectory name  \OPSYS  is OK, then enter the    ║
  116. echo    ║   Listed Hard Drive Letter to use, or press Q to Quit.                ║
  117. echo    ║                                                                       ║
  118. echo    ╚═══════════════════════════════════════════════════════════════════════╝
  119. bh CDEFGQ
  120. if errorlevel 6 goto nodrive
  121. if errorlevel 5 INSTALL G:
  122. if errorlevel 4 INSTALL F:
  123. if errorlevel 3 INSTALL E:
  124. if errorlevel 2 INSTALL D:
  125. if errorlevel 1 INSTALL C:
  126. :nodrive
  127. cls
  128. echo    ╔═══════════════════════════════════════════════════════════════════════╗
  129. echo    ║                                                                       ║
  130. echo    ║          ▒▒▒▒▒▄     ▒▒▒▒▒▄     ▒▒▒▒▒▄     ▒▄  ▒▄     ▒▒▒▒▒▄           ║
  131. echo    ║          ▒█▀▀▒█     ▒█▀▀▒█     ▒▀▀▀▀▀     ▒█▄▄▒█     ▒▀▀▀▀▀           ║
  132. echo    ║          ▒█  ▒█     ▒▒▒▒▒█      ▀▀▀▒▄      ▒▒▒█▀      ▀▀▀▒▄           ║
  133. echo    ║          ▒▒▒▒▒█     ▒█▀▀▀▀     ▒▒▒▒▒█       ▒█▀      ▒▒▒▒▒█           ║
  134. echo    ║           ▀▀▀▀▀      ▀           ▀▀▀▀        ▀        ▀▀▀▀▀           ║
  135. echo    ║                                                                       ║
  136. echo    ║         An Operating System Multi-Configuration Menu Utility          ║
  137. echo    ║                                                                       ║
  138. echo    ╠═══════════════════════════════════════════════════════════════════════╣
  139. echo    ║                                                                       ║
  140. echo    ║  PROBLEM: What is your TARGET Drive ?  A TARGET Drive is required!    ║
  141. goto e_error
  142. :b_error
  143. echo    ╠═══════════════════════════════════════════════════════════════════════╣
  144. echo    ║                                                                       ║
  145. echo    ║  PROBLEM: The drive\directory Specified DOES NOT EXIST!               ║
  146. goto e_error
  147. :c_error
  148. echo    ╠═══════════════════════════════════════════════════════════════════════╣
  149. echo    ║                                                                       ║
  150. echo    ║  PROBLEM: "INSTALL.BAT" is NOT Located in the Default Drive!          ║
  151. goto :e_error
  152. :d_error
  153. echo    ╠═══════════════════════════════════════════════════════════════════════╣
  154. echo    ║                                                                       ║
  155. echo    ║  PROBLEM: Floppy Disk installation not required.  For Hard Disk Only! ║
  156. :e_error
  157. echo    ║                                                                       ║
  158. echo    ║  Syntax: "INSTALL d:[\path]"                                          ║
  159. echo    ║                                                                       ║
  160. echo    ║  This INSTALL  batch file must be located in the default drive.  The  ║
  161. echo    ║  target disk drive d is a required parameter and must be a HARD DISK  ║
  162. echo    ║  DRIVE while the  \path  is optional.  The  final sub-directory will  ║
  163. echo    ║  always be named OPSYS.  INSTALL C:  will install OPSYS in C:\OPSYS.  ║
  164. echo    ║  INSTALL C:\UTILITY will install OPSYS in C:\UTILITY\OPSYS.   Please  ║
  165. echo    ║  rerun INSTALL with required parameters.                              ║
  166. echo    ╚═══════════════════════════════════════════════════════════════════════╝
  167. pause
  168. goto wantdoc
  169. :done
  170. cls
  171.