help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Doing a file filter with grep


From: Eli Zaretskii
Subject: Re: Doing a file filter with grep
Date: Fri, 26 Jan 2007 11:29:56 +0200

> From: "RealityMonster" <jan.sacharuk@gmail.com>
> Date: 25 Jan 2007 14:37:45 -0800
> 
> So I've been getting find and grep working on my WinXP system with
> emacs. I can finally properly search for files and search in files for
> the things that I want. I'd like, however, to put a file filter on it,
> so I can search just through .h files or .cpp files.
> 
> On the command line, I'd do something like this:
> 
> grep -r Pattern `find . -name *.cpp`

After typing "M-x grep RET" inside Emacs, make the Grep command be
this:

    grep -r Pattern . --include="*.cpp"

That's it! no need to use `find'.




reply via email to

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