Grep: Add DragonFly README files
[dragonfly.git] / gnu / usr.bin / grep / NEWS
1 Version 2.4.1
2
3   - If the final byte of an input file is not a newline, grep now silently
4     supplies one.
5
6   - The new option --binary-files=TYPE makes grep assume that a binary input
7     file is of type TYPE.
8     --binary-files='binary' (the default) outputs a 1-line summary of matches.
9     --binary-files='without-match' assumes binary files do not match.
10     --binary-files='text' treats binary files as text
11         (equivalent to the -a or --text option).
12
13   - New option -I; equivalent to --binary-files='without-match'.
14
15 Version 2.4:
16
17   - egrep is now equivalent to `grep -E' as required by POSIX,
18     removing a longstanding source of confusion and incompatibility.
19     `grep' is now more forgiving about stray `{'s, for backward
20     compatibility with traditional egrep.
21
22   - The lower bound of an interval is not optional.
23     You must use an explicit zero, e.g. `x{0,10}' instead of `x{,10}'.
24     (The old documentation incorrectly claimed that it was optional.)
25
26   - The --revert-match option has been renamed to --invert-match.
27
28   - The --fixed-regexp option has been renamed to --fixed-string.
29
30   - New option -H or --with-filename.
31
32   - New option --mmap.  By default, GNU grep now uses read instead of mmap.
33     This is faster on some hosts, and is safer on all.
34
35   - The new option -z or --null-data causes `grep' to treat a zero byte
36     (the ASCII NUL character) as a line terminator in input data, and
37     to treat newlines as ordinary data.
38
39   - The new option -Z or --null causes `grep' to output a zero byte
40     instead of the normal separator after a file name.
41
42   - These two options can be used with commands like `find -print0',
43     `perl -0', `sort -z', and `xargs -0' to process arbitrary file names,
44     even those that contain newlines.
45
46   - The environment variable GREP_OPTIONS specifies default options;
47     e.g. GREP_OPTIONS='--directories=skip' reestablishes grep 2.1's
48     behavior of silently skipping directories.
49
50   - You can specify a matcher multiple times without error, e.g.
51     `grep -E -E' or `fgrep -F'.  It is still an error to specify
52     conflicting matchers.
53
54   - -u and -U are now allowed on non-DOS hosts, and have no effect.
55
56   - Modifications of the tests scripts to go around the "Broken Pipe"
57     errors from bash. See Bash FAQ.
58
59   - New option -r or --recursive or --directories=recurse.
60     (This option was also in grep 2.3, but wasn't announced here.)
61
62   - --without-included-regex disable, was causing bogus reports .i.e
63     doing more harm then good.
64
65 Version 2.3:
66
67   - When searching a binary file FOO, grep now just reports
68     `Binary file FOO matches' instead of outputting binary data.
69     This is typically more useful than the old behavior,
70     and it is also more consistent with other utilities like `diff'.
71     A file is considered to be binary if it contains a NUL (i.e. zero) byte.
72
73     The new -a or --text option causes `grep' to assume that all
74     input is text.  (This option has the same meaning as with `diff'.)
75     Use it if you want binary data in your output.
76
77   - `grep' now searches directories just like ordinary files; it no longer
78     silently skips directories.  This is the traditional behavior of
79     Unix text utilities (in particular, of traditional `grep').
80     Hence `grep PATTERN DIRECTORY' should report
81     `grep: DIRECTORY: Is a directory' on hosts where the operating system
82     does not permit programs to read directories directly, and
83     `grep: DIRECTORY: Binary file matches' (or nothing) otherwise.
84
85     The new -d ACTION or --directories=ACTION option affects directory handling.
86     `-d skip' causes `grep' to silently skip directories, as in grep 2.1;
87     `-d read' (the default) causes `grep' to read directories if possible,
88     as in earlier versions of grep.
89
90   - The MS-DOS and Microsoft Windows ports now behave identically to the
91     GNU and Unix ports with respect to binary files and directories.
92
93 Version 2.2:
94
95 Bug fix release.
96
97   - Status error number fix.
98   - Skipping directories removed.
99   - Many typos fix.
100   - -f /dev/null fix(not to consider as an empty pattern).
101   - Checks for wctype/wchar.
102   - -E was using the wrong matcher fix.
103   - bug in regex char class fix
104   - Fixes for DJGPP
105
106 Version 2.1:
107
108 This is a bug fix release(see Changelog) i.e. no new features.
109
110   - More compliance to GNU standard.
111   - Long options.
112   - Internationalisation.
113   - Use automake/autoconf.
114   - Directory hierarchy change.
115   - Sigvec with -e on Linux corrected.
116   - Sigvec with -f on Linux corrected.
117   - Sigvec with the mmap() corrected.
118   - Bug in kwset corrected.
119   - -q, -L and -l stop on first match.
120   - New and improve regex.[ch] from Ulrich Drepper.
121   - New and improve dfa.[ch] from Arnold Robbins.
122   - Prototypes for over zealous C compiler.
123   - Not scanning a file, if it's a directory
124     (cause problems on Sun).
125   - Ported to MS-DOS/MS-Windows with DJGPP tools.
126
127 See Changelog for the full story and proper credits.
128
129 Version 2.0:
130
131 The most important user visible change is that egrep and fgrep have
132 disappeared as separate programs into the single grep program mandated
133 by POSIX 1003.2.  New options -G, -E, and -F have been added,
134 selecting grep, egrep, and fgrep behavior respectively.  For
135 compatibility with historical practice, hard links named egrep and
136 fgrep are also provided.  See the manual page for details.
137
138 In addition, the regular expression facilities described in Posix
139 draft 11.2 are now supported, except for internationalization features
140 related to locale-dependent collating sequence information.
141
142 There is a new option, -L, which is like -l except it lists
143 files which don't contain matches.  The reason this option was
144 added is because '-l -v' doesn't do what you expect.
145
146 Performance has been improved; the amount of improvement is platform
147 dependent, but (for example) grep 2.0 typically runs at least 30% faster
148 than grep 1.6 on a DECstation using the MIPS compiler.  Where possible,
149 grep now uses mmap() for file input; on a Sun 4 running SunOS 4.1 this
150 may cut system time by as much as half, for a total reduction in running
151 time by nearly 50%.  On machines that don't use mmap(), the buffering
152 code has been rewritten to choose more favorable alignments and buffer
153 sizes for read().
154
155 Portability has been substantially cleaned up, and an automatic
156 configure script is now provided.
157
158 The internals have changed in ways too numerous to mention.
159 People brave enough to reuse the DFA matcher in other programs
160 will now have their bravery amply "rewarded", for the interface
161 to that file has been completely changed.  Some changes were
162 necessary to track the evolution of the regex package, and since
163 I was changing it anyway I decided to do a general cleanup.