the standard & extended RE's don't find find NUL's:
dd if=/dev/zero of=zeros bs=4k count=1
command grep -Pq '\000\000' zeros && echo "badness"
badness
command grep -Eq '\000\000' zeros && echo "badness"
command grep -Gq '\000\000' zeros && echo "badness"
command grep -q '\000\000' zeros &
/usr/bin/grep --color=auto -I -D skip -d skip -exclude-from=EX -P -r xrm
/usr/bin/grep: xrm: No such file or directory
/usr/bin/grep --version
/usr/bin/grep (GNU grep) 2.21.31-adf9
How did 'xrm' become a file name?
It happened after I added the "-exclude-from=EX -P -r"
to an alias... but
Paul Eggert wrote:
Because you omitted a "-" before "-exclude", and that caused your
pattern to be 'xclude-from=EX'.
Dang -- confused w/the file find util, which I was also using...*sigh*...
_Thanks_ & sorry for the bother... I had a feeling it
was something I did, (note I didn't call it a
I've used grep to search through my mbox-format emails for decades, but
I've run into a case where it seems to be ignore a text mailbox
because, I guess, it thinks it is "binary" (I think ignoring binary
is a default in my aliases file).
I used:
grep -Pr 'Game:\s+NCSOFT' *
and it ignored a m
nly
files. It's summary says:
grep, egrep, fgrep - print lines matching a pattern
which it does not do. It doesn't say "print lines matching
a pattern only from POSIX text files.
Eric Blake wrote:
tag 30326 notabug
thanks
On 02/02/2018 01:30 PM, L. A. Walsh wrote:
I'
Paul Eggert wrote:
On 02/02/2018 12:09 PM, L A Walsh wrote:
Grep was able to find text strings in mboxes without a POSIX
definition telling it that it was "broken".
It's not a question of POSIX telling us what to do. It's a question of
what is a good thing for
Paul Eggert wrote:
On 02/02/2018 03:16 PM, L A Walsh wrote:
It also used to be the default.
Single-byte locales also used to be the default. Times have changed, and
things have gotten more complicated. We don't change default behavior
for no reason, but we also don'
Paul Eggert wrote:
On 02/02/2018 03:30 PM, L A Walsh wrote:
> most computer files (vs. user-files) are still single-byte.
That's because so many of them are ASCII. But ASCII files are not the
issue here. grep's behavior hasn't changed when operating on ASCII files
in ty
On 5/10/2019 3:49 PM, Miro Kropáček wrote:
> Hi,
>
> I found this today by accident - it seems that grep's ./configure
> doesn't work with so called minimal bash (enabled in bash's configure
> via --enable-minimal-config).
>
> One can verify that not only by the failed ./configure process but
> als
On 2021/03/19 14:04, Paul Eggert wrote:
On 3/19/21 8:22 AM, Jaroslav Skarvada wrote:
Please consider adding PCRE2 support.
Patches would be welcome. As I understand it, they're not trivial.
---
What are differences from 1->2 and wondering why they are
so non-trivial? I guess th
On 2023/05/31 17:38, Paul Eggert wrote:
On 2023-05-30 14:01, g...@tlinx.org wrote:
Why is finding the desired text in a binary file not a "positive finding"
as it is in a text file?
But it is a positive finding. Grep exits with zero status, which is a
positive result.
There is n
On 2023/06/01 14:18, Paul Eggert wrote:
On 6/1/23 07:50, L A Walsh wrote:
I thought binary files were skipped, by default
They're not. The '--binary-files=without-match' option enables that
behavior. With that option, this issue doesn't come up.
if they want to
On 2023/06/02 15:17, Paul Eggert wrote:
Yes, and grep does that now. The only issue is whether to send that
summary information to stdout or to stderr.
---
If you want to send all matches from all files to one or the other, that's
fine -- the point is to be consistent: sending matches to on
13 matches
Mail list logo