[BACK]Return to sdiff.1 CVS log [TXT][DIR] Up to [local] / src / usr.bin / sdiff

Annotation of src/usr.bin/sdiff/sdiff.1, Revision 1.2

1.2     ! tedu        1: .\" $OpenBSD$
1.1       tedu        2: .\"
                      3: .\" Written by Raymond Lai <ray@cyth.net>.
                      4: .\" Public domain.
                      5: .\"
                      6: .Dd October 29, 2005
                      7: .Dt SDIFF 1
                      8: .Os
                      9: .Sh NAME
                     10: .Nm sdiff
                     11: .Nd side-by-side diff
                     12: .Sh SYNOPSIS
                     13: .Nm
                     14: .Op Fl abDdilstW
                     15: .Op Fl I Ar regexp
                     16: .Op Fl o Ar outfile
                     17: .Op Fl w Ar width
                     18: .Ar file1
                     19: .Ar file2
                     20: .Sh DESCRIPTION
                     21: Shows a side-by-side comparison of two files.
                     22: .Pp
                     23: The options are:
                     24: .Bl -tag -width Ds
                     25: .It Fl l
                     26: Only print left column for identical lines.
                     27: .It Fl o Ar outfile
                     28: Interactively merge
                     29: .Ar file1
                     30: and
                     31: .Ar file2
                     32: into
                     33: .Ar outfile .
                     34: In this mode, the user is prompted for each set of differences.
                     35: .Pp
                     36: The commands are:
                     37: .Bl -tag -width Ds
                     38: .It Cm l
                     39: Choose left set of diffs.
                     40: .It Cm r
                     41: Choose right set of diffs.
                     42: .It Cm s
                     43: Silent mode \(en identical lines are not printed.
                     44: .It Cm v
                     45: Verbose mode \(en identical lines are printed.
                     46: .It Cm e
                     47: Start editing an empty file, which will be merged into
                     48: .Ar outfile
                     49: upon exiting the editor.
                     50: .It Cm e Cm l
                     51: Start editing file with left set of diffs.
                     52: .It Cm e Cm r
                     53: Start editing file with right set of diffs.
                     54: .It Cm e Cm b
                     55: Start editing file with both sets of diffs.
                     56: .It Cm q
                     57: Quit
                     58: .Nm .
                     59: .El
                     60: .It Fl s
                     61: Skip identical lines.
                     62: .It Fl D
                     63: Debug mode.
                     64: Verifies whenever possible.
                     65: Used to test how well
                     66: .Nm
                     67: works with various
                     68: .Xr diff 1
                     69: implementations.
                     70: .It Fl w Ar width
                     71: Print a maximum of
                     72: .Ar width
                     73: characters on each line.
                     74: The default is 130 characters.
                     75: .El
                     76: .Pp
                     77: Options passed to
                     78: .Xr diff 1
                     79: are:
                     80: .Bl -tag -width Ds
                     81: .It Fl a
                     82: Treat
                     83: .Ar file1
                     84: and
                     85: .Ar file2
                     86: as text files.
                     87: .It Fl b
                     88: Ignore trailing blank spaces.
                     89: .It Fl d
                     90: Minimize diff size.
                     91: .It Fl I Ar regexp
                     92: Ignore line changes matching
                     93: .Ar regexp .
                     94: .It Fl i
                     95: Do a case-insensitive comparison.
                     96: .It Fl t
                     97: Expand tabs to spaces.
                     98: .It Fl W
                     99: Ignore all spaces.
                    100: (The
                    101: .Fl w
                    102: flag is passed to
                    103: .Xr diff 1 .)
                    104: .El
                    105: .Sh CAVEATS
                    106: Although undocumented,
                    107: .Nm
                    108: supports all options supported by GNU sdiff.
                    109: Some options require GNU diff.
                    110: .Pp
                    111: Tabs are treated as anywhere from one to eight characters wide,
                    112: depending on the current column.
                    113: Terminals that treat tabs as eight characters wide will look best.
                    114: .Sh AUTHORS
                    115: .Nm
                    116: was written from scratch for the public domain by
                    117: .An Ray Lai Aq ray@cyth.net .