Subject: Re: bug#31355: 26.1; [PATCH] Fix remote-host/tramp directory tracking for shells in `term' buffers

From: Michael Albinus <[email-masked]>
Date: Fri, 04 May 2018 09:27:26 +0200

Phil Sainty <[email-masked]> writes:

Hi Phil,

>> And here I believe you could always apply
>>
>> (format "/-:%s@%s:%s" term-ansi-at-user term-ansi-at-host
>> term-ansi-at-dir)
>
> Right, although I believe the intent is simply to produce the least-
> verbose path by excluding the username if possible (as indeed the user
> would very likely be doing if entering the tramp path manually); so
> I'd be inclined to leave that part alone as well.

I don't understand the benefit of the "least-verbose path". The user
hasn't to type anything, so there's no profit to have a shorter file name.

And you cannot expect, that for all Tramp methods the default user is
equal to `user-login-name'. This happened to ange-ftp, but it isn't the
case in Tramp. See variables `tramp-default-user' and
`tramp-default-user-alist'.

Best regards, Michael.