NEWS revision 56915
154359SrobertoVersion 2.4.1
254359Sroberto
354359Sroberto  - If the final byte of an input file is not a newline, grep now silently
454359Sroberto    supplies one.
554359Sroberto
654359Sroberto  - The new option --binary-files=TYPE makes grep assume that a binary input
754359Sroberto    file is of type TYPE.
854359Sroberto    --binary-files='binary' (the default) outputs a 1-line summary of matches.
954359Sroberto    --binary-files='without-match' assumes binary files do not match.
1082498Sroberto    --binary-files='text' treats binary files as text
1182498Sroberto	(equivalent to the -a or --text option).
1282498Sroberto
1382498Sroberto  - New option -I; equivalent to --binary-files='without-match'.
1482498Sroberto
1582498SrobertoVersion 2.4:
1654359Sroberto
1754359Sroberto  - egrep is now equivalent to `grep -E' as required by POSIX,
1854359Sroberto    removing a longstanding source of confusion and incompatibility.
1954359Sroberto    `grep' is now more forgiving about stray `{'s, for backward
2054359Sroberto    compatibility with traditional egrep.
2154359Sroberto
2254359Sroberto  - The lower bound of an interval is not optional.
2356746Sroberto    You must use an explicit zero, e.g. `x{0,10}' instead of `x{,10}'.
2454359Sroberto    (The old documentation incorrectly claimed that it was optional.)
2554359Sroberto
2654359Sroberto  - The --revert-match option has been renamed to --invert-match.
2754359Sroberto
28285612Sdelphij  - The --fixed-regexp option has been renamed to --fixed-string.
29285612Sdelphij
30285612Sdelphij  - New option -H or --with-filename.
31285612Sdelphij
32285612Sdelphij  - New option --mmap.  By default, GNU grep now uses read instead of mmap.
33285612Sdelphij    This is faster on some hosts, and is safer on all.
34285612Sdelphij
3554359Sroberto  - The new option -z or --null-data causes `grep' to treat a zero byte
36285612Sdelphij    (the ASCII NUL character) as a line terminator in input data, and
37285612Sdelphij    to treat newlines as ordinary data.
38285612Sdelphij
39285612Sdelphij  - The new option -Z or --null causes `grep' to output a zero byte
40285612Sdelphij    instead of the normal separator after a file name.
41285612Sdelphij
42285612Sdelphij  - These two options can be used with commands like `find -print0',
4354359Sroberto    `perl -0', `sort -z', and `xargs -0' to process arbitrary file names,
4454359Sroberto    even those that contain newlines.
4554359Sroberto
4654359Sroberto  - The environment variable GREP_OPTIONS specifies default options;
47285612Sdelphij    e.g. GREP_OPTIONS='--directories=skip' reestablishes grep 2.1's
4854359Sroberto    behavior of silently skipping directories.
49285612Sdelphij
50285612Sdelphij  - You can specify a matcher multiple times without error, e.g.
51285612Sdelphij    `grep -E -E' or `fgrep -F'.  It is still an error to specify
52285612Sdelphij    conflicting matchers.
53285612Sdelphij
54285612Sdelphij  - -u and -U are now allowed on non-DOS hosts, and have no effect.
55285612Sdelphij
56285612Sdelphij  - Modifications of the tests scripts to go around the "Broken Pipe"
57285612Sdelphij    errors from bash. See Bash FAQ.
58285612Sdelphij
5954359Sroberto  - New option -r or --recursive or --directories=recurse.
6054359Sroberto    (This option was also in grep 2.3, but wasn't announced here.)
6154359Sroberto
6254359Sroberto  - --without-included-regex disable, was causing bogus reports .i.e
6354359Sroberto    doing more harm then good.
6454359Sroberto
6554359SrobertoVersion 2.3:
6654359Sroberto
6754359Sroberto  - When searching a binary file FOO, grep now just reports
6854359Sroberto    `Binary file FOO matches' instead of outputting binary data.
6954359Sroberto    This is typically more useful than the old behavior,
7054359Sroberto    and it is also more consistent with other utilities like `diff'.
7154359Sroberto    A file is considered to be binary if it contains a NUL (i.e. zero) byte.
72285612Sdelphij
7354359Sroberto    The new -a or --text option causes `grep' to assume that all
74285612Sdelphij    input is text.  (This option has the same meaning as with `diff'.)
75285612Sdelphij    Use it if you want binary data in your output.
76285612Sdelphij
77285612Sdelphij  - `grep' now searches directories just like ordinary files; it no longer
7854359Sroberto    silently skips directories.  This is the traditional behavior of
79285612Sdelphij    Unix text utilities (in particular, of traditional `grep').
8054359Sroberto    Hence `grep PATTERN DIRECTORY' should report
81285612Sdelphij    `grep: DIRECTORY: Is a directory' on hosts where the operating system
82285612Sdelphij    does not permit programs to read directories directly, and
83285612Sdelphij    `grep: DIRECTORY: Binary file matches' (or nothing) otherwise.
8454359Sroberto
85285612Sdelphij    The new -d ACTION or --directories=ACTION option affects directory handling.
86285612Sdelphij    `-d skip' causes `grep' to silently skip directories, as in grep 2.1;
87285612Sdelphij    `-d read' (the default) causes `grep' to read directories if possible,
88285612Sdelphij    as in earlier versions of grep.
89285612Sdelphij
90285612Sdelphij  - The MS-DOS and Microsoft Windows ports now behave identically to the
91285612Sdelphij    GNU and Unix ports with respect to binary files and directories.
92285612Sdelphij
93285612SdelphijVersion 2.2:
9454359Sroberto
95285612SdelphijBug fix release.
9654359Sroberto
97285612Sdelphij  - Status error number fix.
98285612Sdelphij  - Skipping directories removed.
99285612Sdelphij  - Many typos fix.
100285612Sdelphij  - -f /dev/null fix(not to consider as an empty pattern).
101285612Sdelphij  - Checks for wctype/wchar.
102285612Sdelphij  - -E was using the wrong matcher fix.
103285612Sdelphij  - bug in regex char class fix
104285612Sdelphij  - Fixes for DJGPP
105285612Sdelphij
106285612SdelphijVersion 2.1:
107285612Sdelphij
108285612SdelphijThis is a bug fix release(see Changelog) i.e. no new features.
109285612Sdelphij
110285612Sdelphij  - More compliance to GNU standard.
111285612Sdelphij  - Long options.
112285612Sdelphij  - Internationalisation.
113285612Sdelphij  - Use automake/autoconf.
114285612Sdelphij  - Directory hierarchy change.
115285612Sdelphij  - Sigvec with -e on Linux corrected.
116285612Sdelphij  - Sigvec with -f on Linux corrected.
117285612Sdelphij  - Sigvec with the mmap() corrected.
118285612Sdelphij  - Bug in kwset corrected.
11954359Sroberto  - -q, -L and -l stop on first match.
12054359Sroberto  - New and improve regex.[ch] from Ulrich Drepper.
121285612Sdelphij  - New and improve dfa.[ch] from Arnold Robbins.
122285612Sdelphij  - Prototypes for over zealous C compiler.
123285612Sdelphij  - Not scanning a file, if it's a directory
124285612Sdelphij    (cause problems on Sun).
125285612Sdelphij  - Ported to MS-DOS/MS-Windows with DJGPP tools.
12654359Sroberto
12754359SrobertoSee Changelog for the full story and proper credits.
12854359Sroberto
12954359SrobertoVersion 2.0:
13054359Sroberto
13154359SrobertoThe most important user visible change is that egrep and fgrep have
13254359Srobertodisappeared as separate programs into the single grep program mandated
13354359Srobertoby POSIX 1003.2.  New options -G, -E, and -F have been added,
134132451Srobertoselecting grep, egrep, and fgrep behavior respectively.  For
135182007Srobertocompatibility with historical practice, hard links named egrep and
136182007Srobertofgrep are also provided.  See the manual page for details.
137182007Sroberto
138182007SrobertoIn addition, the regular expression facilities described in Posix
139285612Sdelphijdraft 11.2 are now supported, except for internationalization features
140182007Srobertorelated to locale-dependent collating sequence information.
141285612Sdelphij
142285612SdelphijThere is a new option, -L, which is like -l except it lists
143285612Sdelphijfiles which don't contain matches.  The reason this option was
144285612Sdelphijadded is because '-l -v' doesn't do what you expect.
145285612Sdelphij
14654359SrobertoPerformance has been improved; the amount of improvement is platform
14754359Srobertodependent, but (for example) grep 2.0 typically runs at least 30% faster
14854359Srobertothan grep 1.6 on a DECstation using the MIPS compiler.  Where possible,
14954359Srobertogrep now uses mmap() for file input; on a Sun 4 running SunOS 4.1 this
15082498Srobertomay cut system time by as much as half, for a total reduction in running
15154359Srobertotime by nearly 50%.  On machines that don't use mmap(), the buffering
15254359Srobertocode has been rewritten to choose more favorable alignments and buffer
15354359Srobertosizes for read().
154132451Sroberto
15556746SrobertoPortability has been substantially cleaned up, and an automatic
15654359Srobertoconfigure script is now provided.
15754359Sroberto
15854359SrobertoThe internals have changed in ways too numerous to mention.
159285612SdelphijPeople brave enough to reuse the DFA matcher in other programs
160285612Sdelphijwill now have their bravery amply "rewarded", for the interface
161285612Sdelphijto that file has been completely changed.  Some changes were
16254359Srobertonecessary to track the evolution of the regex package, and since
163285612SdelphijI was changing it anyway I decided to do a general cleanup.
164285612Sdelphij