[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Don't concat directories to file names

From: Juanma Barranquero
Subject: Re: Don't concat directories to file names
Date: Thu, 21 Jun 2007 10:11:09 +0200

On 6/21/07, Richard Stallman <address@hidden> wrote:

What these files all have in common is that they are used
in special ways by Emacs.

Which is so generic as to not mean anything IMO.

The function could be `locate-user-emacs-directory'

The function does not locate a directory, but a file. It's intended to
return the path for a filename, i.e., if a module wants to save its
data in ".my-module" and your $HOME is /home/you, and
`user-emacs-directory' is at default value, then

(function-without-a-name ".my-module")

will return "/home/you/.my-module" if it exists, else
"/home/you/.emacs.d/.my-module" (creating /home/you/.emacs.d/ as

With the second optional argument NEW-NAME:

(function-without-a-name ".my-module" "module-data")

in the second case (when ~/.my-module does not exist) it will return

So locate-user-emacs-directory does not describe what the function
does, and locate-user-emacs-file would be confusing: it does not
return the path of the "emacs file" (presumable .emacs).


reply via email to

[Prev in Thread] Current Thread [Next in Thread]