home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 4 / AACD04.ISO / Welcome < prev    next >
AmigaDOS Script File  |  1999-12-02  |  7KB  |  211 lines

  1. .key CHECK/K,QUIET/K,VOL/K
  2. .bra {
  3. .ket }
  4.  
  5. ;set echo on
  6.  
  7. ;;; CD to AACD root if run from elsewhere, e.g. AutoRun
  8. cd >NIL: {VOL}
  9. ;;;
  10. ;;; Check argument - exit if Welcome has been run, otherwise ask
  11.     If {CHECK} EQ "YES"
  12.         Assign >NIL: AACD: EXISTS
  13.         If NOT WARN
  14.             Skip ABORT
  15.         Else
  16.             set init `:System/C/RequestChoice "Amiga Active CD" "Some assigns need to be made before we can proceed.*NYou can remove them later with the RemoveCD icon" "OK|Cancel"`
  17.             If $init EQ 0
  18.                 Skip ABORT
  19.                 EndIf
  20.             EndIf
  21.         EndIf
  22. ;;;
  23. ;;; Skip to HTML if Welcome has already been run
  24. Assign >NIL: AACD: EXISTS
  25. If NOT WARN
  26.     Skip HTML
  27.     EndIf
  28. ;;;
  29. ;;; Set up temporary assign
  30. Assign AACDtmp: :
  31. set ReqTitle Welcome to the Amiga Active CD
  32. ;;;
  33. ;;; Check for some system assigns
  34. ; MUI
  35. Assign MUI: EXISTS >NIL:
  36. If WARN
  37.     AACDtmp:System/C/RequestChoice >NIL: "`get ReqTitle`" "Some of the software on this CD requires MUI*NIf you use it regularly you should install MUI to your hard drive.*NThe installer is in the CDTools drawer of this CD" "I see"
  38.     Assign >NIL: MUI: AACDtmp:CDTools/MUI
  39.     Assign >NIL: LIBS: AACDtmp:CDTools/MUI/libs ADD
  40.     EndIf
  41. ; ClassAct
  42. If NOT EXISTS LIBS:window.class
  43.     AACDtmp:System/C/RequestChoice >NIL: "`get ReqTitle`" "Some of the software on this CD requires ClassAct*NIf you use it regularly you should install ClassAct to your hard drive.*NThe installer is in the CDTools drawer of this CD" "I see"
  44.     EndIf
  45. ;;;
  46. ;;; Start arexx if not running
  47. AACDtmp:System/rexxc/rx "address command" >NIL:
  48. If WARN
  49.     AACDtmp:System/System/RexxMast >NIL:
  50.     EndIf
  51. ;;;
  52. ;;; Make sure files needed by CD system are available
  53. ; muirexx.library
  54. If NOT EXISTS LIBS:muirexx.library
  55.     Copy >NIL: AACDtmp:CDTools/MUI/Libs/muirexx.library MUI:Libs CLONE
  56. Else
  57.     Version >NIL: muirexx.library 19 9
  58.     If WARN
  59.         Copy >NIL: AACDtmp:CDTools/MUI/Libs/muirexx.library MUI:Libs CLONE
  60.         EndIf
  61.     EndIf
  62. ; icon.mcc
  63. Version >NIL: MUI:Libs/MUI/Icon.mcc 1 1
  64. If WARN
  65.     Copy >NIL: AACDtmp:Icon.mcc MUI:Libs/MUI CLONE
  66.     EndIf
  67. ; MUIRexx
  68. which >NIL: MUIRexx
  69. if WARN
  70.     copy AACDtmp:MUIRexx SYS:Rexxc clone quiet'
  71.     path SYS:Rexxc ADD
  72.     endif
  73. ; AACDfile
  74. If NOT EXISTS C:AACDfile
  75.     Copy >NIL: AACDtmp:System/C/AACDfile C: CLONE QUIET
  76.     EndIf
  77. ; IDer
  78. Version >NIL: C:IDer 1 6
  79. If WARN
  80.     Copy >NIL: AACDtmp:System/C/IDer C: CLONE
  81.     EndIf
  82. ; FlashFind
  83. which >NIL: FlashFind
  84. If WARN
  85.     copy AACDtmp:System/C/FlashFind C: clone quiet
  86.     Endif
  87. ; AWeb config
  88. If NOT EXISTS ENVARC:AWeb3DEMO
  89.     Makedir >NIL: ENVARC:AWeb3DEMO
  90.     Makedir >NIL: ENV:AWeb3DEMO
  91.     Endif
  92. If NOT EXISTS ENVARC:AWeb3DEMO/Amigactive
  93.     Makedir >NIL: ENVARC:AWeb3DEMO/Amigactive
  94.     Makedir >NIL: ENV:AWeb3DEMO/Amigactive
  95.     Copy AACDtmp:System/Prefs/env-archive/AWeb3DEMO/Amigactive/#? ENVARC:AWeb3DEMO/Amigactive CLONE QUIET
  96.     Copy AACDtmp:System/Prefs/env-archive/AWeb3DEMO/Amigactive/#? ENV:AWeb3DEMO/Amigactive CLONE QUIET
  97.     Endif
  98. If EXISTS ENVARC:AWeb3
  99.     If NOT EXISTS ENVARC:AWeb3/Amigactive
  100.         Makedir >NIL: ENVARC:AWeb3/Amigactive
  101.         Makedir >NIL: ENV:AWeb3/Amigactive
  102.         Copy AACDtmp:System/Prefs/env-archive/AWeb3DEMO/Amigactive/#? ENVARC:AWeb3/Amigactive CLONE QUIET
  103.         Copy AACDtmp:System/Prefs/env-archive/AWeb3DEMO/Amigactive/#? ENV:AWeb3/Amigactive CLONE QUIET
  104.         Endif
  105.     Endif
  106. ;;;
  107. ;;; Give option for setting CD preferences, if not already done
  108. If NOT EXISTS ENV:AACD.prefs
  109.     If NOT EXISTS S:AACD.prefs
  110.         Version >NIL: version 39
  111.         If NOT WARN
  112.             Copy >NIL: AACDtmp:CDTools/S/AACD.prefs ENV:
  113.             Copy >NIL: AACDtmp:CDTools/S/AACD.prefs ENVARC:
  114.             set NoPrefs 1
  115.         Else
  116.             Copy >NIL: AACDtmp:CDTools/S/AACD.prefs_OS2 ENV:AACD.prefs
  117.             EndIf
  118.         EndIf
  119.     EndIf
  120. If NOT EXISTS ENV:AACDfile.prefs
  121.     If NOT EXISTS S:AACDfile.prefs
  122.         Version >NIL: version 39
  123.         If NOT WARN
  124.             Copy >NIL: AACDtmp:CDTools/S/AACDfile.prefs ENV:
  125.             Copy >NIL: AACDtmp:CDTools/S/AACDfile.prefs ENVARC:
  126.             set NoPrefs 1
  127.         Else
  128.             Copy >NIL: AACDtmp:CDTools/S/AACDfile.prefs_OS2 ENV:AACDfile.prefs
  129.             EndIf
  130.         EndIf
  131.     EndIf
  132. If $NoPrefs EQ 1
  133.     set edit `RequestChoice "Amigaactive CD" "AACD has a preferences program to specify*N the tools used to view/hear different types of files.*NWould you like to run it now?" "Yes|No"`
  134.     If $edit EQ 1
  135.         stack 16384
  136.         MuiRexx AACDPrefs port AACDPREFS
  137.     Else
  138.         RequestChoice >NIL: "Amiga Active CD" "You can run AACD preferences at any time.*NEither from its icon or from the Setup page of the documentation." "OK"
  139.         EndIf
  140.     EndIf
  141. ;;;
  142. ;;; Set assigns for programs on this CD and system drawers
  143. Execute AACDtmp:CDTools/S/ThisCD
  144. Assign >NIL: DEVS:    AACDtmp:System/Devs ADD
  145. Assign >NIL: Fonts:   AACDtmp:System/Fonts ADD
  146. Assign >NIL: Libs:    AACDtmp:System/Libs ADD
  147. Assign >NIL: L:       AACDtmp:System/L ADD
  148. Assign >NIL: S:       AACDtmp:CDTools/S ADD
  149. Assign >NIL: LIBS:    AACDtmp:System/Classes ADD
  150.  
  151. ; Make environment variables defined on CD available to system
  152. Failat 21
  153. Assign >NIL: ENV: AACDtmp:System/Prefs/Env-Archive ADD
  154. ; For HappyENV users
  155. If FAIL
  156.     Assign >NIL: ENVARC: AACDtmp:System/Prefs/Env-Archive ADD
  157.     EndIf
  158. ;;;
  159. ;;;Check for NewIcons if not already running
  160. If $NoNewIcons NOT EQ TRUE
  161.     AACDtmp:System/C/isnirunning
  162.     If NOT WARN
  163.         Version >NIL: Version 44
  164.         If Warn
  165.             set RunNI `AACDtmp:System/C/RequestChoice "Amiga Active CD" "This CD is set up for use with NewIcons*NIf you do not run Newicons the icon*Nimages and layout may look strange.*N*NWould you like to run NewIcons now?" "Yes|No"`
  166.             If $RunNI EQ 1
  167.                 Run <>NIL: AACDtmp:System/C/NewIcons
  168.                 EndIf
  169.             EndIf
  170.         EndIf
  171.     EndIf
  172. ;;;
  173. ;;; Change temporary assign to permanent one
  174. If {QUIET} NOT EQ "YES"
  175.     Run >NIL: RequestChoice >NIL: "`get ReqTitle`" "We have set up some assigns to run software from the CD.*N*NIf you wish to remove the CD from the drive, doubleclick the RemoveCD icon,*Notherwise the icon will stay on your Workbench." " OK "
  176.     Endif
  177. Assign AACD: AACDtmp:
  178. Assign AACDtmp:
  179. ;;;
  180. ;;; Load HTML - using registered AWeb if available
  181. LAB HTML
  182. If {QUIET} NOT EQ "YES"
  183.     set Browser AACD:AACD/WebSites/AWeb3/AWebDemo 
  184.     Assign >NIL: AWeb3: EXISTS
  185.     If NOT WARN
  186.         Version >NIL: AWeb3:AWeb-II 3 3
  187.         If NOT WARN
  188.             set Browser AWeb3:AWeb-II
  189.             If NOT EXISTS ENVARC:AWeb3/Amigactive
  190.                 Makedir >NIL: ENVARC:AWeb3/Amigactive
  191.                 Makedir >NIL: ENV:AWeb3/Amigactive
  192.                 copy >NIL: AACD:System/Prefs/Env-Archive/AWeb3DEMO/AmigActive/#? ENVARC:AWeb3/Amigactive clone
  193.                 copy >NIL: AACD:System/Prefs/Env-Archive/AWeb3DEMO/AmigActive/#? ENV:AWeb3/Amigactive clone
  194.                 EndIf
  195.             EndIf
  196.         EndIf
  197.     Run >NIL: $Browser Welcome.html LOCAL CONFIG Amigactive
  198.     Endif
  199. ;;;
  200. ;;; Show Newsflash
  201. If {QUIET} NOT EQ "YES"
  202.     If `cd` GT $AACDlast
  203.         Run >NIL: AACD:System/Rexxc/RX AACD:CDTools/S/NewsFlash.awebrx
  204.         EndIf
  205.     EndIf
  206. ;;;
  207. ;;; Abort
  208. LAB ABORT
  209. ;;;
  210.  
  211.