home *** CD-ROM | disk | FTP | other *** search
- ;
- CPA.COM
-
- Size (recs) CRC Version Author/Latest Issue Disk
- 4k (32) 49B4 1.3 Bruce Morgen 7/91 Z3COM2
-
- 1- Syntax 2- Usage 3- Notes
-
-
- ComPare Ascii utility will analyze two text files, on a line by line basis,
- reporting any differences via a split screen with a window for each file.
- Files may be scrolled separately, allowing realignment after the first mis-
- match. If available, video highlighting shows differences between files.
- Under ZSDOS or Z3PLUS, file datestamps are also displayed.
-
- For purposes of this utility, lines are terminated by a <CR><LF> pair.
- Also, before comparison, all tab characters are expanded. Lines of length
- longer than a screen width will wrap, causing following of the lines in BOTH
- windows to scroll down. Version 1.0 by Malcom Kemp (1/87).
- :1
- Syntax CPA [dir:]ufn [dir:][ufn]
-
- ... where the file specification must be unambiguous, but otherwise any
- allowable Z-system specification. If a file is missing, or a line exceeding
- 1015 characters is found in a file, CPA exits to the operating system with the
- appropriate error message.
-
-
- Commands while CPA is active
-
- X, ^X - Scroll the current screen up
- E, ^E - Scroll the current screen down
- <sp>, S - Switch screens
- G - Go on comparing at the next pair of lines
- ^C - Abort to operating system
- :2
- Usage - 1/2
-
- The compare will proceed until a mismatch occurs or until the end of one or
- both files is reached, whichever comes first. At this time, the names and
- current lines, and file datestamps if available, are displayed. If a mismatch
- is found, the mismatched line will be shown as the last line in each display.
- The user can then manipulate the lines in each screen to achieve synchroniza-
- tion, and begin the compare again. The compare will continue from the line
- AFTER the displayed line forward.
-
- If your terminal supports video attributes, the display will highlight the
- text in each window beyond the point of mismatch. Under ZSDOS or Z3PLUS, file
- datestamps are displayed along with each filename. For both systems, the
- stamp displayed is normally the last modify stamp. If the last modify stamp
- is not found, the create stamp is instead displayed, and the date is followed
- by a lower-case 'c'. Since CP/M Plus defines the same field for either the
- Update or Last Access stamp depending on the disk label, stamps designated 'c'
- may actually be the last access stamp, depending on the system. The CP/M Plus
- 'SHOW d:[LABEL " command will display what stamps are active on a given disk.
- Usage - 2/2
-
- If no datestamps are available on the disk(s), just the filename(s) appear.
- If datestamping is active, but the file(s) do not have valid stamps (day is
- not in range 1..31), two dashes will appear instead of one between the
- filename and the line number.
-
- CPA buffers as much of both files as TPA permits. This allows a limited
- 'back up' facility, but if the files are larger than the available memory, you
- will not be able to back up to the beginning of one or both files; you must
- restart CPA to review these areas.
- :3
- CPA Notes - 1/2
-
- a. Vs 1.3 updates (7/5/91, Bruce Morgen):
- - Meticulous maintenance update to reduce tool size to 32 records (4K)
- from 34 records. No observable functional alterations.
- - Biggest single savings came from eliminating use of PRINT routine,
- used VPRINT (needed it regardless) calls instead.
- - The Z3 test (such as it is) is done earlier now (before the program
- banner is shown), so now VPRINT isn't called unless we know we've got
- a decent size stack to work with.
- - CPA now exits via DINIT, as we we should since we call TINIT.
-
- b. Vs 1.2 updates (2/20/89, Carson Wilson):
- - Adds Z3PLUS datestamp support.
- - Separates code from data segments.
- - Uses SFXIO routines and 4k I/O buffers for better performance.
- - Fixes bug at GETNXTLN which caused read past end of file.
- - Adds datestamp display to DISP_SCREEN.
- - For faster operation, will not refresh the whole screen if keyboard
- input is available (G, ^E, ^X commands).
- - Allows user interrupt during long compares.
- CPA Notes - 2/2
-
- - Uses defaults for missing parts of command line (e.g., if second file-
- name is missing, uses first filename for both).
- - Adds built-in help.
- - Adds ZCPR environment detection (aborts unless ZCPR present).
- - Adds comments to clarify code (hint: study the data structures at the
- end of CPA.Z80 before tackling the code).
- - Comments .NEW's and renames labels for Z80ASM.