[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: unexpected match

From: Dave B
Subject: Re: unexpected match
Date: Fri, 05 Jun 2009 20:40:36 +0200
User-agent: Thunderbird (X11/20090527)

Jonathan Blanchard wrote:
> Hi,
> While using file as patterns to grep, some unexpected match occurs.
> In this two files below no line is similar but the flowing command return
> one match.
>>> grep -f .tmp_check1 .tmp_check2
> address@hidden
>>> grep -V
> grep (grep de GNU) 2.5.1
> Copyright 1988, 1992-1999, 2000, 2001 Free Software Foundation, Inc.

Not unexpected.tmp_check1 contains address@hidden, which of course matches
address@hidden in tmp_check2. Try doing

grep 'address@hidden' tmp_file2

and see that it matches a line in tmp_check2.

What you want here is probably the -x option.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]