AT&T UNIX™PC Unix System V Users Manual - tenox
AT&T UNIX™PC Unix System V Users Manual - tenox AT&T UNIX™PC Unix System V Users Manual - tenox
DIFF ( 1) DIFF ( 1) -e producing a script of a, c and d commands for the editor ed, which will recreate file2 from filel . In connection with -e, the following shell program may help maintain multiple versions of a file. Only an ancestral file ($1) and a chain of version-to-version ed scripts ($2,$3, ... ) made by diff need be on hand. A 'latest version' appears on the standard output. (shift; cat $*; echo '1,$p ') I ed - $1 Extra commands are added to the output when comparing directories with -e, so that the result is a sh ( 1) script for converting text files which are common to the two directories from their state in dir 1 to their state in dir2. -f produces a script similar to that of -e, not useful with ed, and in the opposite order. -c produces a diff with lines of context. The default is to present 3 lines of context and may be changed, e.g to 10, by -clO. With -c the output format is modified slightly: the output beginning with identification of the files involved and their creation dates and then each change is separated by a line with a dozen *'s. The lines removed from filel are marked with '- '; those added to file2 are marked '+'. Lines which are changed from one file to the other are marked in both files with 'f'. -h does a fast, half-hearted job. It works only when changed stretches are short and well separated, but does work on files of unlimited length. -Dstring causes diff to create a merged version of filel and file2 on the standard output, with C preprocessor controls included so that a compilation of the result without defining string is equivalent to compiling filel, while defining string will yield file2. -b causes trailing blanks (spaces and tabs) to be ignored, and other strings of blanks to compare equal. FILES /tmp / d????? /usr/lib/diffh for -h /bin/pr SEE ALSO cmp( 1), cc( 1), comm(1), ed( 1), diff3( 1) DIAGNOSTICS Exit status is 0 for no differences, 1 for some, 2 for trouble. BUGS Editing scripts produced under the -e or -f option are naive about creating lines consisting of a single '.' - 2-
DIFF ( 1 ) DIFF ( 1) When comparing directories with the -b option specified, dif! first compares the files ala cmp, and then decides to run the diff algorithm if they are not equal. This may cause a small amount of spurious output if the files then turn out to be identical because the only differences are insignificant blank string differences. - 3-
- Page 234 and 235: .'�
- Page 236 and 237: I I I I I I I I I I I I I I I I I I
- Page 238 and 239: COL(l) COL(l) BUGS Cannot back up m
- Page 240 and 241: COMB(l) COMB(l) FIT..ES s.COMB The
- Page 243 and 244: CP ( 1) CP ( 1) NAME cp, In, mv - c
- Page 245 and 246: CPIO ( 1 ) CPIO ( 1) NAME cpio - co
- Page 247: CPIO ( 1) CPIO ( 1) track of them a
- Page 250 and 251: CPP ( 1) CPP (1) Two special names
- Page 253 and 254: CRYPT { l ) ( Domestic Version Only
- Page 255 and 256: CSPLIT ( 1) CSPLIT (l) NAME csplit
- Page 257 and 258: CU ( lC ) CU ( lC ) NAME cu - call
- Page 259: CU(lC) CU ( lC ) BUGS Cu buffers in
- Page 262 and 263: CUT ( 1) CUT(l) DIAGNOSTICS line to
- Page 264 and 265: CW(l) CW (l) .OW Start of text to b
- Page 266 and 267: CW (l) CW (l) Documents that contai
- Page 268 and 269: .� .• \ __ }
- Page 270 and 271: DATE(l) DATE(l) DIAGNOSTICS No perm
- Page 272 and 273: DC( 1) DC (1) x =x The top two elem
- Page 275 and 276: DD ( 1 ) DD ( 1) NAME dd - convert
- Page 277 and 278: � I DELTA ( l ) DELTA (I) NAME de
- Page 279 and 280: DELTA ( 1) DELTA (!) WARNINGS Lines
- Page 281: DEROFF (l) DEROFF (l) NAME derofi -
- Page 287: DIFF3 ( 1 ) DIFF3 (1) NAME diff3 -
- Page 291: DIRCMP ( 1) DIRCMP ( 1) NAME dircmp
- Page 295 and 296: DUMP ( 1 ) DUMP(!) NAME dump - dump
- Page 297: ECHO (l) ECHO (l) NAME echo - echo
- Page 300 and 301: ED ( l ) ED {1) the RE. The REs all
- Page 302 and 303: ED (l) ED (1) . 6. FILES below. A R
- Page 304 and 305: ED ( 1 ) ED ( 1) command list is eq
- Page 306 and 307: ED (1) ED (l) replaced by the repla
- Page 308 and 309: ED (l) ED (1) FILES /tmp/e# tempora
- Page 311: ENV ( 1) ENV(l) NAME env - set envi
- Page 314 and 315: EQN(l) EQN( 1) [ • '+ � ] � l
- Page 316 and 317: � I )
- Page 318 and 319: EX (l) BUGS EX (l) The undo command
- Page 320 and 321: EXPR(l) EXPR ( l ) 3. 4. returns th
- Page 323 and 324: FC(l) ( AT&T UNIX PC only ) FC ( l
- Page 325: FILE ( 1 ) FIT..E ( 1 ) NAME file -
- Page 328 and 329: FIND ( 1 ) FIND ( 1 ) -print -cpio
- Page 330 and 331: GET(l) -b -ilist -xlist GET(l) furt
- Page 332 and 333: GET(l) GET(l) TABLE 1. Determinatio
DIFF ( 1) DIFF ( 1)<br />
-e producing a script of a, c and d commands for the editor<br />
ed, which will recreate file2 from filel . In connection<br />
with -e, the following shell program may help<br />
maintain multiple versions of a file. Only an ancestral<br />
file ($1) and a chain of version-to-version ed scripts<br />
($2,$3, ... ) made by diff need be on hand. A 'latest version'<br />
appears on the standard output.<br />
(shift; cat $*; echo '1,$p ') I ed - $1<br />
Extra commands are added to the output when comparing<br />
directories with -e, so that the result is a sh ( 1)<br />
script for converting text files which are common to the<br />
two directories from their state in dir 1 to their state in<br />
dir2.<br />
-f produces a script similar to that of -e, not useful with<br />
ed, and in the opposite order.<br />
-c produces a diff with lines of context. The default is to<br />
present 3 lines of context and may be changed, e.g to<br />
10, by -clO. With -c the output format is modified<br />
slightly: the output beginning with identification of the<br />
files involved and their creation dates and then each<br />
change is separated by a line with a dozen *'s. The<br />
lines removed from filel are marked with '- '; those<br />
added to file2 are marked '+'. Lines which are changed<br />
from one file to the other are marked in both files with<br />
'f'.<br />
-h does a fast, half-hearted job. It works only when<br />
changed stretches are short and well separated, but does<br />
work on files of unlimited length.<br />
-Dstring<br />
causes diff to create a merged version of filel and file2<br />
on the standard output, with C preprocessor controls<br />
included so that a compilation of the result without<br />
defining string is equivalent to compiling filel, while<br />
defining string will yield file2.<br />
-b causes trailing blanks (spaces and tabs) to be ignored,<br />
and other strings of blanks to compare equal.<br />
FILES<br />
/tmp / d?????<br />
/usr/lib/diffh for -h<br />
/bin/pr<br />
SEE ALSO<br />
cmp( 1), cc( 1), comm(1), ed( 1), diff3( 1)<br />
DIAGNOSTICS<br />
Exit status is 0 for no differences, 1 for some, 2 for trouble.<br />
BUGS<br />
Editing scripts produced under the -e or -f option are naive<br />
about creating lines consisting of a single '.'<br />
- 2-