[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Changes to grep/manual/grep.txt,v
From: |
Jim Meyering |
Subject: |
Changes to grep/manual/grep.txt,v |
Date: |
Fri, 02 Mar 2012 09:28:35 +0000 |
CVSROOT: /webcvs/grep
Module name: grep
Changes by: Jim Meyering <meyering> 12/03/02 09:28:32
Index: grep.txt
===================================================================
RCS file: /webcvs/grep/grep/manual/grep.txt,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- grep.txt 25 Jun 2011 09:28:43 -0000 1.9
+++ grep.txt 2 Mar 2012 09:28:23 -0000 1.10
@@ -33,13 +33,13 @@
grep
****
-`grep' prints lines that match a pattern.
+`grep' prints lines that contain a match for a pattern.
- This manual is for version 2.9 of GNU Grep.
+ This manual is for version 2.11 of GNU Grep.
This manual is for `grep', a pattern matching engine.
- Copyright (C) 1999-2002, 2005, 2008-2011 Free Software Foundation,
+ Copyright (C) 1999-2002, 2005, 2008-2012 Free Software Foundation,
Inc.
Permission is granted to copy, distribute and/or modify this
@@ -52,7 +52,7 @@
1 Introduction
**************
-`grep' searches the input files for lines containing a match to a given
+`grep' searches input files for lines containing a match to a given
pattern list. When it finds a match in a line, it copies the line to
standard output (by default), or produces whatever other sort of output
you have requested with options.
@@ -79,12 +79,12 @@
2.1 Command-line Options
========================
-`grep' comes with a rich set of options: some from POSIX.2 and some
-being GNU extensions. Long option names are always a GNU extension,
-even for options that are from POSIX specifications. Options that are
-specified by POSIX, under their short names, are explicitly marked as
-such to facilitate POSIX-portable programming. A few option names are
-provided for compatibility with older or more exotic implementations.
+`grep' comes with a rich set of options: some from POSIX and some being
+GNU extensions. Long option names are always a GNU extension, even for
+options that are from POSIX specifications. Options that are specified
+by POSIX, under their short names, are explicitly marked as such to
+facilitate POSIX-portable programming. A few option names are provided
+for compatibility with older or more exotic implementations.
Several additional options control which variant of the `grep'
matching engine is used. *Note grep Programs::.
@@ -150,7 +150,7 @@
`-c'
`--count'
Suppress normal output; instead print a count of matching lines
- for each input file. With the `-v', `--invert-match' option,
+ for each input file. With the `-v' (`--invert-match') option,
count non-matching lines. (`-c' is specified by POSIX.)
`--color[=WHEN]'
@@ -159,26 +159,26 @@
lines, file names, line numbers, byte offsets, and separators (for
fields and groups of context lines) with escape sequences to
display them in color on the terminal. The colors are defined by
- the environment variable GREP_COLORS and default to
+ the environment variable `GREP_COLORS' and default to
`ms=01;31:mc=01;31:sl=:cx=:fn=35:ln=32:bn=32:se=36' for bold red
matched text, magenta file names, green line numbers, green byte
offsets, cyan separators, and default terminal colors otherwise.
- The deprecated environment variable GREP_COLOR is still supported,
- but its setting does not have priority; it defaults to `01;31'
- (bold red) which only covers the color for matched text. WHEN is
- `never', `always', or `auto'.
+ The deprecated environment variable `GREP_COLOR' is still
+ supported, but its setting does not have priority; it defaults to
+ `01;31' (bold red) which only covers the color for matched text.
+ WHEN is `never', `always', or `auto'.
`-L'
`--files-without-match'
Suppress normal output; instead print the name of each input file
from which no output would normally have been printed. The
- scanning of every file will stop on the first match.
+ scanning of each file stops on the first match.
`-l'
`--files-with-matches'
Suppress normal output; instead print the name of each input file
from which output would normally have been printed. The scanning
- of every file will stop on the first match. (`-l' is specified by
+ of each file stops on the first match. (`-l' is specified by
POSIX.)
`-m NUM'
@@ -232,13 +232,17 @@
Suppress error messages about nonexistent or unreadable files.
Portability note: unlike GNU `grep', 7th Edition Unix `grep' did
not conform to POSIX, because it lacked `-q' and its `-s' option
- behaved like GNU `grep''s `-q' option. USG-style `grep' also
+ behaved like GNU `grep''s `-q' option.(1) USG-style `grep' also
lacked `-q' but its `-s' option behaved like GNU `grep''s.
Portable shell scripts should avoid both `-q' and `-s' and should
redirect standard and error output to `/dev/null' instead. (`-s'
is specified by POSIX.)
+ ---------- Footnotes ----------
+
+ (1) Of course, 7th Edition Unix predated POSIX by several years!
+
2.1.4 Output Line Prefix Control
--------------------------------
@@ -313,7 +317,7 @@
--------------------------
Regardless of how these options are set, `grep' will never print any
-given line more than once. If the `-o' or `--only-matching' option is
+given line more than once. If the `-o' (`--only-matching') option is
specified, these options have no effect and a warning is given upon
their use.
@@ -339,18 +343,28 @@
adjacent to each other.
- Matching lines normally use `:' as a separator between prefix fields
-and actual line content. Context (i.e., non-matching) lines use `-'
-instead. When no context is specified, matching lines are simply
-output one right after another. When nonzero context is specified,
-lines that are adjacent in the input form a group and are output one
-right after another, while a separator appears by default between
-disjoint groups on a line of its own and without any prefix. The
-default separator is `--', however whether to include it and its
-appearance can be changed with the options above. Each group may
-contain several matching lines when they are close enough to each other
-that two otherwise adjacent but divided groups connect and can just
-merge into a single contiguous one.
+ Here are some points about how `grep' chooses the separator to print
+between prefix fields and line content:
+
+ * Matching lines normally use `:' as a separator between prefix
+ fields and actual line content.
+
+ * Context (i.e., non-matching) lines use `-' instead.
+
+ * When no context is specified, matching lines are simply output one
+ right after another.
+
+ * When nonzero context is specified, lines that are adjacent in the
+ input form a group and are output one right after another, while a
+ separator appears by default between disjoint groups on a line of
+ its own and without any prefix.
+
+ * The default separator is `--', however whether to include it and
+ its appearance can be changed with the options above.
+
+ * Each group may contain several matching lines when they are close
+ enough to each other that two otherwise adjacent but divided
+ groups connect and can just merge into a single contiguous one.
2.1.6 File and Directory Selection
----------------------------------
@@ -365,13 +379,17 @@
binary data, assume that the file is of type TYPE. By default,
TYPE is `binary', and `grep' normally outputs either a one-line
message saying that a binary file matches, or no message if there
- is no match. If TYPE is `without-match', `grep' assumes that a
- binary file does not match; this is equivalent to the `-I' option.
+ is no match.
+
+ If TYPE is `without-match', `grep' assumes that a binary file does
+ not match; this is equivalent to the `-I' option.
+
If TYPE is `text', `grep' processes a binary file as if it were
- text; this is equivalent to the `-a' option. _Warning:_
- `--binary-files=text' might output binary garbage, which can have
- nasty side effects if the output is a terminal and if the terminal
- driver interprets some of it as commands.
+ text; this is equivalent to the `-a' option.
+
+ _Warning:_ `--binary-files=text' might output binary garbage,
+ which can have nasty side effects if the output is a terminal and
+ if the terminal driver interprets some of it as commands.
`-D ACTION'
`--devices=ACTION'
@@ -415,8 +433,8 @@
`-r'
`-R'
`--recursive'
- For each directory mentioned on the command line, read and process
- all files in that directory, recursively. This is the same as the
+ For each directory operand, read and process all files in that
+ directory, recursively. This is the same as the
`--directories=recurse' option.
@@ -428,10 +446,11 @@
penalty.
`--mmap'
- This option is ignored for backwards compatibility. It used to
- read input with the `mmap' system call, instead of the default
- `read' system call. On modern systems, `mmap' would rarely if
- ever yield better performance.
+ This option is deprecated and now elicits a warning, but is
+ otherwise a no-op. It used to make `grep' read input with the
+ `mmap' system call, instead of the default `read' system call. On
+ modern systems, `mmap' would rarely if ever yield better
+ performance.
`-U'
`--binary'
@@ -470,6 +489,28 @@
variables are set, if the locale catalog is not installed, or if `grep'
was not compiled with national language support (NLS).
+ Many of the environment variables in the following list let you
+control highlighting using Select Graphic Rendition (SGR) commands
+interpreted by the terminal or terminal emulator. (See the section in
+the documentation of your text terminal for permitted values and their
+meanings as character attributes.) These substring values are integers
+in decimal representation and can be concatenated with semicolons.
+`grep' takes care of assembling the result into a complete SGR sequence
+(`\33['...`m'). Common values to concatenate include `1' for bold, `4'
+for underline, `5' for blink, `7' for inverse, `39' for default
+foreground color, `30' to `37' for foreground colors, `90' to `97' for
+16-color mode foreground colors, `38;5;0' to `38;5;255' for 88-color
+and 256-color modes foreground colors, `49' for default background
+color, `40' to `47' for background colors, `100' to `107' for 16-color
+mode background colors, and `48;5;0' to `48;5;255' for 88-color and
+256-color modes background colors.
+
+ The two-letter names used in the `GREP_COLORS' environment variable
+(and some of the others) refer to terminal "capabilities," the ability
+of a terminal to highlight text, or change its color, and so on. These
+capabilities are stored in an online database and accessed by the
+`terminfo' library.
+
`GREP_OPTIONS'
This variable specifies default options to be placed in front of
any explicit options. For example, if `GREP_OPTIONS' is
@@ -480,6 +521,13 @@
backslash escapes the next character, so it can be used to specify
an option containing whitespace or a backslash.
+ The `GREP_OPTIONS' value does not affect whether `grep' without
+ file operands searches standard input or the working directory;
+ that is affected only by command-line options. For example, the
+ command `grep PAT' searches standard input and the command `grep
+ -r PAT' searches the working directory, regardless of whether
+ `GREP_OPTIONS' contains `-r'.
+
`GREP_COLOR'
This variable specifies the color used to highlight matched
(non-empty) text. It is deprecated in favor of `GREP_COLORS', but
@@ -494,7 +542,7 @@
`GREP_COLORS'
This variable specifies the colors and other attributes used to
highlight various parts of the output. Its value is a
- colon-separated list of capabilities that defaults to
+ colon-separated list of `terminfo' capabilities that defaults to
`ms=01;31:mc=01;31:sl=:cx=:fn=35:ln=32:bn=32:se=36' with the `rv'
and `ne' boolean capabilities omitted (i.e., false). Supported
capabilities are as follows.
@@ -532,17 +580,19 @@
`ms=01;31'
SGR substring for matching non-empty text in a selected line.
- (This is only used when the `-v' command-line option is
+ (This is used only when the `-v' command-line option is
omitted.) The effect of the `sl=' (or `cx=' if `rv')
- capability remains active when this kicks in. The default is
- a bold red text foreground over the current line background.
+ capability remains active when this takes effect. The
+ default is a bold red text foreground over the current line
+ background.
`mc=01;31'
SGR substring for matching non-empty text in a context line.
- (This is only used when the `-v' command-line option is
+ (This is used only when the `-v' command-line option is
specified.) The effect of the `cx=' (or `sl=' if `rv')
- capability remains active when this kicks in. The default is
- a bold red text foreground over the current line background.
+ capability remains active when this takes effect. The
+ default is a bold red text foreground over the current line
+ background.
`fn=35'
SGR substring for file names prefixing any content line. The
@@ -571,7 +621,7 @@
Erase in Line (EL) to Right (`\33[K') each time a colorized
item ends. This is needed on terminals on which EL is not
supported. It is otherwise useful on terminals for which the
- `back_color_erase' (`bce') boolean terminfo capability does
+ `back_color_erase' (`bce') boolean `terminfo' capability does
not apply, when the chosen highlight colors do not affect the
background, or when EL is too slow or causes too much flicker.
The default is false (i.e., the capability is omitted).
@@ -579,21 +629,6 @@
Note that boolean capabilities have no `='... part. They are
omitted (i.e., false) by default and become true when specified.
- See the Select Graphic Rendition (SGR) section in the
- documentation of your text terminal for permitted values and their
- meaning as character attributes. These substring values are
- integers in decimal representation and can be concatenated with
- semicolons. `grep' takes care of assembling the result into a
- complete SGR sequence (`\33['...`m'). Common values to
- concatenate include `1' for bold, `4' for underline, `5' for blink,
- `7' for inverse, `39' for default foreground color, `30' to `37'
- for foreground colors, `90' to `97' for 16-color mode foreground
- colors, `38;5;0' to `38;5;255' for 88-color and 256-color modes
- foreground colors, `49' for default background color, `40' to `47'
- for background colors, `100' to `107' for 16-color mode background
- colors, and `48;5;0' to `48;5;255' for 88-color and 256-color
- modes background colors.
-
`LC_ALL'
`LC_COLLATE'
`LANG'
@@ -616,12 +651,12 @@
default `C' locale uses American English messages.
`POSIXLY_CORRECT'
- If set, `grep' behaves as POSIX.2 requires; otherwise, `grep'
- behaves more like other GNU programs. POSIX.2 requires that
- options that follow file names must be treated as file names; by
- default, such options are permuted to the front of the operand list
- and are treated as options. Also, `POSIXLY_CORRECT' disables
- special handling of an invalid bracket expression. *Note
+ If set, `grep' behaves as POSIX requires; otherwise, `grep'
+ behaves more like other GNU programs. POSIX requires that options
+ that follow file names must be treated as file names; by default,
+ such options are permuted to the front of the operand list and are
+ treated as options. Also, `POSIXLY_CORRECT' disables special
+ handling of an invalid bracket expression. *Note
invalid-bracket-expr::.
`_N_GNU_nonoption_argv_flags_'
@@ -650,9 +685,11 @@
2.4 `grep' Programs
===================
-`grep' searches the named input files (or standard input if no files
-are named, or the file name `-' is given) for lines containing a match
-to the given pattern. By default, `grep' prints the matching lines.
+`grep' searches the named input files for lines containing a match to
+the given pattern. By default, `grep' prints the matching lines. A
+file named `-' stands for standard input. If no input is specified,
+`grep' searches the working directory `.' if given a command-line
+option specifying recursion; otherwise, `grep' searches standard input.
There are four major variants of `grep', controlled by the following
options.
@@ -693,13 +730,13 @@
expressions, by using various operators to combine smaller expressions.
`grep' understands three different versions of regular expression
syntax: "basic," (BRE) "extended" (ERE) and "perl". In GNU `grep',
-there is no difference in available functionality between basic and
+there is no difference in available functionality between the basic and
extended syntaxes. In other implementations, basic regular expressions
are less powerful. The following description applies to extended
regular expressions; differences for basic regular expressions are
summarized afterwards. Perl regular expressions give additional
-functionality, and are documented in pcresyntax(3) and pcrepattern(3),
-but may not be available on every system.
+functionality, and are documented in the pcresyntax(3) and
+pcrepattern(3) manual pages, but may not be available on every system.
3.1 Fundamental Structure
=========================
@@ -738,13 +775,14 @@
M times.
- Two regular expressions may be concatenated; the resulting regular
-expression matches any string formed by concatenating two substrings
-that respectively match the concatenated expressions.
+ The empty regular expression matches the empty string. Two regular
+expressions may be concatenated; the resulting regular expression
+matches any string formed by concatenating two substrings that
+respectively match the concatenated expressions.
Two regular expressions may be joined by the infix operator `|'; the
resulting regular expression matches any string matching either
-alternalte expression.
+alternate expression.
Repetition takes precedence over concatenation, which in turn takes
precedence over alternation. A whole expression may be enclosed in
@@ -772,14 +810,18 @@
Finally, certain named classes of characters are predefined within
bracket expressions, as follows. Their interpretation depends on the
-`LC_CTYPE' locale; the interpretation below is that of the `C' locale,
-which is the default if no `LC_CTYPE' locale is specified.
+`LC_CTYPE' locale; for example, `[[:alnum:]]' means the character class
+of numbers and letters in the current locale.
`[:alnum:]'
- Alphanumeric characters: `[:alpha:]' and `[:digit:]'.
+ Alphanumeric characters: `[:alpha:]' and `[:digit:]'; in the `C'
+ locale and ASCII character encoding, this is the same as
+ `[0-9A-Za-z]'.
`[:alpha:]'
- Alphabetic characters: `[:lower:]' and `[:upper:]'.
+ Alphabetic characters: `[:lower:]' and `[:upper:]'; in the `C'
+ locale and ASCII character encoding, this is the same as
+ `[A-Za-z]'.
`[:blank:]'
Blank characters: space and tab.
@@ -796,34 +838,34 @@
Graphical characters: `[:alnum:]' and `[:punct:]'.
`[:lower:]'
- Lower-case letters: `a b c d e f g h i j k l m n o p q r s t u v w
- x y z'.
+ Lower-case letters; in the `C' locale and ASCII character
+ encoding, this is `a b c d e f g h i j k l m n o p q r s t u v w x
+ y z'.
`[:print:]'
Printable characters: `[:alnum:]', `[:punct:]', and space.
`[:punct:]'
- Punctuation characters: `! " # $ % & ' ( ) * + , - . / : ; < = > ?
- @ [ \ ] ^ _ ` { | } ~'.
+ Punctuation characters; in the `C' locale and ASCII character
+ encoding, this is `! " # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \
+ ] ^ _ ` { | } ~'.
`[:space:]'
- Space characters: tab, newline, vertical tab, form feed, carriage
- return, and space. *Note Usage::, for more discussion of matching
- newlines.
+ Space characters: in the `C' locale, this is tab, newline,
+ vertical tab, form feed, carriage return, and space. *Note
+ Usage::, for more discussion of matching newlines.
`[:upper:]'
- Upper-case letters: `A B C D E F G H I J K L M N O P Q R S T U V W
- X Y Z'.
+ Upper-case letters: in the `C' locale and ASCII character
+ encoding, this is `A B C D E F G H I J K L M N O P Q R S T U V W X
+ Y Z'.
`[:xdigit:]'
Hexadecimal digits: `0 1 2 3 4 5 6 7 8 9 A B C D E F a b c d e f'.
- For example, `[[:alnum:]]' means `[0-9A-Za-z]', except the latter
-depends upon the `C' locale and the ASCII character encoding, whereas
-the former is independent of locale and character set. (Note that the
-brackets in these class names are part of the symbolic names, and must
-be included in addition to the brackets delimiting the bracket
-expression.)
+ Note that the brackets in these class names are part of the symbolic
+names, and must be included in addition to the brackets delimiting the
+bracket expression.
If you mistakenly omit the outer brackets, and search for say,
`[:upper:]', GNU `grep' prints a diagnostic and exits with status 2, on
@@ -873,28 +915,28 @@
The `\' character, when followed by certain ordinary characters, takes
a special meaning:
-``\b''
+`\b'
Match the empty string at the edge of a word.
-``\B''
+`\B'
Match the empty string provided it's not at the edge of a word.
-``\<''
+`\<'
Match the empty string at the beginning of word.
-``\>''
+`\>'
Match the empty string at the end of word.
-``\w''
- Match word constituent, it is a synonym for `[[:alnum:]]'.
+`\w'
+ Match word constituent, it is a synonym for `[_[:alnum:]]'.
-``\W''
- Match non-word constituent, it is a synonym for `[^[:alnum:]]'.
+`\W'
+ Match non-word constituent, it is a synonym for `[^_[:alnum:]]'.
-``\s''
+`\s'
Match whitespace, it is a synonym for `[[:space:]]'.
-``\S''
+`\S'
Match non-whitespace, it is a synonym for `[^[:space:]]'.
@@ -906,6 +948,8 @@
The caret `^' and the dollar sign `$' are meta-characters that
respectively match the empty string at the beginning and end of a line.
+They are termed "anchors", since they force the match to be "anchored"
+to beginning or end of a line, respectively.
3.5 Back-references and Subexpressions
======================================
@@ -916,7 +960,7 @@
with alternation, if the group does not participate in the match then
the back-reference makes the whole match fail. For example, `a(.)|b\1'
will not match `ba'. When multiple regular expressions are given with
-`-e' or from a file (`-f file'), back-references are local to each
+`-e' or from a file (`-f FILE'), back-references are local to each
expression.
3.6 Basic vs Extended Regular Expressions
@@ -935,7 +979,7 @@
`{' is not special if it would be the start of an invalid interval
specification. For example, the command `grep -E '{1'' searches for
the two-character string `{1' instead of reporting a syntax error in
-the regular expression. POSIX.2 allows this behavior as an extension,
+the regular expression. POSIX allows this behavior as an extension,
but portable scripts should avoid it.
4 Usage
@@ -974,12 +1018,10 @@
This differs from the command:
- grep -rH 'hello' *.c
+ grep -H 'hello' *.c
which merely looks for `hello' in all files in the current
- directory whose names end in `.c'. Here the `-r' is probably
- unnecessary, as recursion occurs only in the unlikely event that
- one of `.c' files is a directory. The `find ...' command line
+ directory whose names end in `.c'. The `find ...' command line
above is more similar to the command:
grep -rH --include='*.c' 'hello' /home/gigi
@@ -1052,26 +1094,38 @@
contain no matching lines, use the `-L' or `--files-without-match'
option.
- 10. I can do OR with `|', but what about AND?
+ 10. I can do "OR" with `|', but what about "AND"?
grep 'paul' /etc/motd | grep 'franc,ois'
finds all lines that contain both `paul' and `franc,ois'.
- 11. How can I search in both standard input and in files?
+ 11. Why does the empty pattern match every input line?
+
+ The `grep' command searches for lines that contain strings that
+ match a pattern. Every line contains the empty string, so an
+ empty pattern causes `grep' to find a match on each line. It is
+ not the only such pattern: `^', `$', `.*', and many other patterns
+ cause `grep' to match every line.
+
+ To match empty lines, use the pattern `^$'. To match blank lines,
+ use the pattern `^[[:blank:]]*$'. To match no lines at all, use
+ the command `grep -f /dev/null'.
+
+ 12. How can I search in both standard input and in files?
Use the special file name `-':
cat /etc/passwd | grep 'alain' - /etc/motd
- 12. How to express palindromes in a regular expression?
+ 13. How to express palindromes in a regular expression?
It can be done by using back-references; for example, a palindrome
of 4 characters can be written with a BRE:
grep -w -e '\(.\)\(.\).\2\1' file
- It matches the word "radar" or "civic".
+ It matches the word "radar" or "civic."
Guglielmo Bondioni proposed a single RE that finds all palindromes
up to 19 characters long using 9 subexpressions and
@@ -1082,7 +1136,7 @@
Note this is done by using GNU ERE extensions; it might not be
portable to other implementations of `grep'.
- 13. Why is this back-reference failing?
+ 14. Why is this back-reference failing?
echo 'ba' | grep -E '(a)\1|b\1'
@@ -1093,7 +1147,7 @@
match if the first alternate has matched--making the second one
superfluous.)
- 14. How can I match across lines?
+ 15. How can I match across lines?
Standard grep cannot do this, as it is fundamentally line-based.
Therefore, merely using the `[:space:]' character class does not
@@ -1115,7 +1169,7 @@
before giving it to `grep', or turn to `awk', `sed', `perl', or
many other utilities that are designed to operate across lines.
- 15. What do `grep', `fgrep', and `egrep' stand for?
+ 16. What do `grep', `fgrep', and `egrep' stand for?
The name `grep' comes from the way line editing was done on Unix.
For example, `ed' uses the following syntax to print a list of
@@ -1149,14 +1203,16 @@
6 Copying
*********
-GNU grep is licensed under the GNU GPL, which makes it "free software".
+GNU `grep' is licensed under the GNU GPL, which makes it "free
+software".
The "free" in "free software" refers to liberty, not price. As some
GNU project advocates like to point out, think of "free speech" rather
than "free beer". In short, you have the right (freedom) to run and
-change grep and distribute it to other people, and--if you want--charge
-money for doing either. The important restriction is that you have to
-grant your recipients the same rights and impose the same restrictions.
+change `grep' and distribute it to other people, and--if you
+want--charge money for doing either. The important restriction is that
+you have to grant your recipients the same rights and impose the same
+restrictions.
This general method of licensing software is sometimes called "open
source". The GNU project prefers the term "free software" for reasons
@@ -1173,7 +1229,7 @@
Version 1.3, 3 November 2008
- Copyright (C) 2000-2002, 2007-2008, 2010-2011 Free Software
+ Copyright (C) 2000-2002, 2007-2008, 2010-2012 Free Software
Foundation, Inc.
`http://fsf.org/'
@@ -1655,240 +1711,240 @@
Index
*****
-*: See 3.1. (line 722)
-+: See 3.1. (line 725)
---after-context: See 2.1.5. (line 322)
---basic-regexp: See 2.4. (line 661)
---before-context: See 2.1.5. (line 326)
---binary: See 2.1.7. (line 438)
---binary-files: See 2.1.6. (line 364)
---byte-offset: See 2.1.4. (line 251)
+*: See 3.1. (line 759)
++: See 3.1. (line 762)
+--after-context: See 2.1.5. (line 326)
+--basic-regexp: See 2.4. (line 698)
+--before-context: See 2.1.5. (line 330)
+--binary: See 2.1.7. (line 457)
+--binary-files: See 2.1.6. (line 378)
+--byte-offset: See 2.1.4. (line 255)
--color: See 2.1.3. (line 158)
--colour: See 2.1.3. (line 158)
---context: See 2.1.5. (line 331)
+--context: See 2.1.5. (line 335)
--count: See 2.1.3. (line 152)
---devices: See 2.1.6. (line 378)
---directories: See 2.1.6. (line 385)
---exclude: See 2.1.6. (line 395)
---exclude-dir: See 2.1.6. (line 404)
---exclude-from: See 2.1.6. (line 400)
---extended-regexp: See 2.4. (line 666)
+--devices: See 2.1.6. (line 396)
+--directories: See 2.1.6. (line 403)
+--exclude: See 2.1.6. (line 413)
+--exclude-dir: See 2.1.6. (line 422)
+--exclude-from: See 2.1.6. (line 418)
+--extended-regexp: See 2.4. (line 703)
--file: See 2.1.2. (line 116)
--files-with-matches: See 2.1.3. (line 179)
--files-without-match: See 2.1.3. (line 173)
---fixed-strings: See 2.4. (line 671)
---group-separator: See 2.1.5. (line 334)
+--fixed-strings: See 2.4. (line 708)
+--group-separator: See 2.1.5. (line 338)
--help: See 2.1.1. (line 96)
--ignore-case: See 2.1.2. (line 123)
---include: See 2.1.6. (line 412)
---initial-tab: See 2.1.4. (line 282)
+--include: See 2.1.6. (line 430)
+--initial-tab: See 2.1.4. (line 286)
--invert-match: See 2.1.2. (line 129)
---label: See 2.1.4. (line 269)
---line-buffered: See 2.1.7. (line 427)
---line-number: See 2.1.4. (line 277)
+--label: See 2.1.4. (line 273)
+--line-buffered: See 2.1.7. (line 445)
+--line-number: See 2.1.4. (line 281)
--line-regexp: See 2.1.2. (line 143)
--max-count: See 2.1.3. (line 186)
---mmap: See 2.1.7. (line 431)
---no-filename: See 2.1.4. (line 264)
+--mmap: See 2.1.7. (line 449)
+--no-filename: See 2.1.4. (line 268)
--no-messages: See 2.1.3. (line 232)
---null: See 2.1.4. (line 302)
---null-data: See 2.1.7. (line 452)
+--null: See 2.1.4. (line 306)
+--null-data: See 2.1.7. (line 471)
--only-matching: See 2.1.3. (line 219)
---perl-regexp: See 2.4. (line 677)
+--perl-regexp: See 2.4. (line 714)
--quiet: See 2.1.3. (line 225)
---recursive: See 2.1.6. (line 418)
+--recursive: See 2.1.6. (line 436)
--regexp=PATTERN: See 2.1.2. (line 110)
--silent: See 2.1.3. (line 225)
---text: See 2.1.6. (line 360)
---unix-byte-offsets: See 2.1.4. (line 292)
+--text: See 2.1.6. (line 374)
+--unix-byte-offsets: See 2.1.4. (line 296)
--version: See 2.1.1. (line 101)
---with-filename: See 2.1.4. (line 259)
+--with-filename: See 2.1.4. (line 263)
--word-regexp: See 2.1.2. (line 134)
--a: See 2.1.6. (line 360)
--A: See 2.1.5. (line 322)
--B: See 2.1.5. (line 326)
--b: See 2.1.4. (line 251)
--C: See 2.1.5. (line 331)
+-a: See 2.1.6. (line 374)
+-A: See 2.1.5. (line 326)
+-B: See 2.1.5. (line 330)
+-b: See 2.1.4. (line 255)
+-C: See 2.1.5. (line 335)
-c: See 2.1.3. (line 152)
--d: See 2.1.6. (line 385)
--D: See 2.1.6. (line 378)
--E: See 2.4. (line 666)
+-d: See 2.1.6. (line 403)
+-D: See 2.1.6. (line 396)
+-E: See 2.4. (line 703)
-e: See 2.1.2. (line 110)
--F: See 2.4. (line 671)
+-F: See 2.4. (line 708)
-f: See 2.1.2. (line 116)
--G: See 2.4. (line 661)
--h: See 2.1.4. (line 264)
--H: See 2.1.4. (line 259)
+-G: See 2.4. (line 698)
+-h: See 2.1.4. (line 268)
+-H: See 2.1.4. (line 263)
-i: See 2.1.2. (line 123)
-l: See 2.1.3. (line 179)
-L: See 2.1.3. (line 173)
-m: See 2.1.3. (line 186)
--n: See 2.1.4. (line 277)
--NUM: See 2.1.5. (line 331)
+-n: See 2.1.4. (line 281)
+-NUM: See 2.1.5. (line 335)
-o: See 2.1.3. (line 219)
--P: See 2.4. (line 677)
+-P: See 2.4. (line 714)
-q: See 2.1.3. (line 225)
--r: See 2.1.6. (line 418)
+-r: See 2.1.6. (line 436)
-s: See 2.1.3. (line 232)
--T: See 2.1.4. (line 282)
--U: See 2.1.7. (line 438)
--u: See 2.1.4. (line 292)
+-T: See 2.1.4. (line 286)
+-U: See 2.1.7. (line 457)
+-u: See 2.1.4. (line 296)
-v: See 2.1.2. (line 129)
-V: See 2.1.1. (line 101)
-w: See 2.1.2. (line 134)
-x: See 2.1.2. (line 143)
-y: See 2.1.2. (line 123)
--z: See 2.1.7. (line 452)
--Z: See 2.1.4. (line 302)
-.: See 3.1. (line 716)
-?: See 3.1. (line 719)
-_N_GNU_nonoption_argv_flags_ environment variable:See 2.2. (line 628)
-after context: See 2.1.5. (line 322)
-alnum character class: See 3.2. (line 779)
-alpha character class: See 3.2. (line 782)
-alphabetic characters: See 3.2. (line 782)
-alphanumeric characters: See 3.2. (line 779)
-anchoring: See 3.4. (line 907)
-asterisk: See 3.1. (line 722)
-back-reference: See 3.5. (line 913)
-backslash: See 3.3. (line 873)
-basic regular expressions: See 3.6. (line 925)
-before context: See 2.1.5. (line 326)
-binary files: See 2.1.6. (line 360)
-binary files, MS-DOS/MS-Windows: See 2.1.7. (line 438)
-blank character class: See 3.2. (line 785)
-blank characters: See 3.2. (line 785)
-bn GREP_COLORS capability: See 2.2. (line 558)
-braces, first argument omitted: See 3.1. (line 734)
-braces, one argument: See 3.1. (line 728)
-braces, second argument omitted: See 3.1. (line 731)
-braces, two arguments: See 3.1. (line 737)
-bracket expression: See 3.2. (line 756)
-Bugs, known: See 5.1. (line 1142)
-bugs, reporting: See 5. (line 1134)
-byte offset: See 2.1.4. (line 251)
-byte offsets, on MS-DOS/MS-Windows: See 2.1.4. (line 292)
+-z: See 2.1.7. (line 471)
+-Z: See 2.1.4. (line 306)
+.: See 3.1. (line 753)
+?: See 3.1. (line 756)
+_N_GNU_nonoption_argv_flags_ environment variable:See 2.2. (line 663)
+after context: See 2.1.5. (line 326)
+alnum character class: See 3.2. (line 817)
+alpha character class: See 3.2. (line 822)
+alphabetic characters: See 3.2. (line 822)
+alphanumeric characters: See 3.2. (line 817)
+anchoring: See 3.4. (line 949)
+asterisk: See 3.1. (line 759)
+back-reference: See 3.5. (line 957)
+backslash: See 3.3. (line 915)
+basic regular expressions: See 3.6. (line 969)
+before context: See 2.1.5. (line 330)
+binary files: See 2.1.6. (line 374)
+binary files, MS-DOS/MS-Windows: See 2.1.7. (line 457)
+blank character class: See 3.2. (line 827)
+blank characters: See 3.2. (line 827)
+bn GREP_COLORS capability: See 2.2. (line 608)
+braces, first argument omitted: See 3.1. (line 771)
+braces, one argument: See 3.1. (line 765)
+braces, second argument omitted: See 3.1. (line 768)
+braces, two arguments: See 3.1. (line 774)
+bracket expression: See 3.2. (line 794)
+Bugs, known: See 5.1. (line 1196)
+bugs, reporting: See 5. (line 1188)
+byte offset: See 2.1.4. (line 255)
+byte offsets, on MS-DOS/MS-Windows: See 2.1.4. (line 296)
case insensitive search: See 2.1.2. (line 123)
-changing name of standard input: See 2.1.4. (line 269)
-character class: See 3.2. (line 756)
-character classes: See 3.2. (line 778)
-character type: See 2.2. (line 600)
-classes of characters: See 3.2. (line 778)
-cntrl character class: See 3.2. (line 788)
-context: See 2.1.5. (line 331)
-context lines, after match: See 2.1.5. (line 322)
-context lines, before match: See 2.1.5. (line 326)
-control characters: See 3.2. (line 788)
-copying: See 6. (line 1152)
+changing name of standard input: See 2.1.4. (line 273)
+character class: See 3.2. (line 794)
+character classes: See 3.2. (line 816)
+character type: See 2.2. (line 635)
+classes of characters: See 3.2. (line 816)
+cntrl character class: See 3.2. (line 830)
+context: See 2.1.5. (line 335)
+context lines, after match: See 2.1.5. (line 326)
+context lines, before match: See 2.1.5. (line 330)
+control characters: See 3.2. (line 830)
+copying: See 6. (line 1206)
counting lines: See 2.1.3. (line 152)
-cx GREP_COLORS capability: See 2.2. (line 511)
-default options environment variable: See 2.2. (line 474)
-device search: See 2.1.6. (line 378)
-digit character class: See 3.2. (line 793)
-digit characters: See 3.2. (line 793)
-directory search: See 2.1.6. (line 385)
-dot: See 3.1. (line 716)
-environment variables: See 2.2. (line 473)
-exclude directories: See 2.1.6. (line 404)
-exclude files: See 2.1.6. (line 395)
-exit status: See 2.3. (line 641)
-FAQ about grep usage: See 4. (line 955)
+cx GREP_COLORS capability: See 2.2. (line 559)
+default options environment variable: See 2.2. (line 515)
+device search: See 2.1.6. (line 396)
+digit character class: See 3.2. (line 835)
+digit characters: See 3.2. (line 835)
+directory search: See 2.1.6. (line 403)
+dot: See 3.1. (line 753)
+environment variables: See 2.2. (line 514)
+exclude directories: See 2.1.6. (line 422)
+exclude files: See 2.1.6. (line 413)
+exit status: See 2.3. (line 676)
+FAQ about grep usage: See 4. (line 999)
files which don't match: See 2.1.3. (line 173)
-fn GREP_COLORS capability: See 2.2. (line 548)
-graph character class: See 3.2. (line 796)
-graphic characters: See 3.2. (line 796)
-grep programs: See 2.4. (line 653)
-GREP_COLOR environment variable: See 2.2. (line 484)
-GREP_COLORS environment variable: See 2.2. (line 495)
-GREP_OPTIONS environment variable: See 2.2. (line 474)
-group separator: See 2.1.5. (line 334)
-hexadecimal digits: See 3.2. (line 819)
-highlight markers: See 2.2. (line 484)
+fn GREP_COLORS capability: See 2.2. (line 598)
+graph character class: See 3.2. (line 838)
+graphic characters: See 3.2. (line 838)
+grep programs: See 2.4. (line 688)
+GREP_COLOR environment variable: See 2.2. (line 532)
+GREP_COLORS environment variable: See 2.2. (line 543)
+GREP_OPTIONS environment variable: See 2.2. (line 515)
+group separator: See 2.1.5. (line 338)
+hexadecimal digits: See 3.2. (line 864)
+highlight markers: See 2.2. (line 532)
highlight, color, colour: See 2.1.3. (line 158)
-include files: See 2.1.6. (line 412)
-interval specifications: See 3.6. (line 929)
+include files: See 2.1.6. (line 430)
+interval specifications: See 3.6. (line 973)
invert matching: See 2.1.2. (line 129)
-LANG environment variable: See 2.2. (line 600)
-language of messages: See 2.2. (line 614)
-LC_ALL environment variable: See 2.2. (line 600)
-LC_COLLATE environment variable: See 2.2. (line 600)
-LC_CTYPE environment variable: See 2.2. (line 607)
-LC_MESSAGES environment variable: See 2.2. (line 614)
-line buffering: See 2.1.7. (line 427)
-line numbering: See 2.1.4. (line 277)
-ln GREP_COLORS capability: See 2.2. (line 553)
-lower character class: See 3.2. (line 799)
-lower-case letters: See 3.2. (line 799)
-match expression at most M times: See 3.1. (line 734)
-match expression at most once: See 3.1. (line 719)
-match expression from N to M times: See 3.1. (line 737)
-match expression N or more times: See 3.1. (line 731)
-match expression N times: See 3.1. (line 728)
-match expression one or more times: See 3.1. (line 725)
-match expression zero or more times: See 3.1. (line 722)
+LANG environment variable: See 2.2. (line 635)
+language of messages: See 2.2. (line 649)
+LC_ALL environment variable: See 2.2. (line 635)
+LC_COLLATE environment variable: See 2.2. (line 635)
+LC_CTYPE environment variable: See 2.2. (line 642)
+LC_MESSAGES environment variable: See 2.2. (line 649)
+line buffering: See 2.1.7. (line 445)
+line numbering: See 2.1.4. (line 281)
+ln GREP_COLORS capability: See 2.2. (line 603)
+lower character class: See 3.2. (line 841)
+lower-case letters: See 3.2. (line 841)
+match expression at most M times: See 3.1. (line 771)
+match expression at most once: See 3.1. (line 756)
+match expression from N to M times: See 3.1. (line 774)
+match expression N or more times: See 3.1. (line 768)
+match expression N times: See 3.1. (line 765)
+match expression one or more times: See 3.1. (line 762)
+match expression zero or more times: See 3.1. (line 759)
match the whole line: See 2.1.2. (line 143)
-matching basic regular expressions: See 2.4. (line 661)
-matching extended regular expressions: See 2.4. (line 666)
-matching fixed strings: See 2.4. (line 671)
-matching Perl regular expressions: See 2.4. (line 677)
+matching basic regular expressions: See 2.4. (line 698)
+matching extended regular expressions: See 2.4. (line 703)
+matching fixed strings: See 2.4. (line 708)
+matching Perl regular expressions: See 2.4. (line 714)
matching whole words: See 2.1.2. (line 134)
max-count: See 2.1.3. (line 186)
-mc GREP_COLORS capability: See 2.2. (line 541)
-memory mapped input: See 2.1.7. (line 431)
-message language: See 2.2. (line 614)
-ms GREP_COLORS capability: See 2.2. (line 534)
-MS-DOS/MS-Windows binary files: See 2.1.7. (line 438)
-MS-DOS/MS-Windows byte offsets: See 2.1.4. (line 292)
-mt GREP_COLORS capability: See 2.2. (line 526)
+mc GREP_COLORS capability: See 2.2. (line 590)
+memory mapped input: See 2.1.7. (line 449)
+message language: See 2.2. (line 649)
+ms GREP_COLORS capability: See 2.2. (line 582)
+MS-DOS/MS-Windows binary files: See 2.1.7. (line 457)
+MS-DOS/MS-Windows byte offsets: See 2.1.4. (line 296)
+mt GREP_COLORS capability: See 2.2. (line 574)
names of matching files: See 2.1.3. (line 179)
-national language support: See 2.2. (line 600)
-ne GREP_COLORS capability: See 2.2. (line 570)
-NLS: See 2.2. (line 600)
-no filename prefix: See 2.1.4. (line 264)
-numeric characters: See 3.2. (line 793)
+national language support: See 2.2. (line 635)
+ne GREP_COLORS capability: See 2.2. (line 620)
+NLS: See 2.2. (line 635)
+no filename prefix: See 2.1.4. (line 268)
+numeric characters: See 3.2. (line 835)
only matching: See 2.1.3. (line 219)
-palindromes: See 4. (line 1067)
+palindromes: See 4. (line 1121)
pattern from file: See 2.1.2. (line 116)
pattern list: See 2.1.2. (line 110)
-period: See 3.1. (line 716)
-plus sign: See 3.1. (line 725)
-POSIXLY_CORRECT environment variable: See 2.2. (line 619)
-print character class: See 3.2. (line 803)
+period: See 3.1. (line 753)
+plus sign: See 3.1. (line 762)
+POSIXLY_CORRECT environment variable: See 2.2. (line 654)
+print character class: See 3.2. (line 846)
print non-matching lines: See 2.1.2. (line 129)
-printable characters: See 3.2. (line 803)
-punct character class: See 3.2. (line 806)
-punctuation characters: See 3.2. (line 806)
-question mark: See 3.1. (line 719)
+printable characters: See 3.2. (line 846)
+punct character class: See 3.2. (line 849)
+punctuation characters: See 3.2. (line 849)
+question mark: See 3.1. (line 756)
quiet, silent: See 2.1.3. (line 225)
-range expression: See 3.2. (line 762)
-recursive search: See 2.1.6. (line 418)
-regular expressions: See 3. (line 691)
-return status: See 2.3. (line 641)
-rv GREP_COLORS capability: See 2.2. (line 520)
-searching directory trees: See 2.1.6. (line 395)
+range expression: See 3.2. (line 800)
+recursive search: See 2.1.6. (line 436)
+regular expressions: See 3. (line 728)
+return status: See 2.3. (line 676)
+rv GREP_COLORS capability: See 2.2. (line 568)
+searching directory trees: See 2.1.6. (line 413)
searching for a pattern: See 1. (line 55)
-sl GREP_COLORS capability: See 2.2. (line 503)
-space character class: See 3.2. (line 810)
-space characters: See 3.2. (line 810)
-subexpression: See 3.5. (line 913)
-suppress binary data: See 2.1.6. (line 360)
+sl GREP_COLORS capability: See 2.2. (line 551)
+space character class: See 3.2. (line 854)
+space characters: See 3.2. (line 854)
+subexpression: See 3.5. (line 957)
+suppress binary data: See 2.1.6. (line 374)
suppress error messages: See 2.1.3. (line 232)
-tab-aligned content lines: See 2.1.4. (line 282)
-translation of message language: See 2.2. (line 614)
-upper character class: See 3.2. (line 815)
-upper-case letters: See 3.2. (line 815)
+tab-aligned content lines: See 2.1.4. (line 286)
+translation of message language: See 2.2. (line 649)
+upper character class: See 3.2. (line 859)
+upper-case letters: See 3.2. (line 859)
usage summary, printing: See 2.1.1. (line 96)
-usage, examples: See 4. (line 944)
-using grep, Q&A: See 4. (line 955)
-variants of gerp: See 2.4. (line 653)
+usage, examples: See 4. (line 988)
+using grep, Q&A: See 4. (line 999)
+variants of grep: See 2.4. (line 688)
version, printing: See 2.1.1. (line 101)
-whitespace characters: See 3.2. (line 810)
-with filename prefix: See 2.1.4. (line 259)
-xdigit character class: See 3.2. (line 819)
-xdigit class: See 3.2. (line 819)
-zero-terminated file names: See 2.1.4. (line 302)
-zero-terminated lines: See 2.1.7. (line 452)
-{,M}: See 3.1. (line 734)
-{N,M}: See 3.1. (line 737)
-{N,}: See 3.1. (line 731)
-{N}: See 3.1. (line 728)
+whitespace characters: See 3.2. (line 854)
+with filename prefix: See 2.1.4. (line 263)
+xdigit character class: See 3.2. (line 864)
+xdigit class: See 3.2. (line 864)
+zero-terminated file names: See 2.1.4. (line 306)
+zero-terminated lines: See 2.1.7. (line 471)
+{,M}: See 3.1. (line 771)
+{N,M}: See 3.1. (line 774)
+{N,}: See 3.1. (line 768)
+{N}: See 3.1. (line 765)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Changes to grep/manual/grep.txt,v,
Jim Meyering <=