unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* How to set the default file pattern for the igrep-find command in c++-mode
@ 2007-10-22  7:09 Avi
  0 siblings, 0 replies; 2+ messages in thread
From: Avi @ 2007-10-22  7:09 UTC (permalink / raw)
  To: help-gnu-emacs


Hi,
I'm looking for a way to set the default file pattern for the igrep-
find command.
In c-mode, the following line defines a multiple file pattern in one
string:
(put 'igrep-files-default 'c-mode (lambda () "*.[ch]"))
This captures both *.h and *.c files
I am looking for something similar for the c++-mode.
I have tried the following line:
(put 'igrep-files-default 'c++-mode (lambda () "*.[cpp|h]"))
but this is parsed as *.c *.p *.h (rather than *.cpp *.h)
Another option is to customize the read-multiple-files variable to
true. This allows to insert multiple patterns but requires interaction
(every pattern needs to be specified and confirmed by clicking on the
"Enter" key.

Thanks,
Avner

^ permalink raw reply	[flat|nested] 2+ messages in thread

* How to set the default file pattern for the igrep-find command in c++-mode
@ 2007-10-22  7:09 Avi
  0 siblings, 0 replies; 2+ messages in thread
From: Avi @ 2007-10-22  7:09 UTC (permalink / raw)
  To: help-gnu-emacs


Hi,
I'm looking for a way to set the default file pattern for the igrep-
find command.
In c-mode, the following line defines a multiple file pattern in one
string:
(put 'igrep-files-default 'c-mode (lambda () "*.[ch]"))
This captures both *.h and *.c files
I am looking for something similar for the c++-mode.
I have tried the following line:
(put 'igrep-files-default 'c++-mode (lambda () "*.[cpp|h]"))
but this is parsed as *.c *.p *.h (rather than *.cpp *.h)
Another option is to customize the read-multiple-files variable to
true. This allows to insert multiple patterns but requires interaction
(every pattern needs to be specified and confirmed by clicking on the
"Enter" key.

Thanks,
Avner

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-10-22  7:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-10-22  7:09 How to set the default file pattern for the igrep-find command in c++-mode Avi
  -- strict thread matches above, loose matches on Subject: below --
2007-10-22  7:09 Avi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).