Line | |
---|
1 | .TH UNIQ 1
|
---|
2 | .SH NAME
|
---|
3 | uniq \- delete consecutive identical lines in a file
|
---|
4 | .SH SYNOPSIS
|
---|
5 | \fBuniq\fR [\fB\-cdu\fR]\fR [\fB\-\fIn\fR] [\fB+\fIn\fR] [\fIinput [\fIoutput\fR]\fR]\fR
|
---|
6 | .br
|
---|
7 | .de FL
|
---|
8 | .TP
|
---|
9 | \\fB\\$1\\fR
|
---|
10 | \\$2
|
---|
11 | ..
|
---|
12 | .de EX
|
---|
13 | .TP 20
|
---|
14 | \\fB\\$1\\fR
|
---|
15 | # \\$2
|
---|
16 | ..
|
---|
17 | .SH OPTIONS
|
---|
18 | .FL "\-c" "Give count of identical lines in the input"
|
---|
19 | .FL "\-d" "Only duplicate lines are written to output"
|
---|
20 | .FL "\-u" "Only unique lines are written to output"
|
---|
21 | .FL "\-\fIn\fR" "Skip the first \fIn\fR columns when matching"
|
---|
22 | .FL "+\fIn\fR" "Skip the first \fIn\fR fields when matching"
|
---|
23 | .SH EXAMPLES
|
---|
24 | .EX "uniq +2 file" "Ignore first 2 fields when comparing"
|
---|
25 | .EX "uniq \-d inf outf" "Write duplicate lines to \fIoutf\fP"
|
---|
26 | .SH DESCRIPTION
|
---|
27 | .PP
|
---|
28 | .I Uniq
|
---|
29 | examines a file for consecutive lines that are identical.
|
---|
30 | All but duplicate entries are deleted, and the file is written to output.
|
---|
31 | The +\fIn\fR option skips the first \fIn\fR fields, where a field is defined
|
---|
32 | as a run of characters separated by white space.
|
---|
33 | The \-\fIn\fP option skips the first \fIn\fR spaces.
|
---|
34 | Fields are skipped first.
|
---|
35 | .SH "SEE ALSO"
|
---|
36 | .BR sort (1).
|
---|
Note:
See
TracBrowser
for help on using the repository browser.