executable file diff

SIMON mfs at mhuxr.UUCP
Fri Sep 13 11:20:03 AEST 1985


> If you are just interested in knowing if they are the same or not (without
> wanting to know WHAT is different) first check the obvious--are they the same
> size (as told by ls -l at first, then via the size command)?  Warning--if one
> of the files is "stripped" and the other is not (use the "file" command to
> determine this) make a stripped copy of the one that is not and use that to
> compare with the other.   This test passed, try the "sum" command on both
> the files which should come up with identical checksums if they are the same.
> If you are REALLY paranoid, do an "od" on each one, save the results, and do
> a conventional "diff" between those results.
> 
>         dan levy 

You could also use the cmp(1) command, which does a byte by byte compare
of the two files. Sounds easier to me.

Marcel Simon



More information about the Comp.unix.wizards mailing list