home *** CD-ROM | disk | FTP | other *** search
/ PC Online 1998 November / PCO_1198.ISO / filesbbs / os2 / hmakeos2.arj / HMAKEOS2.ZIP / HMinstal.cmd < prev    next >
Encoding:
Text File  |  1998-02-05  |  5.7 KB  |  155 lines

  1. /*  rexx-program generating a HyperMake folder and
  2.     program objects with *.HMP file association,
  3.     pointing to HMAKE.EXE and E.EXE
  4.     Author: Martin Vieregg, Germany, Jan 1997  */
  5.  
  6. Call RxFuncAdd 'SysLoadFuncs','RexxUtil','SysLoadFuncs'
  7. Call SysLoadFuncs
  8.  
  9. CurrentDir = directory()
  10.  
  11. say "German language (press Y or N) "
  12. pull YesNo
  13. if  ((YesNo = "Y") | (YesNo = "y") | (YesNo = "J") | (YesNo = "j") ) then 
  14.   German = TRUE
  15. else
  16.   German = FALSE
  17.  
  18. rc = SysOpenObject("<MVhmakeFolder>", ICON, TRUE)
  19.  
  20. if (rc = 1) then DO
  21.   if (German = TRUE) then DO
  22.     say "Der Programmordner HyperMake ist schon vorhanden.";
  23.     say "Sollen die HyperMake Objekte gelöscht werden ? (drücken Sie J oder N) "
  24.   END
  25.   else DO
  26.     say "The HyperMake program folder already exists.";
  27.     say "Do you want to delete all these WPS Objects ? (press Y or N) "
  28.   END
  29.   pull Contin
  30.   if  ((Contin = "N") | (Contin = "n")) then EXIT
  31.  
  32.   Call Destroy "<MVhmake_comp>"
  33.   Call Destroy "<MVhmake_edit>"
  34.   Call Destroy "<MVhmakeAssocFolder>"
  35.   Call Destroy "<MVhmakeDirShadow>"
  36.   Call Destroy "<MVhmakeButtonLib>"
  37.   Call Destroy "<MVhmake_DocuHelp>"
  38.   Call Destroy "<MVhmake_DocuHTML>"
  39.   Call Destroy "<MVhmakeFolder>"
  40.  
  41.   exit
  42. END
  43.  
  44.  
  45. if (German = TRUE) then DO
  46.  
  47.   say "Bevor Sie mit diesem Programm fortfahren, müssen Sie die HyperMake"
  48.   say "Verzeichnisse und Dateien selbst in das Verzeichnis Ihrer Wahl kopieren."
  49.   say "Weitermachen ? (drücken Sie J oder N) "
  50.   pull Contin
  51.   if  ((Contin = "N") | (Contin = "n")) then EXIT
  52.  
  53.   say "Es wird ein HyperMake Ordner auf der Arbeitsoberfläche erzeugt..."
  54.  
  55.   Call SysCreateObject "WPFolder", "HyperMake", "<WP_DESKTOP>",,
  56.     "OBJECTID=<MVhmakeFolder>;ICONFILE="CurrentDir"\HMP.ICO;"
  57.  
  58.   Call SysCreateObject "WPFolder", "HMP Zuordnungen", "<MVhmakeFolder>",,
  59.     "OBJECTID=<MVhmakeAssocFolder>;"
  60.       Call SysCreateObject "WPProgram", "kompiliere Projekt", "<MVhmakeAssocFolder>",,
  61.           "OBJECTID=<MVhmake_comp>;EXENAME="CurrentDir"\HMAKE.EXE;ICONFILE="CurrentDir"\HMP.ICO;ASSOCFILTER=*.HMP,,;"
  62.       Call SysCreateObject "WPProgram", "editiere Projektdatei", "<MVhmakeAssocFolder>",,
  63.         "OBJECTID=<MVhmake_edit>;EXENAME=E.EXE;ASSOCFILTER=*.HMP,,;"
  64.  
  65.   Call SysCreateObject "WPProgram", "Button Bibliothek", "<MVhmakeFolder>",,
  66.     "OBJECTID=<MVhmakeButtonLib>;EXENAME=NETSCAPE.EXE;PARAMETERS="CurrentDir"\Buttons\Content.htm;STARTUPDIR="CurrentDir"\Buttons;"
  67.  
  68.   Call SysCreateObject "WPProgram", "Doku als HTML", "<MVhmakeFolder>",,
  69.     "OBJECTID=<MVhmake_DocuHTML>;EXENAME=NETSCAPE.EXE;PARAMETERS="CurrentDir"\German\Doku\Index.html;STARTUPDIR="CurrentDir"\German\Doku;"
  70.  
  71.   Call SysCreateObject "WPProgram", "Doku als INF", "<MVhmakeFolder>",,
  72.     "OBJECTID=<MVhmake_DocuHelp>;EXENAME=VIEW.EXE;PARAMETERS="CurrentDir"\German\Doku.inf;"
  73.   
  74.   Call SysCreateObject "WPShadow", "ShadowOfHyperMake", "<MVhmakeFolder>",,
  75.     "OBJECTID=<MVhmakeDirShadow>;SHADOWID="CurrentDir";"
  76.  
  77.  
  78.   say "Es wurde erfolgreich ein HyperMake Ordner mit einigen Objekten erstellt."
  79.   say "Sie können den Ordner irgendwo in einen anderen Ordner Ihrer"
  80.   say "Arbeitsoberfläche verschieben."
  81.   say "Zum Deinstallieren dieser Objekte starten Sie dieses Programm erneut."
  82.   say "Die zwei Referenzen zur Dokumentation gehen noch ins Leere, solange"
  83.   say "die Dokumentation noch nicht erstellt worden ist."
  84.   say "Lesen Sie hierfür bitte GERMAN\MACHDOKU.HLP"
  85.  
  86. END
  87. ELSE DO
  88.  
  89.   say "Before running this installation program, you have to copy the HyperMake"
  90.   say "directories and files to the location of your choice by yourself."
  91.   say "Continue ? (press Y or N) "
  92.   pull Contin
  93.   if  ((Contin = "N") | (Contin = "n")) then EXIT
  94.  
  95.   say "creation of a HyperMake folder on the desktop..."
  96.  
  97.  
  98.   Call SysCreateObject "WPFolder", "HyperMake", "<WP_DESKTOP>",,
  99.     "OBJECTID=<MVhmakeFolder>;ICONFILE="CurrentDir"\HMP.ICO;"
  100.  
  101.   Call SysCreateObject "WPFolder", "HMP Associations", "<MVhmakeFolder>",,
  102.     "OBJECTID=<MVhmakeAssocFolder>;"
  103.       Call SysCreateObject "WPProgram", "compile project", "<MVhmakeAssocFolder>",,
  104.           "OBJECTID=<MVhmake_comp>;EXENAME="CurrentDir"\HMAKE.EXE;ICONFILE="CurrentDir"\HMP.ICO;ASSOCFILTER=*.HMP,,;"
  105.       Call SysCreateObject "WPProgram", "edit project file", "<MVhmakeAssocFolder>",,
  106.         "OBJECTID=<MVhmake_edit>;EXENAME=E.EXE;ASSOCFILTER=*.HMP,,;"
  107.  
  108.   Call SysCreateObject "WPProgram", "Button Library", "<MVhmakeFolder>",,
  109.     "OBJECTID=<MVhmakeButtonLib>;EXENAME=NETSCAPE.EXE;PARAMETERS="CurrentDir"\Buttons\Content.htm;STARTUPDIR="CurrentDir"\Buttons;"
  110.  
  111.   Call SysCreateObject "WPProgram", "Docu in HTML", "<MVhmakeFolder>",,
  112.     "OBJECTID=<MVhmake_DocuHTML>;EXENAME=NETSCAPE.EXE;PARAMETERS="CurrentDir"\English\Docu\Index.html;STARTUPDIR="CurrentDir"\English\Docu;"
  113.  
  114.   Call SysCreateObject "WPProgram", "Docu in INF", "<MVhmakeFolder>",,
  115.     "OBJECTID=<MVhmake_DocuHelp>;EXENAME=VIEW.EXE;PARAMETERS="CurrentDir"\English\Docu.inf;"
  116.   
  117.   Call SysCreateObject "WPShadow", "ShadowOfHyperMake", "<MVhmakeFolder>",,
  118.     "OBJECTID=<MVhmakeDirShadow>;SHADOWID="CurrentDir";"
  119.  
  120.  
  121.   say "Successful creation of a HyperMake folder on your desktop"
  122.   say "containing some objects."
  123.   say "You can drop the folder somewhere into a folder of your desktop."
  124.   say "To deinstal these objects run this program again."
  125.   say "The shortcuts to the documentation are not working yet because you"
  126.   say "need to create the docu first. Please read ENGLISH\MAKEDOCU.HLP" 
  127.  
  128. END
  129.  
  130. "copy kbdvio32.dll c:\os2\dll"
  131. "@pause"
  132.  
  133.  
  134. exit
  135.  
  136.  
  137. Destroy:
  138. if SysDestroyObject(ARG(1)) then DO
  139.   if (German = TRUE) then DO
  140.     say "löschen von "ARG(1)" OK"
  141.   END
  142.   else DO
  143.     say "deleting "ARG(1)" OK"
  144.   END
  145.  
  146. END
  147. else DO
  148.   if (German = TRUE) then DO
  149.     say "löschen von "ARG(1)" fehlgeschlagen"
  150.   END
  151.   else DO
  152.     say "deleting "ARG(1)" failed"
  153.   END
  154. END
  155. return