home *** CD-ROM | disk | FTP | other *** search
- ; Script to install Directory Opus version 5.0
- ;
- ; Directory Opus Install Version $VER: Install-Opus 5.0 6.4.95
- ; COPYRIGHT ©1995 GP SOFTWARE, AUSTRALIA
- ;
-
- (onerror
- (makeassign "Opus5_Install" (safe))
- )
-
-
- (complete 0)
-
- ;check user has Dos 2
- (set DOSTYPE (/ (getversion) 65536))
- (if
- (NOT (>= DOSTYPE 37))
- (abort "Directory Opus 5 requires AmigaDOS 2.04 or higher."
- " If you have an earlier version of AmigaDOS you must purchase an upgrade before using Opus 5.")
- )
-
-
- (set wbisgo 0)
-
- ; just in case the installation was restarted
-
- (makeassign "Opus5_Install" (safe))
-
- ; see if this is really an update
-
-
- (set is_update 0)
- (set DOPus_Dest (getassign "DOpus5" "a"))
-
-
- ; if update, be sure they want program in same place
-
- (if DOPus_Dest
- (if (askbool
- (prompt "Opus 5 has already been installed on this system.\n"
- "The current copy is located in the drawer named \"" DOPus_Dest"\"."
- "\n\nDo you want this version installed in that drawer?"
- )
- (help
- "The installer has determined that you may already have a "
- "copy of Opus 5 installed on your system. If this is wrong or "
- "you want the update installed elsewhere, select NO as an "
- "answer. Otherwise, select YES."
- )
- (default 1)
- )
-
- ; if user wants in same place
-
- (set is_update 1)
-
- ; if user wants in different place
-
- (set DOPus_Dest
- (tackon
- (askdir
- (prompt "Directory Opus 5 will be installed in its own directory on your hard disk.\n\nWhere should the Opus 5 directory be created?")
- (help @askdir-help)
- (default @default-dest)
- )
- "Opus5"
- )
- )
- )
-
-
- ; else if not an update, get a location for program
- ;
- (set DOPus_Dest
- (tackon
- (askdir
- (prompt "Directory Opus 5 will be installed in its own directory on your hard disk.\n\nWhere should the Opus 5 directory be created?")
- (help @askdir-help)
- (default @default-dest)
- )
- "Opus5"
- )
- )
- )
-
-
- ; now lock on to Install Disk volume
-
- ; (askdisk
- ; (prompt "\nPlease insert the master program disk labeled \"Opus5_Install\".")
- ; (help "The Opus 5 program and other options will be copied "
- ; "from the \"DOpus\" into your system.")
- ; (dest "DOpus")
- ; (newname "Opus5_Install")
- ; )
-
- ; make DOpus drawer & icon if not there
-
- (if (not is_update)
- (makedir DOPus_Dest (infos))
- )
-
- ; at this point we have a valid destination, so we tell installer where
- ; the application will end up so the exit page will be correct -- also,
- ; the installation log file (if any) will be copied to the destination
-
- (set @default-dest DOPus_Dest)
-
- (working "Reading the Install disk for Directory Opus files.")
-
- (copyfiles
- (source "Opus5_Install:lhex")
- (dest "ram:")
- )
-
-
-
- (working "DeArchiving Directory Opus and related files.")
-
- (textfile
- (dest "RAM:install_cmd")
- (append
- "ram:lhex >NIL: <NIL: -qfw ""\""DOpus_Dest"\"" " x Opus5_Install:DO5.lha \n"
- )
- )
-
- (execute "RAM:install_cmd")
- (run "delete ram:#?_cmd")
- (run "delete ram:lhex")
-
- (complete 80)
-
-
-
- ;Get the users startup choices
- (set mode (askchoice
- (prompt "Opus 5 can be started automatically when you boot your computer. What do you wish to do?")
- (help @askchoice-help )
- (choices "Start Opus 5 on boot"
- "Start Opus 5 Iconified"
- "Use Opus 5 as Workbench Replacement!"
- "Do not start Directory Opus on boot")
- (default 0)
- )
- )
-
-
- (complete 90)
-
-
-
-
-
- ; start on boot normal
- (if (= mode 0)
- (
- (copyfiles
- (source (tackon DOpus_dest "wbstartup/Opus5_Startup"))
- (dest "SYS:WBStartup")
- (infos)
-
- )
-
- (tooltype
- (dest "SYS:WBStartup/Opus5_Startup")
- (settooltype "CX_POPUP" "YES")
-
- )
- )
- )
-
-
- ; start on iconified normal
- (if (= mode 1)
- (
-
- (copyfiles
- (source (tackon DOpus_dest "wbstartup/Opus5_Startup"))
- (dest "SYS:WBStartup")
- (infos)
-
- )
-
- (tooltype
- (dest "SYS:WBStartup/Opus5_Startup")
- (settooltype "CX_POPUP" "NO")
-
- )
- )
-
- )
-
-
-
- ; use as wb replacement
-
- (if (= mode 2)
- (
- (set wbisgo 1)
-
- (if (= (exists "c:loadwb") 1)
- (rename "c:LoadWB" "c:LoadWB_old")
- )
-
- (copyfiles
- (source (tackon DOpus_dest "c/LoadDB"))
- (dest "c:")
- )
- (rename "c:LoadDB" "c:LoadWB")
- )
- )
-
-
- ; start on boot iconified
-
-
- (complete 95)
-
- ; modify S:User-Startup
-
-
- ; set the script for user startup
-
- (startup "DirectoryOpus 5"
- (prompt
- "The following instructions will added to your "
- "\"S:User-Startup\" so that your system will be properly "
- "configured to use Opus.\n\n"
- "ASSIGN DOpus5: \"" DOpus_Dest "\"\n"
- "PATH DOpus5:c Add \n"
- )
- (help "This will add commands to your S:user-startup file to "
- "allow the correct operation of Directory Opus")
- (command "ASSIGN DOpus5: \"" DOpus_Dest "\"\n")
- (command "PATH DOpus5:c Add \n")
- )
-
-
-
- ;make sure assignment is set up so that Opus 5 can run
-
- (makeassign "DOpus5" DOPus_Dest)
-
- (textfile
- (dest "RAM:serialise_cmd")
- (append
- "dopus5:DirectoryOpus \n"
- )
- )
-
- (execute "RAM:serialise_cmd"
- (prompt "Serialise Directory Opus 5 \n"
- "---------------------------\n"
- "To protect your valuable investment in Opus 5 "
- "and complete the installation procedure, you "
- " SERIALISE your copy of Opus 5 with your details and "
- " the registration number from your installation disk.\n\n"
- "By the way, now is also a good time to complete"
- " the registration card and return it to your local"
- " distributor. Technical support and warranty will"
- " only be honoured if a valid registration card has"
- " been received."
- )
- (help
- "Directory Opus 5 must be serialised before it will run. Please select continue and enter the registration and serialisation details."
- )
- (confirm)
- )
-
- (run "delete ram:#?_cmd")
-
-
-
- (if (= wbisgo 1)
- (
- (message "Since you have selected to run Directory Opus"
- " as a Workbench Replacement, please remove"
- " all disks from floppy drives and REBOOT your computer.\n\n"
- "*************************\n"
- "****** WARNING **********\n"
- "*************************\n"
- " You MUST have serialised your copy of Opus 5 BEFORE you re-boot!"
- )
- )
- )
-
-
-
- ; reinitialize assigns
-
- (if (not @pretend)
- (makeassign "DOpus5" DOPus_Dest)
-
- )
-
-
-
- (complete 100)
-
- ; cleanup
- (makeassign "Opus5_Install" (safe))
-
-
- (exit text)
-
-