From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: al.coyote@gmail.com Newsgroups: gmane.emacs.help Subject: How to avoid /dev/null at the end of grep-command Date: 2 Mar 2007 01:20:35 -0800 Organization: http://groups.google.com Message-ID: <1172827235.116923.127160@31g2000cwt.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: sea.gmane.org 1172828464 20505 80.91.229.12 (2 Mar 2007 09:41:04 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 2 Mar 2007 09:41:04 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Mar 02 10:40:58 2007 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HN4G0-00046W-6k for geh-help-gnu-emacs@m.gmane.org; Fri, 02 Mar 2007 10:40:56 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HN4Fz-0000wW-EC for geh-help-gnu-emacs@m.gmane.org; Fri, 02 Mar 2007 04:40:55 -0500 Original-Path: shelby.stanford.edu!newshub.stanford.edu!postnews.google.com!31g2000cwt.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 23 Original-NNTP-Posting-Host: 193.252.51.94 Original-X-Trace: posting.google.com 1172827247 32708 127.0.0.1 (2 Mar 2007 09:20:47 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Fri, 2 Mar 2007 09:20:47 +0000 (UTC) User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.9) Gecko/20061205 (Debian-1.8.0.9-1) Galeon/2.0.2 (Debian package 2.0.2-4),gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: 31g2000cwt.googlegroups.com; posting-host=193.252.51.94; posting-account=H89-iA0AAAAoUALiCbsFWJeFeaCMOlzg Original-Xref: shelby.stanford.edu gnu.emacs.help:145988 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:41594 Archived-At: 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