Re: Using grep (or some other tool) to highlight, instead of grepping?

Ralf Wildenhues <[email protected]>
Newsgroups gmane.comp.gnu.utils
Organization Department of Numerical Simulation, University of Bonn
Message-ID <[email protected]>
* Ralf Wildenhues wrote on Fri, Aug 15, 2008 at 05:48:23AM CEST:
> 
> I guess if you translate your basic regex into an extended one, then you
> should be able to use egrep/grep -E, and also match end-of-line:
>   grep -E --color=auto 'foo|$'

Erm, or just
   grep --color=auto -e foo -e '$'

> Hmm.  Using ^ instead of $ destroys the coloring, that looks like a bug
> (Debian package grep-2.5.1.ds2-6).

Seems to have been fixed since upstream.

Cheers,
Ralf
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.