# HG changeset patch # User Eli Zaretskii # Date 1123845477 0 # Node ID 94a635fcc5825a7ba9366563887ecacefa34089a # Parent fbe8143fcdeb0166393489e97461805e9cf3e197 (custom-save-all, custom-save-delete): Bind recentf-exclude to exclude custom-file. diff -r fbe8143fcdeb -r 94a635fcc582 lisp/cus-edit.el --- a/lisp/cus-edit.el Fri Aug 12 10:28:48 2005 +0000 +++ b/lisp/cus-edit.el Fri Aug 12 11:17:57 2005 +0000 @@ -141,7 +141,8 @@ (require 'cus-face) (require 'wid-edit) (eval-when-compile - (defvar custom-versions-load-alist)) ; from cus-load + (defvar custom-versions-load-alist) ; from cus-load + (defvar recentf-exclude)) ; from recentf.el (condition-case nil (require 'cus-load) @@ -3901,7 +3902,12 @@ "Visit `custom-file' and delete all calls to SYMBOL from it. Leave point at the old location of the first such call, or (if there were none) at the end of the buffer." - (let ((default-major-mode 'emacs-lisp-mode)) + (let ((default-major-mode 'emacs-lisp-mode) + (recentf-exclude (if recentf-mode + (cons (concat "\\`" + (regexp-quote (custom-file)) + "\\'") + recentf-exclude)))) (set-buffer (find-file-noselect (custom-file)))) (goto-char (point-min)) ;; Skip all whitespace and comments. @@ -4130,7 +4136,12 @@ (custom-save-variables) (custom-save-faces) (save-excursion - (let ((default-major-mode nil)) + (let ((default-major-mode nil) + (recentf-exclude (if recentf-mode + (cons (concat "\\`" + (regexp-quote (custom-file)) + "\\'") + recentf-exclude)))) (set-buffer (find-file-noselect (custom-file)))) (let ((file-precious-flag t)) (save-buffer)))))