* broken grep
[not found] <E1A1AA7-0002hJ-55@monty-python.gnu.org>
@ 2003-09-22 1:42 ` Joe Corneli
2003-09-22 6:21 ` Eli Zaretskii
0 siblings, 1 reply; 2+ messages in thread
From: Joe Corneli @ 2003-09-22 1:42 UTC (permalink / raw)
Hi, when I run grep like this:
(defun grope (string)
(interactive "MRegex: ")
(grep (concat "grep -n -i -e \"" string "\" " (concat apm:dir "a*.tex
") (concat apm:dir "b*.tex ") (concat apm:dir "t*.tex ")
(concat apm:dir "m*.tex ")))
(switch-to-buffer "*grep*"))
I get
cd ~/apm/
grep -n -i -e "int" /Users/joe/apm/a*.tex /Users/joe/apm/b*.tex
/Users/joe/apm/t*.tex /Users/joe/apm/m*.tex /dev/null
grep exited abnormally with code 2 at Sun Sep 21 20:39:50
Similarly if I just run grep through M-x grep
But if I copy and paste the grep string above to an rxvt,
it runs no problem. Also it ran no problem in Emacs
until today. Any idea what is causing the trouble?
Too many files in the directory maybe?? Causing some
kind of depth variable in Emacs to overload?
Joe
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: broken grep
2003-09-22 1:42 ` broken grep Joe Corneli
@ 2003-09-22 6:21 ` Eli Zaretskii
0 siblings, 0 replies; 2+ messages in thread
From: Eli Zaretskii @ 2003-09-22 6:21 UTC (permalink / raw)
> From: Joe Corneli <jcorneli@math.utexas.edu>
> Date: Sun, 21 Sep 2003 20:42:03 -0500
>
> cd ~/apm/
> grep -n -i -e "int" /Users/joe/apm/a*.tex /Users/joe/apm/b*.tex
> /Users/joe/apm/t*.tex /Users/joe/apm/m*.tex /dev/null
>
> grep exited abnormally with code 2 at Sun Sep 21 20:39:50
On what platform does this happen, and with what version of Emacs?
Also, if that's GNU Grep, what does "grep --version" print?
> But if I copy and paste the grep string above to an rxvt,
> it runs no problem. Also it ran no problem in Emacs
> until today. Any idea what is causing the trouble?
> Too many files in the directory maybe?? Causing some
> kind of depth variable in Emacs to overload?
Unlikely, on both counts: Emacs doesn't traverse the files itself, it
just invokes the Grep utility with the exact command string it prints
into the *grep* buffer, the one shown above.
The reason is that Grep, indeed, exited with exit status 2. You need
to find out why did that happen.
What happens if you invoke the same command via "M-!"?
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-09-22 6:21 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <E1A1AA7-0002hJ-55@monty-python.gnu.org>
2003-09-22 1:42 ` broken grep Joe Corneli
2003-09-22 6:21 ` Eli Zaretskii
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.