Dec 282017
A nice little source code management system. | |||
---|---|---|---|
File Name | File Size | Zip Size | Zip Type |
DIFF.EXE | 28800 | 14878 | deflated |
DIFUPD.DOC | 12416 | 3735 | deflated |
UPDT.EXE | 30336 | 15438 | deflated |
Download File DIFUP.ZIP Here
Contents of the DIFUPD.DOC file
1
Version 85.10a
SOURCE CODE MAINTENANCE UTILITIES 12 Oct 1985
Copyright Charlie Jan 1986 by Charlie Y. Jan
With the DIFF and UPDT utilities, you will have a source file maintenance
and update system that can help you keep track of source code changes
and save disk space.
DIFF UTILITY PROGRAM
--------------------
This utility creates an update file (Diff script file) that
describes the differences between two source files. You do
not need sequence numbers. The speed of this utility
inversely proportional to the size of the files being compared.
UPDT UTILITY PROGRAM
--------------------
This utility will take a source file and apply a single update file or
a list of update files against it and create a new file which
contains the origional source file with all of the updates/changes
made to it. An update log file is also created. It contains a
list of the changes that were made to the origional source file.
An update file can be created by comparing two source files
with the DIFF utility. The changed file can then be deleted,thus
saving disk space, and recreated at any time by applying the
updates to the origional file.
+-------------------------------------------------------------------------+
+ *********************************************************************** +
+ * * +
+ * Permission is granted for personal and noncommercial purposes only. * +
+ * * +
+ *********************************************************************** +
+-------------------------------------------------------------------------+
*--------------------------------------------------------------------*
* For any commercial purpose or usage, please contact the author. *
*--------------------------------------------------------------------*
2
DIFF utility
Syntax:
DIFF [Original file] [,Modified file] [,Diff script file]
WHERE:
The Original file is:
The Source file (program) that will be the base file.
This base file will be the only permanent program
source you need to keep. The update files serve to
The Modified file is :
A changed version of the origional source file. DIFF
will compare the [Modified file] against the [Original file]
and find differences between the two files.
The Diff script file is :
The file created by DIFF utility which describes the differneces
between the [Original file] and the [Modified file].
It can be used as the update file when using the UPDT utility.
The [Diff script file] will have following three kinds of control
records and they all begin with "./" at column 1.
1 2
column 123456789012345678901234567890
./ DEL nn:mm
./ INS nnc=cc
./ REP nn:mmc=cc
"./ DEL" will delete line(s) from line #nn to line #mm
"./ INS" will insert cc line(s) after line #nn (before line #(nn+1))
"./ REP" will replace line #nn thru line #mm with cc line(s) of records.
Any other "./" control records will be treated as comment.
3
DIFF utility Examples:
---------------------
1) DIFF TEST.SRC,TEST.NEW,TEST.UPD
Original file is TEST.SRC
Modified file is TEST.NEW
Diff script file is TEST.UPD
Compare TEST.NEW to TEST.SRC and find the difference, then write
the difference to the TEST.UPD using the control records described
above.
2) DIFF TEST.SRC,*.NEW,*.UPD
UPDT will substitute '*' with 'TEST'. Therefore, this DIFF utility
request and the previous request are the same.
3) DIFF XXXX,YYYY
Original file is XXXX
Modified file is YYYY
Diff script file will be prompted.
Compare YYYY against XXXX and write the differences to a file. The
name of the file will be will be prompted for.
4) DIFF SRCE,TRGT,NUL
Original file is SRCE
Modified file is TRGT
Diff script file will be NUL (which meant nothing will be created).
Compare SRCE against TRGT and don't write the difference out.
5) DIFF
All file names will be prompted for.
4
UPDT utility
------------
Syntax:
UPDT [Source file] [,Control file] [,Target file] [,Log file]
WHERE
The Source file is:
The original source file (program) to be updated via the contents
of your update files.
The control file:
Contains the updates to made to the source file.
There are two types of control file:
1) The update file that was created by DIFF utility (Diff script file).
2) Special master control file that will have a list of update files to
be applied by the UPDT utility. The file extension must be ".CTL"
Each line (record) in the ".CTL" file begins at column 1 should be
the update file name to be applied.Comments can follow the file
name but there must be at least one blank separating the file
name and the comment. When column 1 is a blank character or a
semicolon ';', the line (record) will be a comment line.
ex) TEST.CTL has three records and 3 update file names
<1>TEST.U01 Change #1
<2>TEST.U02 Change #2
<3>TEST.U03 Change #3
TEST.U01 TEST.U02 and TEST.U03 are update files' file names
Change #1, Change #2, Change #3 are comments.
ex) ABC.CTL has three records and 2 update file names
<1>; ABC Version 1.20 producfied at Jan 3 1985
<2>ABC.U01 Add ... feature
<3>ABC.U02 Fix ... bug
The target file is :
The file to be created after all the updates are applied. This
is the source file plus the updates you indicated.
The Log file is :
The file output by UPDT utility describing how the updates were
applied. It lists the deleted source records and inserted update
records.
By entering 'NUL' you tell the UPDT utility that NO log file should
be created.
5
UPDT utility Examples:
1) UPDT TEST.SRC,TEST.UPD,TEST.OUT,TEST.LOG
Source file is TEST.SRC
Control file is TEST.UPD
Target file is TEST.OUT
Update Log file is TEST.LOG
Apply TEST.UPD to TEST.SRC and put the result into TEST.OUT and generate
the log file called TEST.LOG
2) UPDT TEST.SRC,*.UPD,*.OUT,*.LOG
UPDT will substitute '*' with 'TEST'. Therefore, this UPDT utility
request and the previous request are the same.
3) UPDT PGM.SRC,PGM.CTL,PGM.PAS,NUL
Source file is PGM.SRC
Control file is PGM.CTL ... has list of update file names
Target file is PGM.PAS
Update Log file is NUL ... no log requested
Suppose PGM.CTL contains these filenames PGM.U01, PGM.U02, PGM.U03,
and pgm.u04. The updates in these four files will be applied to PGM.SRC
to create PGM.PAS. There will be no Log file because NUL is used.
4) UPDT ABC,XYZ
Source file is ABC
Control file is XYZ
Target file and Update log file will be prompted.
5) UPDT
All file names will be prompted for.
6
Sample BAT files to maintain PAS program system
>IF NOT EXIST %1.PPPUPDT %1.SRC ,%1.CTL ,%1.PPP ,NUL
>UPDT %1.PPP ,%1.UPD ,%1.PAS ,NUL
>PE %1.PAS
>COPY %1.UPD %1.UPT
>DIFF %1.PPP,%1.PAS,%1.UPD
>IF NOT EXIST %1.UPD GOTO END
>PAS1 %1,,NUL,NUL
>IF EXIST PASIBF.SYM PAS2
>IF EXIST PASIBF.OID PAS3
>IF EXIST %1.OBJ LINK %1,,NUL,PASLIB+PASCAL
>:END
Sample BAT files to maintain ASM program system
>IF NOT EXIST %1.AAAUPDT %1.SRC ,%1.CTL ,%1.AAA ,NUL
>UPDT %1.AAA ,%1.UPD ,%1.ASM ,NUL
>PE %1.ASM
>COPY %1.UPD %1.UPT
>DIFF %1.AAA,%1.ASM,%1.UPD
>IF NOT EXIST %1.UPD GOTO END
>MASM %1,,NUL,NUL
>IF EXIST %1.OBJ LINK %1,,NUL,ASMLIB
>:END
Sample BAT files to maintain C program system
>IF NOT EXIST %1.CCCUPDT %1.SRC ,%1.CTL ,%1.CCC ,NUL
>UPDT %1.CCC ,%1.UPD ,%1.C ,NUL
>PE %1.C
>COPY %1.UPD %1.UPT
>DIFF %1.CCC,%1.C,%1.UPD
>IF NOT EXIST %1.UPD GOTO END
>CCC1 %1,,NUL,NUL
>IF EXIST %1.OB1 CCC2
>IF EXIST %1.OB2 CCC3
>IF EXIST %1.OBJ LINK %1,,NUL,CLIB1+CLIB2
>:END
7
Special note:
(1) When the utility prompts for afile name and you want to quit, just enter
'QUIT', you don't have to hit ^C (Ctrl-Break) to stop.
(2) When doing the following
>DIFF SRC,CHG,UPD
>UPDT SRC,UPD,OUT,NUL
Will make CHG and OUT files the same, except OUT file might not
have the CHR(26) which is the end-of-file mark character.
(To add end-of-file mark character, use the COPY command to combine
with a null file at the end, like COPY OUT+NUL,OUT1)
(3) The PC system must have at least 128K memory, and 192K or more is
recommended. v85.7e
The recommended memory size changed to 256K or more when using the
UPDT utility with CTL file. v85.10a
(4) The current DIFF.EXE and UPDT.EXE are linked to run under DOS 2.0
or higher. So the path name is allowed.
It can be re-linked to run under DOS 1.1 with proper PASCAL DOS1.1
libraries. (Must be IBM PC Pascal 2.0 or MicroSoft Pascal 3.20)
Of course, no path name is allowed. (If object files are supplied)
(5) The limitation to the DIFF and UPDT facility is that they can only
handle at most 2048 lines of ASCII text file (2000 lines or less
is recommended). Maximum length for each line is 255 characters.
(6) Except the first parameter, you can use '*' or '?' in the 2nd, 3rd
or the 4th parameters. The substitution rules used should be the
same rules used by the DOS COPY command. V85.10a
8
*-------------------------------------------------------------------*
* *
* The DIFF and UPDT utilities have been thoroughly tested, *
*please report any bugs to the author. The author will not *
*be liable for any direct, indirect, consequential or *
*incidental damages arising out of the use, the result of *
*use, or inability to use above two utilities (DIFF and UPDT). *
*The author could either correct the problem or elect to *
*return the donation if it has been made. *
* *
*-------------------------------------------------------------------*
+------------------------------------------------------------------+
+ +
+ If you like the programs, please send $10 donation to +
+ +
+ Charlie Y. Jan +
+ +
+ 43-10 65 Street +
+ Woodside, NY. 11377 USA. +
+ +
+------------------------------------------------------------------+
Please send additional $50, I will be very happy to supply
the source programs (in IBM PC Pascal) of the above two utilities
(DIFF and UPDT). Please make sure the name and address are
given correctly. There is a one-year free-update source
maintenance included.
December 28, 2017
Add comments