tramp-devel
[Top][All Lists]
Advanced

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

Re: Tramp and sudo


From: Kai Großjohann
Subject: Re: Tramp and sudo
Date: Thu, 14 Aug 2003 18:03:10 +0200
User-agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3.50 (gnu/linux)

address@hidden (Björn Lindström) writes:

> I tried evaluating
>
> (make-term "foo" "/usr/bin/sudo" nil "/bin/sh"),
>
> then typing
>
> exec env 'ENV=' 'PS1=$ ' /bin/sh
>
> in the resulting *foo* buffer. The result is a working shell but PS1 is
> set to '# '. ENV is empty, but that was the case in the executing
> environment, too.

I think make-term is the wrong way to approach it.  make-term does
different things internally than either M-x shell RET or Tramp.

> I also think that it might be worth pointing out a problem with
> shell-mode I have been having with shell-mode. It is behaving the same
> way as you believe Tramp is, echoing my input followed by `\n' instead
> of feeding it to the shell. (I have reported this on gnu.emacs.help,
> but received no answers). Here is some example running zsh, but it acts
> the same way with any shell I have tested.
>
> address@hidden ~]% ls
> ls\n

Yep.  It seems this is the same problem that Tramp is also seeing.

Try calling start-process to start a shell, then feed it some input
using process-send-string.  Do you see the same thing?

You could try ending the commands with \n, or with \r, or with \r\n.
Maybe one of them works better than the others.

Not sure what other things to try.  Hm.  Oh, certainly "emacs -q
-no-site-file" is one of the things to try.
-- 
Two cafe au lait please, but without milk.




reply via email to

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