1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-04-25 07:40:40 -07:00

(eshell/diff): Fixed problems that were occurring with Emacs 21's

diff.el/compile.el interaction layer.
This commit is contained in:
John Wiegley 2001-04-24 06:31:46 +00:00
parent 157975e356
commit ef59cfc663

View file

@ -947,14 +947,20 @@ Show wall-clock time elapsed during execution of COMMAND.")
(throw 'eshell-replace-command
(eshell-parse-command "*diff" orig-args))))
(when (fboundp 'diff-mode)
(diff-mode)
(set (make-local-variable 'eshell-diff-window-config) config)
(local-set-key [?q] 'eshell-diff-quit)
(if (fboundp 'turn-on-font-lock-if-enabled)
(turn-on-font-lock-if-enabled))))
(other-window 1)
(goto-char (point-min))
nil))))
(make-local-variable 'compilation-finish-functions)
(add-hook
'compilation-finish-functions
`(lambda (buff msg)
(with-current-buffer buff
(diff-mode)
(set (make-local-variable 'eshell-diff-window-config)
,config)
(local-set-key [?q] 'eshell-diff-quit)
(if (fboundp 'turn-on-font-lock-if-enabled)
(turn-on-font-lock-if-enabled))
(goto-char (point-min))))))
(pop-to-buffer (current-buffer))))))
nil)
(defun eshell/locate (&rest args)
"Alias \"locate\" to call Emacs `locate' function."