home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 037.lha / DU / Du21wb.doc < prev    next >
Text File  |  1987-05-16  |  13KB  |  325 lines

  1. TDI Modula-2 Du v2.1wb - By Greg Browne - compiled for 250 files CLI or WB.
  2.  
  3.  A combination of my DirUtil (smoothed down in size and cleaned up) with an
  4.  expansion on (the idea of) the Simple Development Program demo provided
  5.  with TDI's Modula-2 system. It allows you to edit, compile and link your
  6.  programs without all the repetitive typing and works as a full DirUtil.
  7.  
  8.  This version IS my last (famous 'last' words - don't make me eat them
  9.  later, Lord).  It does all I want it to do, and I want to move on to other
  10.  things. If someone else fancies it up, bravo. Besides, I finally got the
  11.  Workbench startup to work.  No EVERYTHING seems to function properly
  12.  either from CLI or WB.
  13.  
  14. DISCLAIMER:  I take no responsibility for damage or lost files if someone
  15.   is foolish enough to use this on valuable files untested. I am NOT a
  16.   professional programmer and am prone to mistakes like anyone else. I use
  17.   it with no problem, but you may do something differently.
  18.  
  19. NOTICE:  This program is placed in the public domain.  Give it away for the
  20.   asking, but don't try to sell it or else.?.?.?
  21.  
  22. ALERTS:  Don't worry if the compiler (2.20a) returns "Modula failed
  23.   returncode 526" or some other such nonsense.  If you check, it worked.
  24.   The TDI Simple Development Program does the same thing. That's a COMPILER
  25.   QUIRK. Also, if you don't have your .sym/.lnk files in m2: or the current
  26.   directory, it will fail rather than asking for names, since it is
  27.   NONinteractive.
  28.  
  29. HELP ???
  30. I use this with 2.20a.  I'm sure it will work with 3.00 (if you have enough
  31. memory). However, it WON'T compile AND RUN RIGHT on 3.00 - I tried it, and
  32. unless I am missing something about Gadgets, they don't like to be static.
  33. At least, I can't find a way to get the structure to recognize the
  34. IOStringInfo since I am not declaring them dynamically with the new TAG
  35. field.  My Modula book says a CASE variant in a record is undefined if the
  36. tag is undefined, and how else do you define CASE : INTEGER OF ??? ***
  37. ANYWAY, change a few structures to pointers as called for in 3.00, and it
  38. compiles fine, but none of the string gadgets work right. Maybe it's in the
  39. Strings modules.
  40.  
  41. =======================
  42.  
  43. PROGRAM SPECIFIC QUIRKS
  44.  
  45. (*---------*)
  46. If you have used DirUtils, operating this should be familiar.
  47. If not, make yourself a junk disk and try it out.  It's easy to learn.
  48. (*---------*)
  49.  
  50. Everything is "relative verify-Gadget Up".  That means press AND RELEASE
  51. the left mouse button over a gadget (or name) for it to register. You can
  52. save some grief by moving the pointer off a gadget without releasing the
  53. button, and then releasing it in some blank area.
  54.  
  55. Multi-file actions (see detail below) may be interrupted by pressing the
  56. mouse button on something.  It will stop after the current pass is
  57. complete.
  58.  
  59. When doing multi-file execution stuff (ARC,DO,EDIT,LINK,MODULA) the program
  60. is smart enough to just execute them (NOT RUN - to prevent multiple execute
  61. disk grinding) unless it is the last (or only) file worked on. Then it will
  62. RUN >NIL: the command to free up the DirUtil for other things.
  63.  
  64. Directory reads may be interrupted by clicking the slider while in progress.
  65. If your directory exceeds 100 (currently) files, you will be notified and
  66. the first 100 will be used.
  67.  
  68. Free memory := AvailMem(MemReqSet{MemChip}) + AvailMem(MemReqSet{MemFast});
  69. and is shown in the title bar.
  70.  
  71. **NEW**
  72. To accomodate WB startup (where the cli commands still think they are in
  73. DF0:, I added full path expansion to all filenames used in commands.
  74.  
  75. I included my startup-sequence (MyStart.seq needs to be renamed). to show
  76. how I use it. It will work with 2.20a and 512k memory, but not 3.00 with
  77. only 512k no matter where you put the t: directory.
  78.  
  79. ===============
  80.  
  81. OPERATION NOTES
  82.  
  83. The screen has 5 major divisions.
  84.  
  85. 1) The 'window' is the file display area. It is where files are shown for
  86.    selected directories. (It is a gadget)
  87.  
  88. 2) Above the window are device selection gadgets and the "SWAP". These are
  89.    "one-click-select" gadgets (The "SWAP" button is described below)
  90.  
  91. 3) Right of the window is a slider for scrolling lists of filenames too long
  92.    to show in a (8 name) window. Above and below the slider are one line at
  93.    a time scrollers.
  94.  
  95. 4) Right of the slider are the 'BUTTONS'.  They are click select functions.
  96.    Their uses are described below in more detail.
  97.  
  98. 5) Below the 'BUTTONS' are string display areas  R,S,D, and M. These are
  99.    for typed input and messages to you. Also see the section below on HIDDEN
  100.    Gadgets.
  101.  
  102. DEVICE GADGETS: -> df0: df1: df2: dh0: dh1: ram: vd0:
  103.  
  104.   Click the left mouse button on any of these to select a device. It will be
  105.   read and the files displayed in the filewindow.
  106.  
  107. FILEWINDOW GADGET:
  108.  
  109. Click over an unselected filename (white on black) and it will be selected
  110. for inclusion in the multiple-file operations described below.
  111.  
  112. Click on a selected filename (black on white) to unselect it.
  113.  
  114. Click on a directory name (orange on black) to select it.  A prompt will
  115. appear in the (M) gadget giving you the option of switching into that
  116. directory with a second click on top of it. (Clicking anywhere else cancels
  117. this option). Click on a selected directory (after cancelling entry) to
  118. unselect it.  A click to cancel is not acted on except as a cancel.
  119.  
  120. NOTE: Only one directory at a time may be selected. Any and/or all
  121.       filenames may be selected.
  122.  
  123. SLIDER GADGET:
  124.  
  125. The slider scrolls through long lists of filenames. If the slider is filled
  126. and will not move, then all files/directories are displayed.  The + above
  127. and - below the slider move one file at a time through the display.
  128.  
  129. STRING I/O GADGETS: ->  R  S  D  M  (You may type in all EXCEPT 'M')
  130.  
  131. 'R' is the Run gadget.  It holds arguments to pass to a program being run,
  132. like a command line tail. This gadget may also be used alone.
  133.  
  134. 'S' is the Source gadget.  It holds the name of the current active device
  135. or directory.  Click a device gadget and the name will replace what's here.
  136. CLICK-AND-ENTER into this gadget, and your entry will be taken as a new
  137. device or directory to access.  If access to the name fails, the program
  138. returns to the last active directory (or to ram: if that fails).
  139.  
  140. 'D' is the Destination gadget.  It holds the name of the path (or filename
  141. in some cases) to be used for certain GADGET functions as described below.
  142.  
  143. 'M' is the Message gadget.  It will display messages and other information
  144. from time to time.  CLICK-AND-ENTER IN THIS GADGET and you get a NoNo. It
  145. is for one-way (to you) communications.
  146.  
  147. HIDDEN GADGETS:
  148.  
  149. Unmarked gadgets are under the 'R' 'S' and 'D' beside the two-way gadgets.
  150. Clicking 'R' or 'D' blanks out the contents of the gadget, BUT clicking 'S'
  151. FORCES a directory read of the current 'S' contents.
  152.  
  153. BUTTON GADGETS:  (alphabetically - almost)
  154.  
  155.   ARC
  156.   ---
  157. This is the most complicated gadget to use.  It tries to string together
  158. 'arc' followed by a tail made up of 'Rgadget' + 'Dgadget' + filename.
  159. If any are empty, they will make spaces (ignored).
  160.  
  161.   to add to (create too) an arc file.
  162.     'R' => a
  163.     'D' => Result.arc   (the name of the destination file)
  164.     highlighted Joe.exe  Bill.doc
  165.  
  166. This will create Result.arc if new and add Joe.exe and Bill.doc to it
  167. BUT makes a full load for each highlighted file (sorry).
  168.  
  169.   faster to do this.
  170.    'R' => a Result.arc Joe.exe Bill.doc     (whole tail there)
  171.    'D' => [empty]
  172.    highlighted => [none]
  173.  
  174. Fool around with this one.  It is powerful, but complicated to explain.
  175.  
  176.   BYTES
  177.   -----
  178. This will total and display the number of bytes and files for all selected
  179. files in the window NOT including 512 bytes used per FileInfoBlock.
  180.  
  181.  
  182.   COPY              (Multiple files - consecutively)
  183.   ----
  184. This copies all (any) selected file(s) to the location given in the D
  185. gadget. THIS MUST NOT BE A FILENAME.  The path in D must be to a valid
  186. device or directory.  Since multiple copying may be done, copying to a
  187. specific filename is not supported.
  188.  
  189.   CPYDEL            (Multiple files - consecutively)
  190.   ------
  191. Same as COPY - except that if copy is successful, it deletes the original
  192. source file. If interrupted, the DELETE part is still done on the last
  193. copied file.
  194.  
  195.   DELETE            (Multiple files - consecutively)
  196.   ------
  197. FILE delete function. You'll get a CONFIRM message. Click DELETE again, and
  198. any (all) files currently highlighted will be deleted.  The 'M' gadget will
  199. show progress, and the deletion may be stopped by clicking the left mouse
  200. button on any gadget (or in the filewindow).
  201.  
  202.   DELDIR
  203.   ------
  204. Delete the currently highlighted directory.  To work, the directory must be
  205. selected, entry to it cancelled, and IT MUST BE EMPTY. This command has to
  206. be confirmed with another click on DELDIR.
  207.  
  208.   DO f-R  DO R-f   (Multiple files - consecutively)
  209.   ------  ------
  210. These two try to execute the result of sticking together the R gadget and
  211. the 'selected' filename(s)*.  The order of placement depends on which
  212. gadget you select. If no files are selected, 'DO R-f' will attempt the R
  213. gadget content by itself. This uses the DOS call EXECUTE (like typing in a
  214. command at the > prompt).
  215.  
  216. * KNOW YE - THIS OPTION *DOES* INCLUDE ANY HIGHLIGHTED DIRECTORY NAME
  217.   IN THE ATTEMPT TO STICK TOGETHER R+f OR f+R (My choice).
  218.  
  219.   EDIT              (Multiple files - consecutively)
  220.   ----
  221. This gadget invokes your editor with the selected filename(s) as command
  222. tails. If no filenames are selected, the editor will be run with no file.
  223. It expects an editor named 'dme' somewhere in the normal search path.  SEE
  224. PATCHING.
  225.  
  226.   GETDIR
  227.   ------
  228. There is NO GETDIR.  To get a directory, double click on top of the name.
  229. (See the filewindow description above.)
  230.  
  231.   HPRINT  HTYPE  PRINT  TYPE
  232.   ------  -----  -----  ----
  233. Display/print files in ascii or hex.  Output device for print is PRT: but
  234. can be patched (see end of this doc).
  235.  
  236.   INFO
  237.   ----
  238. This reports free space on S and D, (if valid) and the volume name(s).
  239.  
  240.   LINK              (Multiple files - consecutively)
  241.   ----
  242. This will invoke the linker WITH 'O' OPTION ONLY.  It will run consecutively
  243. on any (all) selected files IN ALPHABETIC ORDER (sorry no choice).
  244.  
  245.   MAKDIR
  246.   ------
  247. Make a new directory named in the D gadget (if valid and not already
  248. existing). If a complete dev:path is not given, it will be relative to the
  249. path in S.  If successful, the S directory will be re-read in case of
  250. change. A check is made to insure you are not trying to create a directory
  251. with an already existing name (or over a file).
  252.  
  253.   MODULA            (Multiple files - consecutively)
  254.   ------
  255. This will invoke the compiler (NO OPTIONS-3.00 people).  It will run
  256. consecutively on any (all) selected files IN ALPHABETIC ORDER (sorry no
  257. choice).
  258.  
  259.   MOVE              (Multiple files - consecutively)
  260.   ----
  261. Quick rename. The destination (path only-not name) of all selected file(s)
  262. should be in D. This attempts consecutive renames (between directories not
  263. devices). Since the files can only drop out of sight, they are eliminated
  264. from the filewindow without re-reading S.
  265.  
  266.   PARENT  ROOT
  267.   ------  ----
  268. These commands attempt to 'back-up' to the parent or root directory of the
  269. current 'S' gadget.  If they fail (horrors) they returns to the current
  270. directory (or ram: as a last resort).
  271.  
  272.   RENAME
  273.   ------
  274. This attempts to rename the FIRST selected file it finds (should be only
  275. for this) to the NAME given in the D gadget. Since it may be still in the
  276. same directory, it will re-read the directory afterwards. Wherever feasable,
  277. MOVE is faster.
  278.  
  279.   RETAG  TAG ALL  UNTAG
  280.   -----  -------  -----
  281. Mass selection (or unselection) of all FILENAMES in a window.  Some DU's
  282. call these ALL and CLEAR.  RETAG works after multiple file operations to
  283. reselect any files which were selected before (if they remain now).
  284.  
  285.   SHOW
  286.   ----
  287. Picture display.  Execs "show" (patchable - see end) with the highlighted
  288. files as command tails.
  289.  
  290.   S->D
  291.   ----
  292. This command copies the current Source to the Dest gadget.
  293.  
  294.   SWAP
  295.   ----
  296. These are for two-way swap of S D content. The new S will be sourced as
  297. though typed in.
  298.  
  299.                                 PATCHING
  300.                                 --------
  301. Changing the editor name:
  302.   Use NewZap to find the only occurrance of 'dme' (no quotes).  Change it
  303.   to a null terminated string of your choice. There is space for up to an
  304.   10 character name.
  305.  
  306. Changing PRINT output device:
  307.   Use NewZap to find only occurrance of PRT:.  It can be changed to any
  308.   valid file or device which can accept output and fit in 4 characters plus
  309.   the null terminator.
  310.  
  311. Changing SHOW program name:
  312.   Use NewZap to find only occurrance of 'show' (no quotes) with spaces
  313.   behind it. Change to null terminated string of your choice. The other
  314.   'SHOW' is the gadget text.
  315.  
  316. Changing MODULA or LINK:
  317.   The lower case occurrance of these two names is the actual one passed to
  318.   the CLI. HOWEVER link always tags a ' o' (blank + optimize) on the end of
  319.   everything. These can be changed, too (if the 'o' is no problem). The
  320.   UPPER CASE occurrance of these words is the gadget text.
  321.  
  322. OR - modify and recompile the source!
  323.  
  324.  
  325.