Subject: bug#27612: 25.2; invoking term from a remote eshell uses the local path

From: Michael Albinus <[email-masked]>
Date: Wed, 12 Jul 2017 16:46:43 +0200

Pablo Barbachano <[email-masked]> writes:

Hi Pablo,

> M-x eshell
> $ cd /ssh:remote-host:
> $ hostname
> <remote-hostname>
>
> $ term hostname
> <local-hostname>
>
> term does not seem to get the default-directory from eshell.

That is because term.el is not Tramp-aware. In `term-exec-1', it uses
`start-process' instead of `start-file-process'.

One could replace this, but scanning term.el, there seems to be a tight
integration with ange-ftp. So I guess it needs further work to cooperate
with Tramp.

I'm not a term.el user, so I don't know, whether it is a feature to run
always locally. Other people might tell, whether it would be appropriate
to support remoteness.

If yes, I could try to migrate term.el. But this would take time anyway,
understanding 4500 lines of unknown code. And maybe it is not possible
at all to support a full equipped remote terminal in Emacs.

Best regards, Michael.