Mercurial > emacs
comparison lisp/savehist.el @ 99106:814d2d823dd7
New function `locate-user-emacs-file'.
* subr.el (locate-user-emacs-file): New function.
(user-emacs-directory): Mention it in docstring.
* completion.el (save-completions-file-name):
* filesets.el (filesets-menu-cache-file):
* image-dired.el (image-dired-dir, image-dired-db-file)
(image-dired-temp-image-file, image-dired-gallery-dir)
(image-dired-temp-rotate-image-file):
* savehist.el (savehist-file):
* server.el (server-auth-dir):
* startup.el (auto-save-list-file-prefix):
* thumbs.el (thumbs-thumbsdir):
* tutorial.el (tutorial--saved-dir):
* play/gamegrid.el (gamegrid-user-score-file-directory): Use it.
* url.el (url-configuration-directory): Use `locate-user-emacs-file'.
* NEWS: New function `locate-user-emacs-file'.
author | Juanma Barranquero <lekktu@gmail.com> |
---|---|
date | Fri, 24 Oct 2008 09:39:27 +0000 |
parents | a2b77994ca7e |
children | 2e0e3e5cbd97 |
comparison
equal
deleted
inserted
replaced
99105:910cbd4e6ade | 99106:814d2d823dd7 |
---|---|
94 "*List of additional variables not to save." | 94 "*List of additional variables not to save." |
95 :type '(repeat variable) | 95 :type '(repeat variable) |
96 :group 'savehist) | 96 :group 'savehist) |
97 | 97 |
98 (defcustom savehist-file | 98 (defcustom savehist-file |
99 (cond | 99 (locate-user-emacs-file "history" ".emacs-history") |
100 ;; Backward compatibility with previous versions of savehist. | |
101 ((file-exists-p "~/.emacs-history") "~/.emacs-history") | |
102 ((and (not (featurep 'xemacs)) (file-directory-p user-emacs-directory)) | |
103 (concat user-emacs-directory "history")) | |
104 ((and (featurep 'xemacs) (file-directory-p "~/.xemacs/")) | |
105 "~/.xemacs/history") | |
106 ;; For users without `~/.emacs.d/' or `~/.xemacs/'. | |
107 (t (convert-standard-filename "~/.emacs-history"))) | |
108 "*File name where minibuffer history is saved to and loaded from. | 100 "*File name where minibuffer history is saved to and loaded from. |
109 The minibuffer history is a series of Lisp expressions loaded | 101 The minibuffer history is a series of Lisp expressions loaded |
110 automatically when `savehist-mode' is turned on. See `savehist-mode' | 102 automatically when `savehist-mode' is turned on. See `savehist-mode' |
111 for more details. | 103 for more details. |
112 | 104 |