[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r103598: * shell.el (shell-mode): Set
From: |
Glenn Morris |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r103598: * shell.el (shell-mode): Set comint-input-ring-size from HISTSIZE. (Bug#7889) |
Date: |
Wed, 09 Mar 2011 01:01:14 -0800 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 103598
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Wed 2011-03-09 01:01:14 -0800
message:
* shell.el (shell-mode): Set comint-input-ring-size from HISTSIZE. (Bug#7889)
modified:
lisp/ChangeLog
lisp/shell.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2011-03-09 08:43:27 +0000
+++ b/lisp/ChangeLog 2011-03-09 09:01:14 +0000
@@ -1,5 +1,8 @@
2011-03-09 Glenn Morris <address@hidden>
+ * shell.el (shell-mode):
+ Set comint-input-ring-size from HISTSIZE. (Bug#7889)
+
* progmodes/gdb-mi.el (gdb): Improve 2010-12-08 change.
Check for GDBHISTFILE, HISTSIZE, etc. (Bug#7889)
=== modified file 'lisp/shell.el'
--- a/lisp/shell.el 2011-03-05 21:56:00 +0000
+++ b/lisp/shell.el 2011-03-09 09:01:14 +0000
@@ -459,7 +459,12 @@
;; shell-dependent assignments.
(when (ring-empty-p comint-input-ring)
(let ((shell (file-name-nondirectory (car
- (process-command (get-buffer-process (current-buffer)))))))
+ (process-command (get-buffer-process (current-buffer))))))
+ (hsize (getenv "HISTSIZE")))
+ (and (stringp hsize)
+ (integerp (setq hsize (string-to-number hsize)))
+ (> hsize 0)
+ (set (make-local-variable 'comint-input-ring-size) hsize))
(setq comint-input-ring-file-name
(or (getenv "HISTFILE")
(cond ((string-equal shell "bash") "~/.bash_history")
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r103598: * shell.el (shell-mode): Set comint-input-ring-size from HISTSIZE. (Bug#7889),
Glenn Morris <=