;;
;; an example how to use  patchtest  to find out whether
;; a patchmanager is available or not and
;; to copy one to the system, then.
;;
;; Note that the file "SaferPatches" is taken from util/misc/SaferPatches.lha
;; © Martin Adrian 1992
;;

(message "Hi ! I will now check whether you have a patch-manager or not !")

(if (= 5 (run "/patchtest LIB=/patchtest.library OFF=-30 QUIET"))
    (if (askbool (prompt "You don't have a patch-manager !\n"
                         "Shall I install SaferPatches for you ?")
                 (help   @askbool-help)
                 (default 1)
        )
        (
          (message   "You need to edit this script here !")

          (copyfiles (prompt    "Copying SaferPatches...")
                     (help      "AltF4 !!!")
                     (source    "SaferPatches")
                     (dest      "C:SaferPatches")
          )
          (startup "SAFERPATCHES"
                     (prompt    "I gonna put it to your s:user-startup !")
                     (help      "Gurk")
                     (command   "C:SaferPatches ;**safe patches**")
          )
        )
    )
    (message "All right ! There's a manager !")
)
