home *** CD-ROM | disk | FTP | other *** search
/ World of A1200 / World_Of_A1200.iso / programs / commodity / gblanker / install < prev    next >
Text File  |  1995-02-27  |  5KB  |  206 lines

  1. ;
  2. ; Garshneblanker Installation Script $VER:Garshneblanker 37.4 (31.10.93)
  3. ;
  4.  
  5. (set @default-dest "SYS:WBStartup")
  6. (set @pref-dest "SYS:Prefs")
  7. (set @envarc-dest "ENVARC:")
  8. (set @env-dest "ENV:")
  9. (set installReqTools 1)
  10.  
  11. (set @default-dest
  12.  (askdir
  13.   (prompt "Where would you like Garshneblanker installed?")
  14.   (help "The WBStartup directory on your boot disk is likely the best place "
  15.    "to put blanker. This will insure that Garshneblanker is run "
  16.    "automatically when you boot your computer."
  17.    )
  18.   (default @default-dest)
  19.   )
  20.  )
  21.  
  22. (working "Checking for previously installed version of Garshneblanker.")
  23.  
  24. (set newBlanker (tackon (pathonly @icon) "Garshneblanker"))
  25. (if (exists (tackon @default-dest "Blanker"))
  26.  (set oldBlanker (tackon @default-dest "Blanker"))
  27.  (set oldBlanker (tackon @default-dest "Garshneblanker"))
  28.  )
  29.  
  30. (if (<= (getversion newBlanker) (getversion oldBlanker))
  31.  (if
  32.   (NOT
  33.    (askbool
  34.     (prompt "An equal or newer version of Garshneblanker already installed. "
  35.      "Install anyway?")
  36.     (default 0)
  37.     (help "An equal or newer version of Garshneblanker is already installed. "
  38.      "If you would like to install Garshneblanker anyhow, click 'Yes'. "
  39.      "If you don't want to install Garshneblanker, click 'No'.")
  40.     )
  41.    )
  42.   (abort "Newer version of Garshneblanker already installed. Aborting.")
  43.   )
  44.  )
  45.  
  46. (delete oldBlanker)
  47. (delete (tackon oldBlanker ".info"))
  48.  
  49. (copyfiles
  50.  (prompt ("Copying Garshneblanker to %s" @default-dest))
  51.  (help @copyfiles-help)
  52.  (source (pathonly @icon))
  53.  (dest @default-dest)
  54.  (choices "Garshneblanker")
  55.  (infos)
  56.  )
  57.  
  58. (set @module-dest @default-dest)
  59.  
  60. (set @module-dest
  61.  (askdir
  62.   (prompt "Where would you like the Garshneblanker modules installed?")
  63.   (help "You can put the blankers anywhere and Garshneblanker will look for "
  64.    "them there.")
  65.   (default @module-dest)
  66.   )
  67.  )
  68.  
  69. (if
  70.  (askbool
  71.   (prompt "Would you like to install the 68030 optimized modules?")
  72.   (help "The 68030 modules can ONLY be run on machines with a 68030 processor "
  73.    "or higher.")
  74.   (default 0)
  75.   )
  76.  (set @blanker-choice "Blankers030")
  77.  (set @blanker-choice "Blankers")
  78.  )
  79.  
  80. (set blankersDir (tackon @module-dest @blanker-choice))
  81. (if (exists blankersDir)
  82.  (run "Delete" (tackon blankersDir "#?") "QUIET" "FORCE")
  83.  )
  84.  
  85. (copyfiles
  86.  (prompt ("Copying Garshneblanker modules to %s" @module-dest))
  87.  (help @copyfiles-help)
  88.  (source (pathonly @icon))
  89.  (dest @module-dest)
  90.  (choices @blanker-choice)
  91.  )
  92.  
  93. (if
  94.  (askbool
  95.   (prompt "Would you like Garshneblanker to open its window on startup?")
  96.   (help "This will set the CX_POPUP tooltype to YES or NO depending on your"
  97.    "response. This tooltype dictates whether or not Garshneblanker opens it's"
  98.    "window when it first runs.")
  99.   (default 1)
  100.   )
  101.  (set cxPopUp "YES")
  102.  (set cxPopUp "NO")
  103.  )
  104.  
  105. (tooltype
  106.  (dest (tackon @default-dest "Garshneblanker"))
  107.  (settooltype "CX_POPUP" cxPopUp)
  108.  )
  109.  
  110. (tooltype
  111.  (dest (tackon @default-dest "Garshneblanker"))
  112.  (settooltype "BLANKERDIR" (tackon @module-dest @blanker-choice))
  113.  )
  114.  
  115. (set cxPopKey
  116.  (askstring
  117.   (prompt "What key-combination shall Garshneblanker use to pop up it's "
  118.    "interface? (This key combination can be used after Garshneblanker is "
  119.    "running to bring it's window to front.")
  120.   (help "This key-combination should be a text string. Examples:\n"
  121.    "Alt Help\nShift F1\nCtrl a")
  122.   (default "Alt Help")
  123.   )
  124.  )
  125.  
  126. (tooltype
  127.  (dest (tackon @default-dest "Garshneblanker"))
  128.  (settooltype "CX_POPKEY" cxPopKey)
  129.  )
  130.  
  131. (makedir "SYS:Prefs/Presets/Garshneblanker" (infos))
  132.  
  133. (if (NOT (exists "ENVARC:sys/def_pref.info" (noreq)))
  134.  ((copyfiles
  135.    (source (tackon (pathonly @icon) "env-archive"))
  136.    (dest @envarc-dest)
  137.    (choices "sys")
  138.    )
  139.   (copyfiles
  140.    (source (tackon (pathonly @icon) "env-archive"))
  141.    (dest @env-dest)
  142.    (choices "sys")
  143.    )
  144.   )
  145.  )
  146.  
  147. (copyfiles
  148.  (source (tackon (pathonly @icon) "env-archive"))
  149.  (dest @envarc-dest)
  150.  (choices "Garshneblanker.prefs")
  151.  (infos)
  152.  )
  153.  
  154. (copyfiles
  155.  (source (tackon (pathonly @icon) "env-archive"))
  156.  (dest @env-dest)
  157.  (choices "Garshneblanker.prefs")
  158.  (infos)
  159.  )
  160.  
  161. (working "Checking for previously installed version of ReqTools.")
  162.  
  163. (set oldReqTools "LIBS:reqtools.library")
  164. (set newReqTools (tackon (pathonly @icon) "ReqTools/reqtools.library"))
  165.  
  166. (if (<= (getversion newReqTools) (getversion oldReqTools))
  167.  (if
  168.   (askbool
  169.    (prompt "An equal or newer version of ReqTools already installed. "
  170.     "Install anyway?"
  171.     )
  172.    (default 0)
  173.    (help "An equal or newer version of ReqTools is already installed. "
  174.     "If you would like to install ReqTools anyhow, click 'Yes'. "
  175.     "If you don't want to install ReqTools, click 'No'."
  176.     )
  177.    )
  178.   (set installReqTools 1)
  179.   (set installReqTools 0)
  180.   )
  181.  )
  182.  
  183. (if (= 1 installReqTools)
  184.  (copyfiles
  185.   (prompt "Copying ReqTools library to LIBS:")
  186.   (source (tackon (pathonly @icon) "ReqTools/reqtools.library"))
  187.   (dest "LIBS:")
  188.   )
  189.  (if (< @user-level 1)
  190.   ((set temp @user-level)
  191.    (user 2)
  192.    (message "Not installing reqtools.library because an equal or newer version is already installed.")
  193.    (user temp)
  194.    )
  195.   )
  196.  )
  197.  
  198. (if (= 1 installReqTools)
  199.  (copyfiles
  200.   (prompt "Copying ReqTools preferences editor to SYS:Prefs")
  201.   (source (tackon (tackon (pathonly @icon) "ReqTools") "ReqTools"))
  202.   (dest "SYS:Prefs")
  203.   (infos)
  204.   )
  205.  )
  206.