GNU bug report logs - #31355
26.1; [PATCH] Fix remote-host/tramp directory tracking for shells in `term' buffers

Previous Next

Package: emacs;

Reported by: Phil Sainty <psainty <at> orcon.net.nz>

Date: Thu, 3 May 2018 13:53:01 UTC

Severity: normal

Tags: patch

Found in version 26.1

Done: Phil Sainty <psainty <at> orcon.net.nz>

Bug is archived. No further changes may be made.

Full log


Message #14 received at 31355 <at> debbugs.gnu.org (full text, mbox):

From: Phil Sainty <psainty <at> orcon.net.nz>
To: Michael Albinus <michael.albinus <at> gmx.de>
Cc: bug-gnu-emacs <bug-gnu-emacs-bounces+psainty=orcon.net.nz <at> gnu.org>,
 31355 <at> debbugs.gnu.org
Subject: Re: bug#31355: 26.1; [PATCH] Fix remote-host/tramp directory
 tracking for shells in `term' buffers
Date: Fri, 04 May 2018 02:47:40 +1200
[Message part 1 (text/plain, inline)]
On 2018-05-04 02:04, Michael Albinus wrote:
> Furthermore, I wouldn't hard-code "ssh". People might have other
> preferences, and on some systems it doesn't work. Think about Emacs
> running on MS WIndows, where "plink" is used instead of "ssh". Just 
> take
> "-" as method, this is a notation to apply user's default (Tramp) 
> method.

Revised patch attached to use the "-" pseudo method.


> I believe it is always save to use term-ansi-at-user. There's no need
> to check, whether it is equal to (user-real-login-name).

I've not changed this.  The code is evidentially deciding whether the
user/host pair being tracked in the shell in the term buffer is a match
for the user/host pair known locally to Emacs.  Unless both of those
components match, a tramp path is created.  I've not tested the case
of a different user on the local host, but it seems like reasonable
logic to me, at first look.

(if (and (string= term-ansi-at-host (system-name))
         (string= term-ansi-at-user (user-real-login-name)))
    ;; Use a local path
  ;; Use a tramp path

[0001-Fix-remote-host-directory-tracking-for-shells-in-ter.patch (text/x-diff, attachment)]

This bug report was last modified 7 years and 68 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.