summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2013-02-01 13:32:48 -0800
committerPaul Eggert <eggert@cs.ucla.edu>2013-02-01 13:33:21 -0800
commitd57ebc45ba4c59cc6f8bb0e9a435ecbddc84b982 (patch)
tree2e1dcf0f5d406a676517cb9d47858c48899ee711
parentf25519d6887fc9285d3e0ff1cd259a5e74d5a80a (diff)
downloadcoreutils-d57ebc45ba4c59cc6f8bb0e9a435ecbddc84b982.tar.xz
doc: say how to tac char-by-char
This fixes Bug#12115, reported by Reuben Thomas. * doc/coreutils.texi (tac invocation): Document how to reverse a file character by character. Break out MS-DOS into a separate section, like 'cat' does.
-rw-r--r--doc/coreutils.texi15
1 files changed, 11 insertions, 4 deletions
diff --git a/doc/coreutils.texi b/doc/coreutils.texi
index eac8d52bb..e29af8bec 100644
--- a/doc/coreutils.texi
+++ b/doc/coreutils.texi
@@ -1613,10 +1613,7 @@ precedes in the file.
@itemx --regex
@opindex -r
@opindex --regex
-Treat the separator string as a regular expression. Users of @command{tac}
-on MS-DOS/MS-Windows should note that, since @command{tac} reads files in
-binary mode, each line of a text file might end with a CR/LF pair
-instead of the Unix-style LF.
+Treat the separator string as a regular expression.
@item -s @var{separator}
@itemx --separator=@var{separator}
@@ -1626,8 +1623,18 @@ Use @var{separator} as the record separator, instead of newline.
@end table
+On systems like MS-DOS that distinguish between text and binary files,
+@command{tac} reads and writes in binary mode.
+
@exitstatus
+Example:
+
+@example
+# Reverse a file character by character.
+tac -r -s 'x\|[^x]'
+@end example
+
@node nl invocation
@section @command{nl}: Number lines and write files