From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Use .emacs.d in savehist.el Date: Mon, 24 Oct 2005 11:58:50 -0400 Message-ID: <87u0f69ae6.fsf-monnier+emacs@gnu.org> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1130169951 18177 80.91.229.2 (24 Oct 2005 16:05:51 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 24 Oct 2005 16:05:51 +0000 (UTC) Cc: Hrvoje Niksic Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Oct 24 18:05:42 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1EU4j3-0003y3-44 for ged-emacs-devel@m.gmane.org; Mon, 24 Oct 2005 17:59:05 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EU4j2-0002Dt-KU for ged-emacs-devel@m.gmane.org; Mon, 24 Oct 2005 11:59:04 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1EU4is-0002Dd-Jh for emacs-devel@gnu.org; Mon, 24 Oct 2005 11:58:54 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1EU4ir-0002DR-4T for emacs-devel@gnu.org; Mon, 24 Oct 2005 11:58:54 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EU4ir-0002DO-2g for emacs-devel@gnu.org; Mon, 24 Oct 2005 11:58:53 -0400 Original-Received: from [209.226.175.184] (helo=tomts22-srv.bellnexxia.net) by monty-python.gnu.org with esmtp (Exim 4.34) id 1EU4ir-0002bJ-57 for emacs-devel@gnu.org; Mon, 24 Oct 2005 11:58:53 -0400 Original-Received: from alfajor ([70.48.83.21]) by tomts22-srv.bellnexxia.net (InterMail vM.5.01.06.10 201-253-122-130-110-20040306) with ESMTP id <20051024155852.JYVC21470.tomts22-srv.bellnexxia.net@alfajor>; Mon, 24 Oct 2005 11:58:52 -0400 Original-Received: by alfajor (Postfix, from userid 1000) id 9A00BD781C; Mon, 24 Oct 2005 11:58:50 -0400 (EDT) Original-To: emacs-devel@gnu.org User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:44731 Archived-At: Any objection to the patch below? Stefan Index: lisp/savehist.el =================================================================== RCS file: /cvsroot/emacs/emacs/lisp/savehist.el,v retrieving revision 1.7 diff -u -r1.7 savehist.el --- lisp/savehist.el 22 Oct 2005 17:45:50 -0000 1.7 +++ lisp/savehist.el 24 Oct 2005 15:55:38 -0000 @@ -110,7 +73,13 @@ :type '(repeat (symbol :tag "Variable")) :group 'savehist) -(defcustom savehist-file "~/.emacs-history" +(defcustom savehist-file + (cond + ;; Backward compatibility with previous versions of savehist. + ((file-exists-p "~/.emacs-history") "~/.emacs-history") + ((and (not (featurep 'xemacs)) (file-directory-p "~/.emacs.d/")) + "~/.emacs.d/history") + (t "~/.emacs-history")) - "*File name to save minibuffer history to. + "File name to save minibuffer history to. The minibuffer history is a series of Lisp expressions, which should be loaded using `savehist-load' from your .emacs. See `savehist-load' for