Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 18 Jan 2000 18:04:44 +0200
From:      Ruslan Ermilov <ru@FreeBSD.org>
To:        Ben Rosengart <ben@skunk.org>
Cc:        current@FreeBSD.org
Subject:   Re: HEADS UP: grep 2.4a is now in the tree
Message-ID:  <20000118180444.A58470@relay.ucb.crimea.ua>
In-Reply-To: <Pine.BSF.4.21.0001181100220.64214-100000@penelope.skunk.org>; from Ben Rosengart on Tue, Jan 18, 2000 at 11:00:43AM -0500
References:  <20000118120001.A60039@relay.ucb.crimea.ua> <Pine.BSF.4.21.0001181100220.64214-100000@penelope.skunk.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Jan 18, 2000 at 11:00:43AM -0500, Ben Rosengart wrote:
> On Tue, 18 Jan 2000, Ruslan Ermilov wrote:
> 
> >   --binary-files='text' treats binary files as text
> >       (equivalent to -a or --text).
> 
> So "-a" now does the opposite of what it used to do?
> 
Not exactly.

A stock grep 2.0 did not distinguish between binary and text files.
So we (FreeBSD) added -a option, which caused grep to skip binary
files.

A stock grep 2.3 intoduced a stock -a option.  By default, grep 2.3
prints a one-line message "Binary file FOO matches" (if it really
matches).

Grep 2.4 introduces a --binary-files option, which could be used
to either 1) print a one-line message, if files matches; 2) treat
the binary files as text files; 3) skip binary files.

The equivalent to the old -a option is --binary-files=without-match.
If you want this by default, you can hardcode it in GREP_OPTIONS
environment variable.

For a full story, see src/gnu/usr.bin/grep/NEWS.


Cheers,
-- 
Ruslan Ermilov		Sysadmin and DBA of the
ru@ucb.crimea.ua	United Commercial Bank,
ru@FreeBSD.org		FreeBSD committer,
+380.652.247.647	Simferopol, Ukraine

http://www.FreeBSD.org	The Power To Serve
http://www.oracle.com	Enabling The Information Age


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000118180444.A58470>