[Top][All Lists]

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

M-x grep /dev/null embarrassment

From: Dan Jacobson
Subject: M-x grep /dev/null embarrassment
Date: 13 Mar 2002 12:04:12 +0800
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.1

"What's going on" I murmured to myself as I looked at the output from
(grep "grep -n -e geocities.com/jidanni *htm*|grep Dan")
"there's got to be a million Dan's in there... where did they go?
Hmmm, I know, I'll try
(grep "grep -n -e geocities.com/jidanni *htm*|grep -v Dan")
that ought to find them.  Still nothing.  I bet it's a LC_COLLATE

No, wait, look what it is doing:
cd /home/jidanni/geocities/
grep -n -e geocities.com/jidanni *htm*|grep -v Dan /dev/null

Oh, great, the old /dev/null hack to coax filenames out of old greps
is at play.  They only way I can counter it is fight back with
(grep "grep -n -e geocities.com/jidanni *htm*|grep Dan;:") i.e. I add
";:" at back to sterilize it.  adding ";#" or " #" also works.

By the way, after doing my tests with many C-x ESC ESC, I tried M-x
grep RET M-p M-p ... but it seems the C-x ESC ESC stuff are not added
to the M-x grep RET M-p history.

Anyways, "lose the /dev/null hack and use a regular grep -switch to
force filenames.  It's about time." 
http://www.geocities.com/jidanni/ Taiwan(04)25854780

reply via email to

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