help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: Emacs 23.3 with Cygwin bash and '\r'.


From: Eli Zaretskii
Subject: Re: Emacs 23.3 with Cygwin bash and '\r'.
Date: Fri, 11 Mar 2011 11:00:09 +0200

> From: Oleksandr Gavenko <gavenko@bifit.com.ua>
> Date: Fri, 11 Mar 2011 10:32:44 +0200
> 
> On 10.03.2011 19:34, Eli Zaretskii wrote:
> >> From: Oleksandr Gavenko<gavenko@bifit.com.ua>
> >> Date: Thu, 10 Mar 2011 18:30:41 +0200
> >>
> >> I get latest Emacs 23.3:
> >>
> >>     http://permalink.gmane.org/gmane.emacs.announce/19
> >>
> >> and it loaded successfully, but previously all Emacs after setting:
> >>
> >>          (setq shell-file-name "bash")
> >>          (setenv "SHELL" "/bin/bash")
> >>
> >> work fine and now shell say:
> >>
> >>   $ pwd
> >> bash: $'pwd\r': команда не найдена
> >
> > Doesn't that \r give a hint?
> >
> Sorry, no ))

What value do you get if you evaluate the following expression:

   (process-coding-system (get-process "shell"))

You can do the evaluation with M-:

Since you are using the Cygwin bash, you need to use undecided-unix
(or something -unix, anyway) in the cdr of the cons cell that is
returned by process-coding-system.  You can probably use
set-process-coding-system to change the defaults.

(Btw, if your Emacs is a native Windows build, then you should expect
these surprises, because native Windows programs and Cygwin programs
are subtly incompatible, the matters related to EOL format being one
of the aspects of this incompatibility.  Why not use the Cygwin build
of Emacs instead?)

> In *Message* buffer I get:
> 
> #("ls\n" 0 2
>    (fontified t))
> 
> So no any \r pass to filter!!

Encoding and decoding works below the Lisp level.




reply via email to

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