unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* How to avoid  /dev/null at the end of grep-command
@ 2007-03-02  9:20 al.coyote
  2007-03-02 13:49 ` Eli Zaretskii
       [not found] ` <mailman.334.1172843352.7795.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 4+ messages in thread
From: al.coyote @ 2007-03-02  9:20 UTC (permalink / raw)
  To: help-gnu-emacs

Hello,

When running M-x grep, emacs adds a /dev/null after the list of files.
That's a secure idea most of the times, but when running complex grep
command, this is annoying. For example something like:

grep -n -A2 my_function  *  |  grep -n '\n'

won't work, as emacs will transform this command as

grep -n -A2 my_function  *  |  grep -n '\n' /dev/null

I can add /dev/stdin to the second grep, but the file name will be
garbaged too.

Setting a default grep command does not solve the problem.

Any solution to avoid the /dev/null, without modifying compile.el ?

Thanks in advance.

Al

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

end of thread, other threads:[~2007-03-03 10:26 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-03-02  9:20 How to avoid /dev/null at the end of grep-command al.coyote
2007-03-02 13:49 ` Eli Zaretskii
     [not found] ` <mailman.334.1172843352.7795.help-gnu-emacs@gnu.org>
2007-03-03  8:09   ` al.coyote
2007-03-03 10:26     ` Eli Zaretskii

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).