summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2001-09-16 07:02:26 +0000
committerJim Meyering <jim@meyering.net>2001-09-16 07:02:26 +0000
commit02e4c447fb640b883d28dd2fbaf8776fb1b29710 (patch)
treefd24546603e9976a2795edb982e5815949fb74e7 /doc
parentfc98e3b53bc40fc98075fd62751eedd6a0833799 (diff)
downloadcoreutils-02e4c447fb640b883d28dd2fbaf8776fb1b29710.tar.xz
(uniq invocation): The input need not
be sorted. Try to clarify -d versus -D versus -u.
Diffstat (limited to 'doc')
-rw-r--r--doc/coreutils.texi11
1 files changed, 6 insertions, 5 deletions
diff --git a/doc/coreutils.texi b/doc/coreutils.texi
index a30d45c08..076d343e5 100644
--- a/doc/coreutils.texi
+++ b/doc/coreutils.texi
@@ -3131,8 +3131,9 @@ discards all but one of identical successive lines. Optionally, it can
instead show only lines that appear exactly once, or lines that appear
more than once.
-The input must be sorted. If your input is not sorted, perhaps you want
-to use @code{sort -u}.
+The input need not be sorted, but duplicate input lines are detected
+only if they are adjacent. If you want to discard non-adjacent
+duplicate lines, perhaps you want to use @code{sort -u}.
If no @var{output} file is specified, @code{uniq} writes to standard
output.
@@ -3181,14 +3182,14 @@ Ignore differences in case when comparing lines.
@opindex -d
@opindex --repeated
@cindex duplicate lines, outputting
-Print only duplicate lines.
+Print one copy of each duplicate line.
@item -D
@itemx --all-repeated[=@var{delimit-method}]
@opindex -D
@opindex --all-repeated
@cindex all duplicate lines, outputting
-Print all duplicate lines and only duplicate lines.
+Print all copies of each duplicate line.
This option is useful mainly in conjunction with other options e.g.,
to ignore case or to compare only selected fields.
The optional @var{delimit-method} tells how to delimit
@@ -3223,7 +3224,7 @@ This is a @sc{gnu} extension.
@opindex -u
@opindex --unique
@cindex unique lines, outputting
-Print only unique lines.
+Print non-duplicate lines.
@item -w @var{n}
@itemx --check-chars=@var{n}