From: Peter Dyballa <Peter_Dyballa@Web.DE>
Cc: Help-Gnu-Emacs <help-gnu-emacs@gnu.org>
Subject: Re: Lisp code to expand /~ and // but not env vars?
Date: Mon, 3 Oct 2005 12:50:03 +0200 [thread overview]
Message-ID: <661026f5efbc685ec3b4d2684647bf71@Web.DE> (raw)
In-Reply-To: <DNEMKBNJBGPAOPIJOOICKEPLCMAA.drew.adams@oracle.com>
Am 03.10.2005 um 02:03 schrieb Drew Adams:
> Function `expand-file-name' does not replace "//" and "/~" as
> `substitute-in-file-name' does.
>
// is in UNIX nonsense. The root is / and does not get more root when
written as '//' -- this only has in ancient (Apollo) Domain OS a
meaning (Domain OS could create ad-hoc networks and // was the root of
the individual members in the network). '//' is created as a text in
mini-buffer when you either try to find a file or try to dired. The
right means to handle such strings would be to substitute everything
from the beginning to // with /.
'/~' probably in every OS is nonsense. / is the root; ~ is, when
followed by a /, my home directory; ~, when followed by a user's login
name, means that user's home directory. The sequence '/~' happens to
appear in mini-buffer when you either try to find a file or try to
dired. The right means to handle such strings would be to substitute
everything from the beginning to /~ with ~.
The routines in dired or find-file that handle such 'input' handle it
already right.
--
Greetings
Pete
There's no sense in being precise when you don't
even know what you're talking about.
-- John von Neumann
next prev parent reply other threads:[~2005-10-03 10:50 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-02 22:51 Lisp code to expand /~ and // but not env vars? Drew Adams
2005-10-02 23:16 ` Lennart Borgman
2005-10-03 0:03 ` Drew Adams
2005-10-03 10:50 ` Peter Dyballa [this message]
2005-10-03 16:34 ` Lennart Borgman
[not found] ` <mailman.9543.1128345398.20277.help-gnu-emacs@gnu.org>
2005-10-03 14:55 ` Mathias Dahl
2005-10-03 21:07 ` Drew Adams
[not found] <mailman.9471.1128294372.20277.help-gnu-emacs@gnu.org>
2005-10-03 20:40 ` Thien-Thi Nguyen
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=661026f5efbc685ec3b4d2684647bf71@Web.DE \
--to=peter_dyballa@web.de \
--cc=help-gnu-emacs@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.
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).