home *** CD-ROM | disk | FTP | other *** search
/ Aminet 10 / aminetcdnumber101996.iso / Aminet / misc / edu / VerbeP13.lha / Install_Patch next >
Text File  |  1995-12-14  |  3KB  |  131 lines

  1. ; Installer script for Ensemble Verbes patch
  2. ; $VER: Install_Patch 1.0 (28.3.95)
  3.  
  4. (procedure DOLOCALE
  5. (
  6.     (set n 0)
  7.     (while
  8.         (set language
  9.             (select n ;"dansk"
  10.                   ;"deutsch"
  11.                   "english"
  12.                   "español"
  13.                   "français"
  14.                   ;"italiano"
  15.                   ;"nederlands"
  16.                   "norsk"
  17.                   ;"português"
  18.                   ;"svenska"
  19.                   ""
  20.             )
  21.         )
  22.         (
  23.             (set catpath
  24.                 (tackon "Catalogs" language)
  25.             )
  26.             (set srcpath catpath)
  27.             (if (in lang n)
  28.                 (
  29.                     (if (<> 0 n) ; skip "english"
  30.                         (
  31.                             (makedir
  32.                                 (tackon newdest "Catalogs")
  33.                                 (safe)
  34.                             )
  35.                             (makedir
  36.                                 (tackon newdest catpath)
  37.                                 (safe)
  38.                             )
  39.                             (if (= 2 n) ; handle 2 cases for français
  40.                                 (
  41.                                     (set langopt
  42.                                         (askbool
  43.                                             (prompt "Choose the desired version of the français catalog file")
  44.                                             (choices "French with English" "French only")
  45.                                             (help "You may choose either:\n"
  46.                                                   "  French with English menus and error messages, or\n"
  47.                                                   "  Entirely French"
  48.                                             )
  49.                                         )
  50.                                     )
  51.                                     (if (= 1 langopt) ; French with English
  52.                                         (set srcpath
  53.                                             (tackon "Catalogs" "français2")
  54.                                         )
  55.                                     )
  56.                                 )
  57.                             )
  58.                             (copyfiles
  59.                                 (source
  60.                                     (tackon @execute-dir srcpath)
  61.                                 )
  62.                                 (dest
  63.                                     (tackon newdest catpath)
  64.                                 )
  65.                                 (all)
  66.                             )
  67.                         )
  68.                     )
  69.                 )
  70.             )
  71.             (set n (+ n 1))
  72.         )
  73.     )
  74. ))
  75.  
  76. (set osver
  77.     (/
  78.         (getversion "exec.library"
  79.             (resident)
  80.         )
  81.         65536
  82.     )
  83. )
  84. (set ks3
  85.     (> osver 38)
  86. )
  87.  
  88. (set newdest
  89.     (askdir
  90.         (prompt "Select the directory where \"Ensemble Verbes\" was installed")
  91.         (default @default-dest)
  92.         (help "You must tell the installer where \"Ensemble Verbes\" is located.")
  93.         (newpath)
  94.     )
  95. )
  96.  
  97. (set oldfile (tackon newdest "Verbes"))
  98.  
  99. (if
  100.     (exists oldfile)
  101.     (
  102.         (working "Patching Ensemble Verbes to V1.3")
  103.         ; Create new file in T:
  104.         (run (cat "spatch -oT:Verbes -pVerbes.pch " oldfile))
  105.         ; Copy new file over old file
  106.         (copyfiles (source "T:Verbes") (dest oldfile))
  107.         ; Remove temporary file
  108.         (delete "t:Verbes")
  109.         (if ks3
  110.             (copyfiles
  111.                 (source "Verbes39.guide")
  112.                 (dest newdest)
  113.                 (newname "Verbes.guide")
  114.             )
  115.             (copyfiles
  116.                 (source "Verbes.guide")
  117.                 (dest newdest)
  118.             )
  119.         )
  120.         (set lang
  121.             (askoptions
  122.                 (prompt "Which languages should be installed?")
  123.                 (choices "English" "Español" "Français" "Norsk")
  124.                 (default 15)
  125.                 (help "\"Ensemble Verbes\" may be run in any of the languages listed.")
  126.             )
  127.         )
  128.         (DOLOCALE)
  129.     )
  130. )
  131.