1 .\" You may copy, distribute and modify under the terms of the LDP General
2 .\" Public License as specified in the LICENSE file that comes with the
3 .\" gnumaniak distribution
5 .\" The author kindly requests that no comments regarding the "better"
6 .\" suitability or up-to-date notices of any info documentation alternative
7 .\" is added without contacting him first.
9 .\" (C) 2002 Ragnar Hojland Espinosa <ragnar@ragnar-hojland.com>
11 .\" GNU sdiff man page
12 .\" man pages are NOT obsolete!
13 .\" <ragnar@ragnar-hojland.com>
14 .TH SDIFF 1 "October 2002" "GNU diff Utilities 2.8.1"
16 \fBsdiff\fR \- find differences between two files and merge interactively
19 [\fB\-abdilstBEHW\fR] [\fB\-o \fIOUTFILE\fR] [\fB\-w \fICOLUMNS\fR]
20 [\fB\-I \fIREGEXP\fR] [\fB\-\-diff\-program=\fIPROGRAM\fR]
21 [\fB\-\-expand-tabs\fR] [\fB\-ignore\-all\-space\fR]
22 [\fB\-ignore\-blank\-lines\fR] [\fB\-\-ignore\-case\fR]
23 [\fB\-\-ignore\-matching\-lines=\fIREGEXP\fR]
24 [\fB\-\-ignore\-space\-change\fR]
25 [\fB\-\-ignore\-tab\-expansion\fR]
26 [\fB\-\-left\-column\fR] [\fB\-\-minimal\fR]
27 [\fB\-\-output=\fIOUTFILE\fR]
28 [\fB\-\-speed\-large\-files\fR]
29 [\fB\-\-strip\-trailing\-cr\fR]
30 [\fB\-\-supress\-common\-lines\fR]
31 [\fB\-\-text\fR] [\fB\-\-width=\fICOLUMNS\fR]
35 [\fB-v\fR] [\fB\-\-help\fR] [\fB\-\-version\fR]
38 merges two files and interactively outputs the
41 if \fB\-o\fR is specified, or producing a side-by-side difference if it's
52 whose file name is that of
64 Normally \fBsdiff\fP invokes \fBdiff\fP(1) to do its work, but you can
65 change the program by setting the \fBDIFF\fP environment variable to the
66 name of other program. You may also change the editor, setting the
67 \fBEDITOR\fR environment variable.
71 Treat all files as text and compare them line-by-line, even if they
72 do not appear to be text.
74 .B \-b, \-\-ignore\-space\-change
75 Ignore changes in amount of white space.
78 Change the algorithm to perhaps find a smaller set of changes. This
81 slower (sometimes much slower).
83 .B \-i, \-\-ignore\-case
84 Ignore changes in case; consider upper- and lower-case to be the same.
86 .B \-l, \-\-left\-column
87 Print only the left column of two common lines.
89 .BI "\-o " OUTFILE ", \-\-output=" OUTFILE
90 Put merged output into
92 This option is required for merging.
94 .B \-s, \-\-suppress\-common\-lines
95 Do not print common lines.
97 .B \-t, \-\-expand\-tabs
98 Expand tabs to spaces in the output, to preserve the alignment of tabs
101 .BI "\-w " COLUMNS ", \-\-width=" COLUMNS
102 Use an output width of
104 Note that for historical reasons, this option is
109 .B \-B, \-\-ignore\-blank\-lines
110 Ignore changes that just insert or delete blank lines.
112 .B \-E, \-\-ignore\-tab\-expansion
113 Ignores changes in whitespace due to tab expansion.
115 .B \-H, \-\-speed\-large\-files
116 Use heuristics to speed handling of large files that have numerous
117 scattered small changes.
119 .BI "\-I " REGEXP ", \-\-ignore\-matching\-lines=" REGEXP
120 Ignore changes that just insert or delete lines that match
124 Ignore horizontal white space when comparing lines.
125 Note that for historical reasons, this option is
130 .B \-\-diff\-program= \fIPROGRAM
131 Use an external \fIPROGRAM\fR, compatible with \fBdiff\fR, to compare files.
133 .B \-\-strip\-trailing\-cr
134 Strips trailing CRs. Useful when processing output from systems that use
135 CRLF as end of line markers.
138 Print a usage message on standard output and exit successfully.
141 Output the version number of
144 Groups of common lines, with a blank gutter, are copied from the
145 first file to the output. After each group of differing lines, \fBsdiff\fP
148 and pauses, waiting for one of the following commands.
151 Discard both versions. Invoke a text editor on an empty temporary
152 file, then copy the resulting file to the output.
155 Concatenate the two versions, edit the result in a temporary file,
156 then copy the edited result to the output.
161 except precede each version with a header
162 that shows what file and lines the version came from.
165 Edit a copy of the left version, then copy the result to the output.
168 Edit a copy of the right version, then copy the result to the output.
171 Copy the left version to the output.
177 Copy the right version to the output.
180 Silently copy common lines.
183 Verbosely copy common lines. This is the default.
187 exits with one of the following values:
190 \fBsdiff\fR was successful, no differences found.
193 Some differences were found.
198 cmp(1), comm(1), diff(1), diff3(1).
200 Report bugs to bug-gnu-utils@gnu.org.
201 Page updated by Ragnar Hojland Espinosa <ragnar@ragnar-hojland.com>