unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
Cc: tramp-devel@gnu.org, emacs-devel@gnu.org, "Kim F. Storm" <storm@cua.dk>
Subject: Re: tramp (2.0.51); tramp and file-name-all-completions
Date: Sun, 16 Oct 2005 21:56:39 +0200	[thread overview]
Message-ID: <87zmp944nc.fsf@gmx.de> (raw)
In-Reply-To: <E1ERCRD-0002MQ-Sz@fencepost.gnu.org> (Richard M. Stallman's message of "Sun, 16 Oct 2005 13:36:47 -0400")

"Richard M. Stallman" <rms@gnu.org> writes:

> I would say these problems are all bugs in tramp.

Yes.

> file-name-all-completions has a simple spec,
> and in principle it ought to work "right" for all meaningful args.

The problem is the syntactical ambiguity of Tramp file
names. (file-name-all-completions "" "/telnet:") can mean completion
of user and host names for method "telnet", or completion of file
names for method "ssh" on host "telnet".

When I wrote completion code for Tramp 3 years ago, I've introduced a
somehow obscure heuristic determining what is meant. This works more or
less the usual cases, but it breaks ido.

I've dropped a comment in the TODO "must be changed when we know it
better". It seems to be the time now.

> If there are some cases where it is just hopeless to ask tramp
> to do completion correctly, we could decide on some return value
> that means "unable to do the job right".

I don't think so. It is not a tragedy when file-name-all-completions
does not return the most complete list. Given the example above,
something like ("telnet:127.0.0.1:" "telnet:localhost.local:") would
be sufficient, even if there is a host called "telnet". Only when
completion of the method returns nil, one might try file name
completion.

I'm sitting already the whole day on this problem.

Best regards, Michael.

  reply	other threads:[~2005-10-16 19:56 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-10-15 21:42 tramp (2.0.51); tramp and file-name-all-completions Kim F. Storm
2005-10-16 17:36 ` Richard M. Stallman
2005-10-16 19:56   ` Michael Albinus [this message]
2005-10-16 21:43     ` Kim F. Storm

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87zmp944nc.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=emacs-devel@gnu.org \
    --cc=storm@cua.dk \
    --cc=tramp-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).