home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 6 File / 06-File.zip / flist58.zip / FSTART.CMD < prev    next >
OS/2 REXX Batch file  |  1990-05-19  |  3KB  |  86 lines

  1. @echo off
  2. SETLOCAL
  3. rem This is an example of setting the environment prior to running
  4. rem TJD Software's FLIST product. In most cases you will see that we
  5. rem use a secondary command processor to actually load and run the
  6. rem required programs. Although FLIST is capable of running programs
  7. rem directly it will not uninstall its BREAK handler. This means that
  8. rem FLIST always sees the Ctrl-Break if the program that you are
  9. rem executing doesn't install its own handler. If we use CMD.EXE to run
  10. rem the program it will pass the Ctrl-Break to its child processes.
  11. rem In addition to this, you will be able to start Presentation Manager
  12. rem programs by using the normal eXecute function. FLIST itself is not
  13. rem able to start PM programs (which abort when executed with a
  14. rem standard call to the operating system.)
  15. rem
  16. rem The ability to specify how FLIST reacts to different file extensions
  17. rem and how the programs will execute is one of the most powerful
  18. rem facilities in FLIST and should be exploited to the full.
  19. rem Note that you can force programs to run in VIO windows, run in the
  20. rem background, run as detached processes etc. very easily!
  21. rem
  22. rem Set the $FPRN$ variable so that it doesn't suspend FLIST if the
  23. rem spooler is not installed. Note that it's PRINT.COM not PRINT.EXE!!!
  24. rem Using this method will make sure that FLIST stays in the foreground
  25. rem and continues to run whilst the PRINT program runs
  26. rem
  27. SET $FPRN$=%COMSPEC% /c START /c "FLIST printing" PRINT.COM
  28. rem
  29. rem Note that by using the above technique you can start the editor, browser
  30. rem and other programs and still leave FLIST running in the foreground.
  31. rem
  32. rem Set BRIEF as the editor to be used by FLIST overriding the default
  33. rem E.EXE editor
  34. rem
  35. SET $FEDT$=B.EXE
  36. rem
  37. rem Set FLIST up to run the ZSHELL program when 'X' is requested for a
  38. rem file with a .ZIP extension.
  39. rem
  40. SET $FZIP=%COMSPEC% /c ZSHELL $FN
  41. rem
  42. rem The following example shows how we can perform a MAKE operation when
  43. rem we select 'X' for a .C file.
  44. rem
  45. SET $FC=%COMSPEC% /c MAKE $FN.MAK
  46. rem
  47. rem The following example shows how we can start a debugging session by
  48. rem 'executing' a .OBJ or .MAP file. Note that we ask FLIST to prompt us for
  49. rem parameters before it starts the debugger.
  50. rem
  51. SET $FOBJ=CVP $FN.EXE $P
  52. SET $FMAP=CVP $FN.EXE $P
  53. rem
  54. rem TJD Software runs a BBS in the UK using Gilmore Systems' MAGNUM BBS for
  55. rem OS/2 which has with it an interpreted language useful to SYSOPs. The
  56. rem following example shows how we can run such a program without terminating
  57. rem FLIST.
  58. rem
  59. SET $FMEX=%COMSPEC% /c MBBSEXEC $FN
  60. rem
  61. rem We will now implement an external function (copy within directory) using
  62. rem the supplied FLCOPY.CMD file. In this example we assign the function to
  63. rem the '1' key.
  64. rem
  65. SET $FUSR1$=%COMSPEC% /c FLCOPY $FN.$FE $P
  66. rem
  67. rem We will now set up the '7' key to save the environment after prompting
  68. rem for the file name to save it to. We use the supplied FSAVENV.CMD and
  69. rem GENV.EXE to perform the required processing.
  70. rem
  71. SET $FUSR7$=%COMSPEC% /c FSAVENV $P
  72. rem
  73. rem We will now tell FLIST that prompts for overwriting or deleting files
  74. rem should only occur for the FIRST file to be overwritten or deleted.
  75. rem
  76. SET $FCMPROMPT=FIRST
  77. SET $FDPROMPT=FIRST
  78. rem
  79. rem We'll now set the default sort order to DATE order
  80. SET $FSORT=D
  81. rem
  82. rem At last! We can start FLIST now.
  83. rem
  84. FLIST %1 %2 %3 %4 %5 %6 %7 %8 %9
  85. ENDLOCAL
  86.