SysIII/usr/src/man/man1/diffmk.1
.if t .ds ' \h@.05m@\s+4\v@.333m@\'\v@-.3m@\s-4\h@.05m@
.if n .ds ' '
.if t .ds ` \h@.05m@\s+4\v@.333m@\`\v@-.3m@\s-4\h@.05m@
.if n .ds ` `
.TH DIFFMK 1
.SH NAME
diffmk \- mark differences between files
.SH SYNOPSIS
.B diffmk
name1 name2 name3
.SH DESCRIPTION
.I Diffmk\^
compares two versions of a file and creates a
third file that includes ``change mark'' commands for
.IR nroff (1)
or
.IR troff (1).
.I Name1\^
and
.I name2\^
are the old and new versions of the file.
.I Diffmk\^
generates
.IR name3 ,
which contains the lines of
.I name2\^
plus inserted formatter ``change mark''
.RB ( .mc )
requests.
When
.I name3\^
is formatted,
changed or inserted text is shown by \(bv at the right
margin of each line.
The position of deleted text is shown by a single
.BR \(** .
.PP
If anyone is so inclined,
he can use
.I diffmk\^
to produce listings of C (or other)
programs with changes marked.
A typical command line for such use is:
.PP
.RS
diffmk \|old.c \|new.c \|tmp; \|nroff \|macs \|tmp \|\(bv \|pr
.RE
.PP
where the file
.B macs
contains:
.RS
.PP
.nf
\&.pl \|1
\&.ll \|77
\&.nf
\&.eo
\&.nc \|\*`
.fi
.RE
.PP
The
.B \&.ll
request might specify a different line length, depending on the
nature of the program being printed.
The
.B \&.eo
and
.B \&.nc
requests are probably needed only for C programs.
.PP
If the characters \(bv and
.B \(**
are inappropriate,
a copy of
.I diffmk\^
can be edited to change them
.RI ( diffmk\^
is a shell procedure).
.SH SEE ALSO
diff(1), nroff(1).
.SH BUGS
Aesthetic considerations may dictate manual adjustment of some output.
File differences involving only formatting requests may produce undesirable
output,
i.e., replacing
.B \&.sp
by
.B \&.sp 2
will
produce a ``change mark'' on the preceding or following line of output.