[Top][All Lists]

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

'grep' + long list of files

From: Le Wang
Subject: 'grep' + long list of files
Date: 29 Jun 2006 00:15:51 -0700
User-agent: G2/0.2


I have a variable which holds a list of files, and I need to grep
through them for some expression.

The problem is that the command with the full list of files becomes
longer than the maximum allowed on my OS (Windows).  I've thought of
some possible solutions.

1.  Save list to temp file, use "xargs".  This is not ideal.  I don't
want to fumble with with temporary files.  BUT this is easy to
implement with a minimal lisp code and a shell/perl script.

2.  Make several smaller lists, run grep on each, and merge the output.
 Again, this is hacky and not ideal.  And I can't see how to do this
from looking at compile.el.

3.  Get Emacs to pipe the list into xargs as a string.  This is the
preferred solution, but it's not immediately clear to me how to do this
in conjunction with compilation mode.

I can't get xargs to recognize ^@ (read as null, but I can't type it
into this browser windos) as a separator while running in Emacs.

I already build this list for completion purposes, so grep-find doesn't
here.  Is There is an obvious solution I'm just not seeing?



reply via email to

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