home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 8 Other / 08-Other.zip / warpst04.zip / INSTALL.CMD < prev    next >
OS/2 REXX Batch file  |  1996-04-02  |  6KB  |  211 lines

  1. /* Begin Install.CMD for WarpStart */
  2. '@Echo off'
  3. adummy = ''
  4. say ''
  5. say ''
  6. say 'Welcome to WarpStart:'
  7. say 'This program will copy the WarpStart files to a directory on your'
  8. say 'hard drive.  it will then creat a folder on the desktop for you.'
  9. say 'It will NOT change your system in any way.'
  10. say ''
  11. dummy = charout(,'Do you wish to continue with this install? [y/N] ')
  12. parse upper pull adummy
  13. if left(adummy,1) \= 'Y' then do
  14.   exit
  15. end
  16. adummy = ''
  17.  
  18. curdir = directory()
  19.  
  20. do
  21.     say ''
  22.     say 'Please enter the drive letter to install WarpStart (Ex. C:)'
  23.     say 'You MUST enter the full drive letter, C: <- Notice the colon'
  24.     say '--'
  25.     parse upper pull dummy
  26.     ADDRESS CMD dummy
  27.     ADDRESS CMD "CD\"
  28.     ADDRESS CMD "MD WarpStrt 2>NUL"
  29.     ADDRESS CMD "CD WarpStrt"
  30.     olddir = curdir
  31.     curdir = dummy'\WarpStrt'
  32.     say ''
  33.     say 'Current sub-directory: 'curdir
  34.     say ''
  35.     say 'Install WarpStart into the current'
  36.     dum = charout(, 'sub-directory? [Y/n] ')
  37.     parse upper pull dummy
  38.     if left(dummy,1) = 'N' then exit
  39.     say ''
  40. end
  41.  
  42. say ''
  43. say 'Installing WarpStart, copying files.. Please wait...'
  44.  
  45. no_obje = 11
  46. InsCmd.1 = copy olddir'\IBMWW.INF'
  47. InsCmd.2 = copy olddir'\INSTALL.CMD'
  48. InsCmd.3 = copy olddir'\OWTD.INF'
  49. InsCmd.4 = copy olddir'\pcmtable.inf'
  50. InsCmd.5 = copy olddir'\tricks.inf'
  51. InsCmd.6 = copy olddir'\WarpCon.txt'
  52. InsCmd.7 = copy olddir'\WARPFAQ.INF'
  53. InsCmd.8 = copy olddir'\WarpPerf.TXT'
  54. InsCmd.9 = copy olddir'\WarpStrt.txt'
  55. InsCmd.10 = copy olddir'\WarpStrt.ICO'
  56. InsCmd.11 = copy olddir'\NICCERT.TXT'
  57.  
  58. /* add cleanup rotuine */
  59. if olddir \= curdir then
  60. do
  61.   do obje=1 to no_obje
  62.      ADDRESS CMD InsCmd.obje
  63.   end
  64. end
  65.  
  66. /* load rexx utility functions */
  67.  
  68. rc = stream('WARPFAQ.INF','c','query exists')
  69. if rc = '' then
  70. do
  71.   say 'Sorry, WARPFAQ.INF not found.  Must not be right directory. Terminating.'
  72.   exit
  73. end
  74.  
  75. say ''
  76. say 'If you see any SYS### errors from this point on, please ignore them'
  77. say ''
  78.  
  79. call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  80. call SysLoadFuncs
  81.  
  82. /* say it, then do it */
  83.  
  84. say "Creating WarpStart folder..."
  85.  
  86. /* first, create WarpStart folder */
  87.  
  88. title = "Warp Start"
  89. classname = 'WPFolder'
  90. location = '<WP_DESKTOP>'
  91. setup = 'OBJECTID=<WarpStart_Folder>;OPEN=DEFAULT;ICONFILE='curdir'\WarpStrt.ico'
  92. result=SysCreateObject(classname,title,location,setup,f)
  93.  
  94. /* If folder exists, ask before updating */
  95.  
  96. if result = 0 then
  97. do
  98.   existed = 'TRUE'
  99.   say ''
  100.   say 'The WarpStart folder already exists.'
  101.   dum = Charout(, 'Do you really want to create a duplicate? [Y/n] ')
  102.   parse upper pull dummy
  103.   if left(dummy,1) = 'N' then
  104.   do
  105.     rc = stream('WARPFAQ.INF','c','query exists')
  106.     if rc = '' then
  107.     do
  108.       say 'Sorry, WarpFAQ.INF not found.  Unarchive does not appear to have '
  109.       say 'been successful.'
  110.       exit
  111.     end
  112.  
  113.     do
  114.       say ''
  115.       say 'Install appears to have been sucessful!'
  116.       say ''
  117.     end
  118.  
  119.     say 'Heres to a succesful Warp Start'
  120.     say ''
  121.  
  122.  
  123.     exit
  124.   end
  125.   say ''
  126. end
  127.  
  128. say "Creating objects in WarpStart folder..."
  129.  
  130. /* now, create program objects in Warp Start folder */
  131.  
  132. title = "Welcome to Warp Start"
  133. classname = 'WPProgram'
  134. location = '<WarpStart_Folder>'
  135. setup = 'EXENAME='E.EXE';STARTUPDIR='curdir';PARAMETERS='WarpStrt.TXT''
  136. call SysCreateObject classname,title,location,setup,u
  137.  
  138. title = "OS/2 Warp Frequently Asked Questions"
  139. classname = 'WPProgram'
  140. location = '<WarpStart_Folder>'
  141. setup = 'EXENAME='VIEW.EXE';STARTUPDIR='curdir';PARAMETERS='WARPFAQ.INF''
  142. call SysCreateObject classname,title,location,setup,u
  143.  
  144. title = "IBM World Wide Electronic Resource Guide"
  145. classname = 'WPProgram'
  146. location = '<WarpStart_Folder>'
  147. setup = 'EXENAME='VIEW.EXE';STARTUPDIR='curdir';PARAMETERS='IBMWW.INF''
  148. call SysCreateObject classname,title,location,setup,u
  149.  
  150. title = "OS/2 Warp Troubleshooting Demystified"
  151. classname = 'WPProgram'
  152. location = '<WarpStart_Folder>'
  153. setup = 'EXENAME='VIEW.EXE';STARTUPDIR='curdir';PARAMETERS='OWTD.INF''
  154. call SysCreateObject classname,title,location,setup,u
  155.  
  156. title = "OS/2 Hardware Compatibilty List"
  157. classname = 'WPProgram'
  158. location = '<WarpStart_Folder>'
  159. setup = 'EXENAME='VIEW.EXE';STARTUPDIR='curdir';PARAMETERS='pcmtable.INF''
  160. call SysCreateObject classname,title,location,setup,u
  161.  
  162. title = "Stupid OS/2 Tricks"
  163. classname = 'WPProgram'
  164. location = '<WarpStart_Folder>'
  165. setup = 'EXENAME='VIEW.EXE';STARTUPDIR='curdir';PARAMETERS='tricks.INF''
  166. call SysCreateObject classname,title,location,setup,u
  167.  
  168. title = "OS/2 Warp Connect Tips and Tricks"
  169. classname = 'WPProgram'
  170. location = '<WarpStart_Folder>'
  171. setup = 'EXENAME='E.EXE';STARTUPDIR='curdir';PARAMETERS='WarpCon.TXT''
  172. call SysCreateObject classname,title,location,setup,u
  173.  
  174. title = "Performance Tuning OS/2 Warp"
  175. classname = 'WPProgram'
  176. location = '<WarpStart_Folder>'
  177. setup = 'EXENAME='E.EXE';STARTUPDIR='curdir';PARAMETERS='WarpPerf.TXT''
  178. call SysCreateObject classname,title,location,setup,u
  179.  
  180. title = "Network Interface Cards Certified for IBM LAN Systems"
  181. classname = 'WPProgram'
  182. location = '<WarpStart_Folder>'
  183. setup = 'EXENAME='E.EXE';STARTUPDIR='curdir';PARAMETERS='NICCERT.TXT''
  184. call SysCreateObject classname,title,location,setup,u
  185.  
  186.  
  187.   do
  188.     rc = stream('WARPFAQ.INF','c','query exists')
  189.     if rc = '' then
  190.     do
  191.       say 'Sorry, WarpFAQ.INF not found.  Unarchive does not appear to have '
  192.       say 'been successful.'
  193.       exit
  194.     end
  195.  
  196.  
  197. do
  198.   say ''
  199.   say 'Install appears to have been sucessful!'
  200.   say ''
  201. end
  202.  
  203.  
  204.   say ''
  205.  
  206. end
  207.  
  208. say 'Heres to a succesful Warp Start'
  209.  
  210. /* END Install Program */
  211.