When a changeset wants to modify a region of a file and that region has been independently modified since the changeset was created, this modification (patch hunk) cannot be applied. The conflicting patch hunks are saved in a .rej file named after the target file. Resolving the conflict often means doing some editing so the rejected hunks can be applied.

The rejected patch hunks correspond to the rejected local changes for tla update, and to the rejected changes in the archive for tla replay. See ReplayVsUpdate.

A good habit is to add the rule "unrecognized \.rej$" to the file {arch}/=tagging-method, so that tla tree-lint and all commands calling tree-lint warn you when you have *.rej files in your working directory. (See this discussion for details.)

MilesBader posted a message to gnu-arch-users mailing list explaining how to apply *.rej files (patch rejects) using GNU Emacs or XEmacs:

Non-Emacs users can convert .rej files into unified diffs using filterdiff, from the patchutils package. Typical invocation: filterdiff -v --format=unified foo.c.rej

For the specific case of conflicts in GNU-style ChangeLog files, the tla-fix-changelog-conflicts command in the tla-tools package may be useful.

Process *.rej files (last edited 2006-02-25 23:18:10 by MichaelOlson)