;***** MagicUserInterface Installation Script (transcript "Installing Magic User Interface...") (set @default-dest "SYS:") ;***** Introduction (complete 0) (message "The installation procedure has changed significantly since version 2.0 of " "MagicUserInterface. Instead of spreading the MUI related files all " "over your system, one single MUI directory will be created at some place " "of your choice. This directory will hold all necessary programs and " "libraries for a complete MUI installation. Depending on the available " "space on your harddisk, you may decide to install additional " "demonstration programs, documentation material and images." ) ;***** Old File Deletion (complete 5) (if (<> (exists "sys:classes/mui") 0) ( (if (askbool (help @askbool-help) (prompt "Some old MUI stuff is in your libs: drawer. Do you want to delete it now?")) ( (if (<> (exists "sys:libs/muimaster.library") 0) ( (delete ("sys:libs/muimaster.library") (prompt "Deleting old muimaster.library...") (help @deletefile-help) ) ) ) (foreach "sys:Classes/MUI" "#?.mui" (delete (tackon "sys:Classes/MUI" @each-name) (help @deletefile-help) ) ) (if (<> (exists "sys:Classes/Images") 0) ( (foreach "sys:Classes/Images" "mui#?.image" (delete (tackon "sys:Classes/Images" @each-name) (help @deletefile-help) ) ) ) ) (delete ("sys:Classes/MUI") (help @deletefile-help) ) ) ) ) ) (if (<> (exists "sys:prefs/mui") 0) ( (if (askbool (help @askbool-help) (prompt "The old preferences program is obsolete. Do you want to delete it now?")) ( (delete ("sys:Prefs/MUI") (help @deletefile-help) ) (delete ("sys:Prefs/MUI.info") (help @deletefile-help) ) ) ) ) ) (if (<> (exists "sys:prefs/MUI-Images") 0) ( (if (askbool (help @askbool-help) (prompt "The images in sys:prefs/MUI-Images have moved. Do you want to delete it now? CAUTION: If you have added some extra images here, be sure to copy them somewhere else before proceeding!")) ( (run "delete sys:Prefs/MUI-images#? all >nil:") ) ) (if (askbool (help @askbool-help) (prompt "Due to the new directory structure, your old preferences settings are no longer valid and must be deleted. This will not affect window positions and application private settings. Please don't worry, instead take a look at the prefs program's preset menu when reconfiguring MUI. Do you want to delete the old settings now?")) ( (run "delete envarc:mui/#?.prefs >nil:") (run "delete envarc:mui/MUIPREFS.cfg >nil:") ) ) ) ) (if (<> (exists "sys:locale/catalogs/Deutsch/MUI.catalog" (noreq)) 0) ( (delete ("sys:locale/catalogs/Deutsch/MUI.catalog") (help @deletefile-help) ) ) ) ;***** Destination Directory Selection & Creation (complete 10) (if (<> (exists "mui:" (noreq)) 0) ( (if (<> (exists "mui:MUI-Install" (noreq)) 0) ( (set muimsg "Please select a place for \"MagicUserInterface\". A drawer called \"MUI\" will be created here. The minimum space required is about 500 kB, a complete installation takes 2.5 MB.") ) ( (set @default-dest "mui:/") (set muimsg "MUI is already installed on your system. Press \"Proceed\" to update your installation or select a different path for the \"MUI\" drawer.") ) ) ) ( (set muimsg "Please select a place for \"MagicUserInterface\". A drawer called \"MUI\" will be created here. The minimum space required is about 500 kB, a complete installation takes 2.5 MB.") ) ) (set @default-dest (expandpath @default-dest)) (set destination (askdir (prompt muimsg) (help @askdir-help) (default @default-dest) ) ) (set destination (tackon destination "MUI")) (if (= (exists destination) 2) (message "A MUI drawer does already exist in the selected directory. By selecting \"Proceed\", " "you indicate that you want to update the MUI installation with the " "most recent version. Several MUI specific files will be overwritten!" ) ) (makedir destination (help @makedir-help) (infos) ) (run (cat "copy " "/MUI.info \"" destination ".info\"")) ;***** ReadMe Files (complete 15) (copyfiles (prompt "Installing ReadMe files...") (source "") (pattern "(LiesMich|ReadMe)") (dest destination) (infos) (help @copyfiles-help) ) ;***** Prefs Program (complete 20) (copylib (prompt "Installing Preferences Program...") (source "MUI") (dest destination) (infos) (help @copylib-help) ) ;***** Registration Program ;(complete 25) ; ;(copylib ; (prompt "Installing Registration Program...") ; (source "Docs/Registration") ; (dest destination) ; (infos) ; (help @copylib-help) ;) ;***** Master Library (complete 30) (copylib (prompt "Installing muimaster.library...") (source "Libs/muimaster.library") (dest (tackon destination "Libs")) (help @copylib-help) ) (run (cat "copy " "Libs.info \"" destination "\"")) ;***** External Classes (complete 35) (foreach "Libs/MUI" "#?.(mui|mcc|mcp)" (copylib (prompt "Installing external classes...") (source (tackon "Libs/MUI" @each-name)) (dest (tackon destination "Libs/MUI")) (help @copylib-help) ) ) ;***** Docs Drawer (complete 40) (copyfiles (prompt "Creating Docs Drawer...") (source "Docs") (dest (tackon destination "Docs")) (choices "Registration" "Changes" "ImageDesign" "Preview") (infos) (help @copyfiles-help) ) (run (cat "copy " "Docs.info \"" destination "\"")) ;***** Icons Drawer (complete 45) (copyfiles (prompt "Creating Icons Drawer...") (source "Icons") (dest (tackon destination "Icons")) (all) (infos) (help @copyfiles-help) ) (run (cat "copy " "Icons.info \"" destination "\"")) ;***** Choose Additional Stuff (complete 50) (set choice (askoptions (prompt "Please choose which of the following parts to install. They are not absolutely required, but if you have enough space left, you shoud install them anyway.") (choices "Additional Images" "English Documentation" "German Documentation" "Language Catalogs" "Example ARexx Scripts" "Demonstration Programs" "Developer Material") (help @askoptions-help) ) ) (if (<> 0 (BITAND choice 2)) ( (set echoice (askoptions (prompt "There are two formats available for the english documentation.") (choices "AmigaGuide Format (required for online help)" "TeX DVI Format (for printed manuals)") (help @askoptions-help) ) ) ) ) (if (<> 0 (BITAND choice 4)) ( (set gchoice (askoptions (prompt "There are two formats available for the german documentation.") (choices "AmigaGuide Format (required for online help)" "TeX DVI Format (for printed manuals)") (help @askoptions-help) ) ) ) ) ;***** Images (complete 55) (if (<> 0 (BITAND choice 1)) ( (copyfiles (prompt "Installing additional ILBM images...") (source "Images") (dest (tackon destination "Images")) (infos) (all) (help @copyfiles-help) ) (run (cat "copy " "Images.info \"" destination "\"")) (foreach "Libs/Images" "#?" (copylib (prompt "Installing additional BOOPSI images...") (source (tackon "Libs/Images" @each-name)) (dest (tackon destination "Libs/Images")) (help @copylib-help) ) ) ) ) ;***** English Docs (complete 60) (if (<> 0 (BITAND choice 2)) ( (run (cat "copy " "Docs/English.info \"" (tackon destination "Docs") "\"")) (if (<> 0 (BITAND echoice 1)) ( (copyfiles (prompt "Installing english AmigaGuide manual...") (source "Docs/English/MUI.guide") (dest (tackon destination "Docs/English")) (infos) (help @copyfiles-help) ) ) ) (if (<> 0 (BITAND echoice 2)) ( (if (<> (exists "Docs/English/MUI.dvi") 0) ( (copyfiles (prompt "Installing english DVI manual...") (source "Docs/English/MUI.dvi") (dest (tackon destination "Docs/English")) (infos) (help @copyfiles-help) ) ) ( (message "Due to space limitations, the english DVI manual is not present on the disk distribution.") ) ) ) ) ; (if (<> 0 (BITAND echoice 4)) ; ( ; (copyfiles ; (prompt "Installing english ASCII manual...") ; (source "Docs/English/MUI.doc") ; (dest (tackon destination "Docs/English")) ; (infos) ; (help @copyfiles-help) ; ) ; ) ; ) ) ) ;***** German Docs (complete 65) (if (<> 0 (BITAND choice 4)) ( (run (cat "copy " "Docs/Deutsch.info \"" (tackon destination "Docs") "\"")) (if (<> 0 (BITAND gchoice 1)) ( (copyfiles (prompt "Installing german AmigaGuide manual...") (source "Docs/Deutsch/MUI.guide") (dest (tackon destination "Docs/Deutsch")) (infos) (help @copyfiles-help) ) ) ) (if (<> 0 (BITAND gchoice 2)) ( (if (<> (exists "Docs/Deutsch/MUI.dvi") 0) ( (copyfiles (prompt "Installing german DVI manual...") (source "Docs/Deutsch/MUI.dvi") (dest (tackon destination "Docs/Deutsch")) (infos) (help @copyfiles-help) ) ) ( (message "Due to space limitations, the german DVI manual is not present on the disk distribution.") ) ) ) ) ; (if (<> 0 (BITAND gchoice 4)) ; ( ; (copyfiles ; (prompt "Installing german ASCII manual...") ; (source "Docs/Deutsch/MUI.doc") ; (dest (tackon destination "Docs/Deutsch")) ; (infos) ; (help @copyfiles-help) ; ) ; ) ; ) ) ) ;***** Catalogs (complete 70) (if (<> 0 (BITAND choice 8)) ( (copyfiles (prompt "Installing catalogs...") (source "Locale") (dest (tackon destination "Locale")) (all) (infos) (help @copyfiles-help) ) (run (cat "copy " "Locale.info \"" destination "\"")) ) ) ;***** Rexx Scripts (complete 75) (if (<> 0 (BITAND choice 16)) ( (copyfiles (prompt "Installing example ARexx scripts...") (source "Rexx") (dest (tackon destination "Rexx")) (infos) (all) (help @copyfiles-help) ) (run (cat "copy " "Rexx.info \"" destination "\"")) ) ) ;***** Demo Programs (complete 80) (if (<> 0 (BITAND choice 32)) ( (copyfiles (prompt "Installing demonstration programs...") (source "Demos") (dest (tackon destination "Demos")) (infos) (all) (help @copyfiles-help) ) (run (cat "copy " "Demos.info \"" destination "\"")) ) ) ;***** Developer Stuff (complete 85) (if (<> 0 (BITAND choice 64)) ( (if (<> (exists "Developer") 0) ( (copyfiles (prompt "Installing developer material...") (source "Developer") (dest (tackon destination "Developer")) (infos) (all) (help @copyfiles-help) ) (run (cat "copy " "Developer.info \"" destination "\"")) ) ( (message "The developer files are not present and cannot be installed. You have to get the 'muiXXdev.lha' archive and unpack it first.") ) ) ) ) ;***** Startup-Sequence (complete 95) (startup "MUI" (prompt "Some required commands will be added to your \"s:user-startup\" file.") (help @startup-help) (command "if exists \"" destination "\"\n") (command " assign MUI: \"" destination "\"\n") (command " if exists MUI:Libs\n") (command " assign add LIBS: MUI:Libs\n") (command " endif\n") (command " if exists MUI:Locale\n") (command " assign add LOCALE: MUI:Locale\n") (command " endif\n") (command " version >nil: exec.library 39\n") (command " if not warn\n") (command " if exists MUI:Docs\n") (command " if exists HELP:dummy ; do not remove\n") (command " endif ; this entry!\n") (command " assign add HELP: MUI:Docs\n") (command " endif\n") (command " endif\n") (command "endif") ) ;***** Finished (complete 100) (exit "Please reboot your computer before trying to start any MUI programs.")