all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: npostavs@users.sourceforge.net
Cc: 25183@debbugs.gnu.org
Subject: bug#25183: 26.0.50; expanding quoted file name on w32
Date: Tue, 13 Dec 2016 09:30:18 +0100	[thread overview]
Message-ID: <877f745izp.fsf@gmx.de> (raw)
In-Reply-To: <87mvg0d33x.fsf@users.sourceforge.net> (npostavs's message of "Mon, 12 Dec 2016 20:33:54 -0500")

npostavs@users.sourceforge.net writes:

> Glenn Morris <rgm@gnu.org> writes:
>
>> Noam Postavsky wrote:
>>
>>>>>> (expand-file-name "/:~/path/./file")
>>>>>> => "/:~/path/file"
>>>
>>>>>> (expand-file-name "/:~/path/./file")
>>>>>> => "/:c:/Users/lb01177/AppData/Roaming/path/file"
>>>
>>>>
>>>> (file-name-absolute-p "/:~/path/./file")
>>>> => t
>>>
>>> I think all these cases are user error, `(emacs) Quoted File Names' says
>>>
>>>     You can "quote" an absolute file name [...] add '/:' at the beginning
>>>
>>> But you cannot quote a relative file name, which looks like what
>>> you're trying to do here. It might better to throw an error than
>>> return nonsense (though possibly not worth the trouble).
>>
>> But "~/blah" is an absolute file name. ?
>
> Yes, but in "/:~/blah", the /: should prevent expanding "~", so then it
> seems not to refer to an absolute file name, but rather a file named
> "blah" in a directory named literally "~".  But if it's not an absolute
> file name, then /: doesn't make sense.  So it's a kind of paradox.  This
> is not w32 specific (although the actual implementation happens to
> resolve the "paradox" in a different way on w32).

Well, I don't want to insist that it *must* be solved. But there's
different behaviour when running Emacs on GNU/Linux, or running on MS
Windows.

It is not an annoyance coming from a user's bug report; I've stumbled
over this when running tramp-tests.el under many different environments.

(expand-file-name "/:/~/path/./file") => "/:c:/~/path/file"

looks better, althoug the volume drive would still disturb me. But
that's my personal preference, the result might be OK on MS Windows.

Eli?

Best regards, Michael.





  reply	other threads:[~2016-12-13  8:30 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-12 15:54 bug#25183: 26.0.50; expanding quoted file name on w32 Michael Albinus
2016-12-12 16:48 ` Eli Zaretskii
2016-12-12 16:54   ` Michael Albinus
2016-12-12 18:11     ` Drew Adams
2016-12-12 18:17       ` Drew Adams
2016-12-13  0:39     ` Noam Postavsky
2016-12-13  1:08       ` Glenn Morris
2016-12-13  1:10         ` Glenn Morris
2016-12-13  1:33         ` npostavs
2016-12-13  8:30           ` Michael Albinus [this message]
2016-12-13 16:28             ` Eli Zaretskii
2016-12-24 12:52               ` Eli Zaretskii
2016-12-24 13:57                 ` npostavs
2016-12-24 16:06                   ` Eli Zaretskii
2016-12-24 17:43                     ` Noam Postavsky
2016-12-24 18:00                       ` Eli Zaretskii
2016-12-24 18:51                         ` npostavs
2016-12-27  8:17                           ` Eli Zaretskii
2016-12-25 11:31                 ` Michael Albinus
2016-12-26 15:58                   ` Eli Zaretskii
2016-12-26 16:19                     ` Michael Albinus
2016-12-27  8:14                       ` Eli Zaretskii
2016-12-27  9:56                         ` Michael Albinus
2017-01-27  9:51                           ` Michael Albinus

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

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

  git send-email \
    --in-reply-to=877f745izp.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=25183@debbugs.gnu.org \
    --cc=npostavs@users.sourceforge.net \
    /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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.