/[emacs]/emacs/lisp/eshell/em-hist.el
ViewVC logotype

Diff of /emacs/lisp/eshell/em-hist.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.8 by johnw, Sat Feb 16 07:11:05 2002 UTC revision 1.9 by pj, Sat Feb 16 09:39:14 2002 UTC
# Line 207  element, regardless of any text on the c Line 207  element, regardless of any text on the c
207    
208  (defun eshell-hist-initialize ()  (defun eshell-hist-initialize ()
209    "Initialize the history management code for one Eshell buffer."    "Initialize the history management code for one Eshell buffer."
   (make-local-hook 'eshell-expand-input-functions)  
210    (add-hook 'eshell-expand-input-functions    (add-hook 'eshell-expand-input-functions
211              'eshell-expand-history-references nil t)              'eshell-expand-history-references nil t)
212    
213    (when (eshell-using-module 'eshell-cmpl)    (when (eshell-using-module 'eshell-cmpl)
     (make-local-hook 'pcomplete-try-first-hook)  
214      (add-hook 'pcomplete-try-first-hook      (add-hook 'pcomplete-try-first-hook
215                'eshell-complete-history-reference nil t))                'eshell-complete-history-reference nil t))
216    
# Line 224  element, regardless of any text on the c Line 222  element, regardless of any text on the c
222               (append rebind-alist eshell-hist-rebind-keys-alist))               (append rebind-alist eshell-hist-rebind-keys-alist))
223          (set (make-local-variable 'search-invisible) t)          (set (make-local-variable 'search-invisible) t)
224          (set (make-local-variable 'search-exit-option) t)          (set (make-local-variable 'search-exit-option) t)
         (make-local-hook 'isearch-mode-hook)  
225          (add-hook 'isearch-mode-hook          (add-hook 'isearch-mode-hook
226                    (function                    (function
227                     (lambda ()                     (lambda ()
228                       (if (>= (point) eshell-last-output-end)                       (if (>= (point) eshell-last-output-end)
229                           (setq overriding-terminal-local-map                           (setq overriding-terminal-local-map
230                                 eshell-isearch-map)))) nil t)                                 eshell-isearch-map)))) nil t)
         (make-local-hook 'isearch-mode-end-hook)  
231          (add-hook 'isearch-mode-end-hook          (add-hook 'isearch-mode-end-hook
232                    (function                    (function
233                     (lambda ()                     (lambda ()
# Line 278  element, regardless of any text on the c Line 274  element, regardless of any text on the c
274      (if eshell-history-file-name      (if eshell-history-file-name
275          (eshell-read-history nil t))          (eshell-read-history nil t))
276    
     (make-local-hook 'eshell-exit-hook)  
277      (add-hook 'eshell-exit-hook 'eshell-write-history nil t))      (add-hook 'eshell-exit-hook 'eshell-write-history nil t))
278    
279    (unless eshell-history-ring    (unless eshell-history-ring
280      (setq eshell-history-ring (make-ring eshell-history-size)))      (setq eshell-history-ring (make-ring eshell-history-size)))
281    
   (make-local-hook 'eshell-exit-hook)  
282    (add-hook 'eshell-exit-hook 'eshell-write-history nil t)    (add-hook 'eshell-exit-hook 'eshell-write-history nil t)
283    
284    (add-hook 'kill-emacs-hook 'eshell-save-some-history)    (add-hook 'kill-emacs-hook 'eshell-save-some-history)

Legend:
Removed from v.1.8  
changed lines
  Added in v.1.9

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26