[Top][All Lists]

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

Re: Windows Emacs and Cygwin - the default find-grep has a NUL argument

From: Eli Zaretskii
Subject: Re: Windows Emacs and Cygwin - the default find-grep has a NUL argument
Date: Sat, 27 Feb 2010 13:30:27 +0200

> From: The Quiet Center <address@hidden>
> Date: Sat, 27 Feb 2010 02:13:52 -0800 (PST)
> When I type M-x grep-find in Emacs 23 for Windows, I get a command
> line that has NUL in it:
> Run find (like this): find . -type f -exec grep -nH  {} NUL \;
> and I have to manually remove NUL for the grep-find command to work...
> how can I remove that NUL part of the command line? Or should I leave
> it and modify something else?

The NUL part comes from the value of the variable `null-device'.  If
you will only ever be invoking Cygwin programs as Emacs subprocesses,
you can try customizing that variable to give it the "/dev/null" value
expected by the Cygwin shell.  But I don't know whether this could
break something else; search the Lisp files for null-device to see if
Emacs uses it in any context that is not invoking external programs.

Btw, if you use Cygwin, why don't you use the Cygwin build of Emacs?
Mixing two subtly incompatible packages, like Emacs and Cygwin, is
generally asking for trouble.  (For example, "M-x gdb" is known to be
broken with native Windows Emacs and Cygwin build of GDB, because of
incompatible handling of the terminal.)  So my advice would be to
install the Cygwin build of Emacs instead.  Then you won't need any
tweaking of null-device, cygwin-mount, etc.

reply via email to

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