* tramp inconsistent completion over default directory
@ 2018-05-22 15:40 Yuri D'Elia
2018-05-22 16:08 ` Michael Albinus
0 siblings, 1 reply; 8+ messages in thread
From: Yuri D'Elia @ 2018-05-22 15:40 UTC (permalink / raw)
To: emacs-devel
Using emacs+tramp from master here.
When I try to open a location using the syntax:
/-:remote:<TAB>
the contents of the home directory on the remote host are shown.
Assuming a "projects/" subdirectory exists, when I try to complete it:
/-:remote:proj<TAB>
I get "no match". But if I type manually the path until the first slash:
/-:remote:projects/<TAB>
everything works from then onwards. So it seems that completion in the
home directory doesn't work as a special case (again, no slash?).
If I explicitly use ~ (/-:remote:~/proj<TAB>) the completion works as
intended.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: tramp inconsistent completion over default directory
2018-05-22 15:40 tramp inconsistent completion over default directory Yuri D'Elia
@ 2018-05-22 16:08 ` Michael Albinus
2018-05-22 16:14 ` Yuri D'Elia
0 siblings, 1 reply; 8+ messages in thread
From: Michael Albinus @ 2018-05-22 16:08 UTC (permalink / raw)
To: Yuri D'Elia; +Cc: emacs-devel
Yuri D'Elia <wavexx@thregr.org> writes:
Hi Yuri,
> So it seems that completion in the home directory doesn't work as a
> special case (again, no slash?).
It is intended that Tramp starts with remote file name completion only
if it sees a slash. You could always add a slash if needed, like
/-:remote:./proj<TAB>
Completing an empty remote file name like
/-:remote:<TAB>
was not planned, this must be a side effect I'm not aware of ...
Best regards, Michael.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: tramp inconsistent completion over default directory
2018-05-22 16:08 ` Michael Albinus
@ 2018-05-22 16:14 ` Yuri D'Elia
2018-05-22 16:25 ` Michael Albinus
0 siblings, 1 reply; 8+ messages in thread
From: Yuri D'Elia @ 2018-05-22 16:14 UTC (permalink / raw)
To: emacs-devel
On Tue, May 22 2018, Michael Albinus wrote:
> It is intended that Tramp starts with remote file name completion only
> if it sees a slash. You could always add a slash if needed, like
>
> /-:remote:./proj<TAB>
>
> Completing an empty remote file name like
>
> /-:remote:<TAB>
>
> was not planned, this must be a side effect I'm not aware of ...
Not only the completion works, but you can open /-:remote: and it will
load the home directory into dired.
Personally I'd love to being able to work without the extra "./" or "~/"
(I find it redundant), but if it's ambiguous for the tramp syntax, then
I'd prevent that to happen for consistency.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: tramp inconsistent completion over default directory
2018-05-22 16:14 ` Yuri D'Elia
@ 2018-05-22 16:25 ` Michael Albinus
2018-05-22 16:32 ` Yuri D'Elia
0 siblings, 1 reply; 8+ messages in thread
From: Michael Albinus @ 2018-05-22 16:25 UTC (permalink / raw)
To: Yuri D'Elia; +Cc: emacs-devel
Yuri D'Elia <wavexx@thregr.org> writes:
> Not only the completion works, but you can open /-:remote: and it will
> load the home directory into dired.
For sure. This is another case; which doesn't need completion.
> Personally I'd love to being able to work without the extra "./" or "~/"
> (I find it redundant), but if it's ambiguous for the tramp syntax, then
> I'd prevent that to happen for consistency.
IIRC, we have done this because people have claimed that Tramp starts
completion when not intended yet. Time consuming. So we have decided
that we need a clear indication that the user want's completion. A slash
is such a sign.
(Well, it is a discussion from 10+ years ago. If I would be urged to
find the pointers, it would be real work ...)
Best regards, Michael.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: tramp inconsistent completion over default directory
2018-05-22 16:25 ` Michael Albinus
@ 2018-05-22 16:32 ` Yuri D'Elia
2018-05-23 11:16 ` Michael Albinus
0 siblings, 1 reply; 8+ messages in thread
From: Yuri D'Elia @ 2018-05-22 16:32 UTC (permalink / raw)
To: emacs-devel
On Tue, May 22 2018, Michael Albinus wrote:
> IIRC, we have done this because people have claimed that Tramp starts
> completion when not intended yet. Time consuming. So we have decided
> that we need a clear indication that the user want's completion. A
> slash is such a sign.
When using multi-hops, perhaps? Although the syntax doesn't seem
ambiguous to me by another cursory look.
Maybe with the old syntax it was possible though.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: tramp inconsistent completion over default directory
2018-05-22 16:32 ` Yuri D'Elia
@ 2018-05-23 11:16 ` Michael Albinus
2018-05-24 15:01 ` Michael Albinus
0 siblings, 1 reply; 8+ messages in thread
From: Michael Albinus @ 2018-05-23 11:16 UTC (permalink / raw)
To: Yuri D'Elia; +Cc: emacs-devel
Yuri D'Elia <wavexx@thregr.org> writes:
> When using multi-hops, perhaps? Although the syntax doesn't seem
> ambiguous to me by another cursory look.
>
> Maybe with the old syntax it was possible though.
Likely, it was related to the ambigous old syntax, when you didn't know
whether "foo" is a method or a hostname, after typing "/foo:". So it was
unclear, whether "baz" would be a remote file name to be completed,
after typing "/foo:baz<TAB>". An additional slash "/foo:./baz<TAB>" made
it obvious.
I'll check whether I could improve this, now with the changed syntax.
Best regards, Michael.
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2018-05-29 16:49 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-05-22 15:40 tramp inconsistent completion over default directory Yuri D'Elia
2018-05-22 16:08 ` Michael Albinus
2018-05-22 16:14 ` Yuri D'Elia
2018-05-22 16:25 ` Michael Albinus
2018-05-22 16:32 ` Yuri D'Elia
2018-05-23 11:16 ` Michael Albinus
2018-05-24 15:01 ` Michael Albinus
2018-05-29 16:49 ` Yuri D'Elia
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).