merge.1 revision 9
1.de Id 2.ds Rv \\$3 3.ds Dt \\$4 4.. 5.Id $Id: merge.1,v 5.3 1991/02/28 19:18:45 eggert Exp $ 6.TH MERGE 1 \*(Dt GNU 7.SH NAME 8merge \- three-way file merge 9.SH SYNOPSIS 10.B merge 11[ 12.B \-L 13.I label1 14[ 15.B \-L 16.I label3 17] ] [ 18.B \-p 19] [ 20.B \-q 21] 22.I "file1 file2 file3" 23.SH DESCRIPTION 24.B merge 25incorporates all changes that lead from 26.I file2 27to 28.I file3 29into 30.IR file1 . 31The result goes to standard output if 32.B \-p 33is present, into 34.I file1 35otherwise. 36.B merge 37is useful for combining separate changes to an original. Suppose 38.I file2 39is the original, and both 40.I file1 41and 42.I file3 43are modifications of 44.IR file2 . 45Then 46.B merge 47combines both changes. 48.PP 49An overlap occurs if both 50.I file1 51and 52.I file3 53have changes in a common segment of lines. 54On a few older hosts where 55.B diff3 56does not support the 57.B \-E 58option, 59.B merge 60does not detect overlaps, and merely supplies the changed lines from 61.I file3. 62On most hosts, if overlaps occur, 63.B merge 64outputs a message (unless the 65.B \-q 66option is given), 67and includes both alternatives 68in the result. The alternatives are delimited as follows: 69.LP 70.RS 71.nf 72.BI <<<<<<< " file1" 73.I "lines in file1" 74.B "=======" 75.I "lines in file3" 76.BI >>>>>>> " file3" 77.RE 78.fi 79.LP 80If there are overlaps, the user should edit the result and delete one of the 81alternatives. 82If the 83.BI \-L "\ label1" 84and 85.BI \-L "\ label3" 86options are given, the labels are output in place of the names 87.I file1 88and 89.I file3 90in overlap reports. 91.SH DIAGNOSTICS 92Exit status is 0 for no overlaps, 1 for some overlaps, 2 for trouble. 93.SH IDENTIFICATION 94Author: Walter F. Tichy. 95.br 96Revision Number: \*(Rv; Release Date: \*(Dt. 97.br 98Copyright \(co 1982, 1988, 1989 by Walter F. Tichy. 99.br 100Copyright \(co 1990, 1991 by Paul Eggert. 101.SH SEE ALSO 102diff3(1), diff(1), rcsmerge(1), co(1). 103