[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: About `name' in loadup.el
From: |
Xue Fuqiao |
Subject: |
Re: About `name' in loadup.el |
Date: |
Mon, 11 Mar 2013 06:37:47 +0800 |
On Sun, 10 Mar 2013 20:00:38 +0000
Andy Moreton <andrewjmoreton@gmail.com> wrote:
> >> >> > In lisp/loadup.el:
> >> >> >
> >> >> > (let ((name (concat "emacs-" emacs-version)))
> >> >> > (while (string-match "[^-+_.a-zA-Z0-9]+" name)
> >> >> > (setq name (concat (downcase (substring name 0 (match-beginning
> >> >> > 0)))
> >> >> > "-"
> >> >> > (substring name (match-end 0)))))
> >> >> > (message "Adding name %s" name)
> >> >> > (add-name-to-file "emacs" name t))
[...]
> >> >> > And when will characters other than "-+_.a-zA-Z0-9" be in
> >> >> > `emacs-version'?
[...]
> >> So it is stripping stuff.
> > I see. It makes the program more robust, isn't it?
> The name is used to create a hardlink, so to avoid problems it should
> only contain characters that are allowed in portable filenames. This
> means removing the non-portable characters and replacing them with
> something that all filesystems should be able to cope with.
Thanks.
--
Best regards, Xue Fuqiao.
http://www.emacswiki.org/emacs/XueFuqiao