5.3 Finding Changes

If you get the same file again and again, and you want to see what’s
different, the canonical method is to use the diff command.
It will list for you those records that are unique to each file, and
those that appear to have changed. One drawback is that it requires
the records in the two files to be in the same order. Another is that
it does not pay attention to the key fields that may be important to
you.

When I want to find the changes in a file, including additions,
deletions, and any changes for the information about a key I normally
use 4 applications of combine. One command is suffucuent to
find the new keys. One is enough to find those that are no longer there.
A third finds everything that is different, and the fourth finds the
before and after image of keys whose information has changed.

As an example, suppose my bridge club’s roster has a name and a phone
number, separated by commas, for each member. The following four
commands will identify the new members, the departed members, and
those whose phone number has changed.