From: Richard M. Stallman Date: Thu, 30 Dec 2004 01:47:35 +0000 (+0000) Subject: (eshell-previous-matching-input): X-Git-Tag: ttn-vms-21-2-B4~3063 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=de653a636e5a420096829e393d6cc40f5bc545ac;p=emacs.git (eshell-previous-matching-input): Start the deletion from the end of the output. --- diff --git a/lisp/eshell/em-hist.el b/lisp/eshell/em-hist.el index f4bfea798e0..573d06337db 100644 --- a/lisp/eshell/em-hist.el +++ b/lisp/eshell/em-hist.el @@ -840,7 +840,7 @@ If N is negative, find the next or Nth next match." (unless (minibuffer-window-active-p (selected-window)) (message "History item: %d" (- (ring-length eshell-history-ring) pos))) ;; Can't use kill-region as it sets this-command - (delete-region (save-excursion (eshell-bol) (point)) (point)) + (delete-region eshell-last-output-end (point)) (insert-and-inherit (eshell-get-history pos))))) (defun eshell-next-matching-input (regexp arg)