; $VER: AudioEDUpdate V 2.87a (02.01.96)
;
; Installation script for the Commodore Installer (tm)
;
; Updates the program AudioED 2.87 by Frank Enderle from
; the original 2.87 distribution to version 2.87a.
;
; Fixes a big bug in the datatype routine.

; startup message

(set old_level @user-level)
(set sys_ver (/ (getversion "exec.library" (resident)) 65536))

(if (< sys_ver 37) (
  (abort "AudioED requires at least Kickstart 2.04 !")
  (exit (quiet))
))

(user 1)
(message "This script updates the program\n\nAudioED\nVersion 2.87\n\n"
         "which has to be present on your harddisk to version 2.87a. To "
         "get the complete program download the archive "
         "text/print/audioed287.lha from the Aminet!\n\n"
         "All parts contained in this archive are Copyright © 1996 by Frank Enderle")
(user old_level)

; ask user where AudioED is installed

(set drawer
  (askdir
    (prompt "Please select the directory where you have AudioED 2.87 installed (eg. SYS:AudioED)")
    (help @askdir-help)
    (default "SYS:")
  )
)

(set @default-dest drawer)

(complete 33)

(if (exists (tackon drawer "AudioED") (noreq)) (
  (copyfiles
    (source (tackon drawer "AudioED"))
    (dest drawer)
    (newname "AudioED.bak")
  )
  (copyfiles
    (source "AudioED")
    (dest drawer)
  )
))

(if (> (exists ("c:multiview")) 0) (set mvpath "c:") )
(if (> (exists ("sys:utilities/multiview")) 0) (set mvpath "sys:utilities") )

(complete 66)

(run (cat "run " mvpath "/multiview Preview") )
(complete 100)
(exit)
