aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLute Kamstra2005-04-27 07:44:15 +0000
committerLute Kamstra2005-04-27 07:44:15 +0000
commitb2b46494df4c1f1672b6e260bb322bdf6a025949 (patch)
treec81c6827a0c6de3b28d6f30a36018ebceb631c75
parenta715531f6ee45ac7bf5ad77fc917913d93743062 (diff)
downloademacs-b2b46494df4c1f1672b6e260bb322bdf6a025949.tar.gz
emacs-b2b46494df4c1f1672b6e260bb322bdf6a025949.zip
(disable-command): Don't add spurious newlines to the init file.
Reported by Dan Jacobson <jidanni@jidanni.org>.
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/novice.el9
2 files changed, 10 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 1fbb9a57de9..5222a56d162 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12005-04-27 Lute Kamstra <lute@gnu.org>
2
3 * novice.el (disable-command): Don't add spurious newlines to the
4 init file. Reported by Dan Jacobson <jidanni@jidanni.org>.
5
12005-04-26 Jay Belanger <belanger@truman.edu> 62005-04-26 Jay Belanger <belanger@truman.edu>
2 7
3 * calc/calc-yank.el (calc-edit-finish): Make sure there is more 8 * calc/calc-yank.el (calc-edit-finish): Make sure there is more
diff --git a/lisp/novice.el b/lisp/novice.el
index 3e63f0a7bc6..171285ca3f1 100644
--- a/lisp/novice.el
+++ b/lisp/novice.el
@@ -1,6 +1,6 @@
1;;; novice.el --- handling of disabled commands ("novice mode") for Emacs 1;;; novice.el --- handling of disabled commands ("novice mode") for Emacs
2 2
3;; Copyright (C) 1985, 1986, 1987, 1994, 2002, 2004 3;; Copyright (C) 1985, 1986, 1987, 1994, 2002, 2004, 2005
4;; Free Software Foundation, Inc. 4;; Free Software Foundation, Inc.
5 5
6;; Maintainer: FSF 6;; Maintainer: FSF
@@ -182,9 +182,10 @@ to future sessions."
182 (if (search-forward (concat "(put '" (symbol-name command) " ") nil t) 182 (if (search-forward (concat "(put '" (symbol-name command) " ") nil t)
183 (delete-region 183 (delete-region
184 (progn (beginning-of-line) (point)) 184 (progn (beginning-of-line) (point))
185 (progn (forward-line 1) (point)))) 185 (progn (forward-line 1) (point)))
186 (goto-char (point-max)) 186 (goto-char (point-max))
187 (insert "\n(put '" (symbol-name command) " 'disabled t)\n") 187 (insert ?\n))
188 (insert "(put '" (symbol-name command) " 'disabled t)\n")
188 (save-buffer)))) 189 (save-buffer))))
189 190
190(provide 'novice) 191(provide 'novice)