summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorCharles Levert <charles_levert@gna.org>2005-06-21 15:22:57 +0000
committerCharles Levert <charles_levert@gna.org>2005-06-21 15:22:57 +0000
commitad671730773156ab685c1121ec4c61cc1fb8864e (patch)
tree752108866be37dbd0a2691350a58be8645f47986 /doc
parent6fe02457a28caea8e8611803154af76c38e70250 (diff)
downloadgrep-ad671730773156ab685c1121ec4c61cc1fb8864e.tar.gz
* src/grep.c: The new -T/--initial-tab framework, only
partially used at this point to make for a simpler initial patch in CVS. A subset of patch #3644 on Savannah. The option name/calling convention is the same as for GNU diff. * doc/grep.texi, doc/grep.1: Document -T/--initial-tab.
Diffstat (limited to 'doc')
-rw-r--r--doc/grep.118
-rw-r--r--doc/grep.texi16
2 files changed, 33 insertions, 1 deletions
diff --git a/doc/grep.1 b/doc/grep.1
index 680e51ef..5e44e3b9 100644
--- a/doc/grep.1
+++ b/doc/grep.1
@@ -12,7 +12,7 @@
.de Id
.ds Dt \\$4
..
-.Id $Id: grep.1,v 1.30 2005/06/21 14:58:50 charles_levert Exp $
+.Id $Id: grep.1,v 1.31 2005/06/21 15:22:58 charles_levert Exp $
.TH GREP 1 \*(Dt "GNU Project"
.SH NAME
grep, egrep, fgrep \- print lines matching a pattern
@@ -386,6 +386,22 @@ and should redirect standard and error output to
.B /dev/null
instead.
.TP
+.BR \-T ", " \-\^\-initial\-tab
+Makes sure that the first character of actual line content lies on a
+tab stop, so that the alignment of tabs looks normal.
+This is useful when combined with
+.B \-H
+(which is implicit when there is more than one file to search),
+.BR \-n ,
+and
+.BR \-b ;
+these options prepend their output at the beginning of the displayed
+line, before the actual content.
+In order to improve the probability that all matched or context lines
+from a single file will all start at the same column, this also causes
+the line number and octet offset (if present) to be printed in a minimum
+size field width.
+.TP
.BR \-U ", " \-\^\-binary
Treat the file(s) as binary. By default, under MS-DOS and MS-Windows,
.BR grep
diff --git a/doc/grep.texi b/doc/grep.texi
index e0de9815..e42324fa 100644
--- a/doc/grep.texi
+++ b/doc/grep.texi
@@ -523,6 +523,22 @@ yields better performance. However, @samp{--mmap} can cause undefined
behavior (including core dumps) if an input file shrinks while
@command{grep} is operating, or if an I/O error occurs.
+@item -T
+@itemx --initial-tab
+@opindex -T
+@opindex --initial-tab
+@cindex tab-aligned content lines
+Makes sure that the first character of actual line content lies on a
+tab stop, so that the alignment of tabs looks normal.
+This is useful when combined with @samp{-H} (which is implicit when
+there is more than one file to search), @samp{-n}, and @samp{-b};
+these options prepend their output at the beginning of the displayed
+line, before the actual content.
+In order to improve the probability that all matched or context lines
+from a single file will all start at the same column, this also causes
+the line number and octet offset (if present) to be printed in a minimum
+size field width.
+
@item -Z
@itemx --null
@opindex -Z