bug-gnu-utils
[Top][All Lists]
Advanced

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

Re: grep


From: Stepan Kasal
Subject: Re: grep
Date: Tue, 25 Jun 2002 15:41:38 +0000 (UTC)
User-agent: slrn/0.9.6.2 (Linux)

Hallo,
        the think you report is not a bug.

On Tue, 25 Jun 2002 17:01:10 +0200, Holger Lehmann wrote:
> $ grep '^\b' < test.txt > backspace.txt
> 
> But to my surprise it contained the lines without backspaces ....

try "info grep" and you'll find out that \b marks the empty string
at word boundary, so this matches lines like

word
1

and doesn't match lines like

@word
  word
^Hword

To achive what you want, I was able to run this on bash commandline:

        grep '^^H' filename

(To enter that ^H, I typed Ctrl-V and then Ctrl-H.)
But things depend on shell and terminal configuration.  You may try
your editor or vi to edit a script.

Thank you for writing the bug report anyway,

                Stepan Kasal





reply via email to

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