summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2000-08-11 09:10:22 +0000
committerJim Meyering <jim@meyering.net>2000-08-11 09:10:22 +0000
commitf64320db7bf9d4c2c84c0a50ab39314b77bb6cd1 (patch)
tree1869d81e5d5496650a23323741d537602d4b781c /doc
parentf253241fa66332c1d1c7e328123df76007fd52b9 (diff)
downloadcoreutils-f64320db7bf9d4c2c84c0a50ab39314b77bb6cd1.tar.xz
(wc invocation): Update accordingly.
Diffstat (limited to 'doc')
-rw-r--r--doc/textutils.texi23
1 files changed, 14 insertions, 9 deletions
diff --git a/doc/textutils.texi b/doc/textutils.texi
index b1a220744..4ead6f371 100644
--- a/doc/textutils.texi
+++ b/doc/textutils.texi
@@ -1796,12 +1796,13 @@ contents of files.
@pindex wc
@cindex byte count
+@cindex character count
@cindex word count
@cindex line count
-@code{wc} counts the number of bytes, whitespace-separated words, and
-newlines in each given @var{file}, or standard input if none are given
-or for a @var{file} of @samp{-}. Synopsis:
+@code{wc} counts the number of bytes, characters, whitespace-separated
+words, and newlines in each given @var{file}, or standard input if none
+are given or for a @var{file} of @samp{-}. Synopsis:
@example
wc [@var{option}]@dots{} [@var{file}]@dots{}
@@ -1812,16 +1813,16 @@ wc [@var{option}]@dots{} [@var{file}]@dots{}
given as an argument, it prints the file name following the counts. If
more than one @var{file} is given, @code{wc} prints a final line
containing the cumulative counts, with the file name @file{total}. The
-counts are printed in this order: newlines, words, bytes.
+counts are printed in this order: newlines, words, characters, bytes.
By default, each count is output right-justified in a 7-byte field with
one space between fields so that the numbers and file names line up nicely
in columns. However, @sc{posix} requires that there be exactly one space
separating columns. You can make @code{wc} use the @sc{posix}-mandated
output format by setting the @env{POSIXLY_CORRECT} environment variable.
-By default, @code{wc} prints all three counts. Options can specify
-that only certain counts be printed. Options do not undo others
-previously given, so
+By default, @code{wc} prints three counts: the newline, words, byte counts.
+Options can specify that only certain counts be printed. Options do not
+undo others previously given, so
@example
wc --bytes --words
@@ -1840,12 +1841,16 @@ The program accepts the following options. Also see @ref{Common options}.
@item -c
@itemx --bytes
-@itemx --chars
@opindex -c
@opindex --bytes
-@opindex --chars
Print only the byte counts.
+@item -m
+@itemx --chars
+@opindex -m
+@opindex --chars
+Print only the character counts.
+
@item -w
@itemx --words
@opindex -w