Add ^D binding to quit eshell
This commit is contained in:
parent
d04a3bbd78
commit
bf6a117838
13
init.el
13
init.el
|
@ -306,8 +306,19 @@
|
|||
|
||||
;;;; Eshell
|
||||
(setup eshell
|
||||
(defun eshell-quit-or-delete-char (arg)
|
||||
"Delete the character to the right, or quit eshell on an empty line."
|
||||
(interactive "p")
|
||||
(if (and (eolp) (looking-back eshell-prompt-regexp))
|
||||
(eshell-life-is-too-much)
|
||||
(delete-forward-char arg)))
|
||||
(:option eshell-directory-name (acdw/in-dir "eshell/" t)
|
||||
eshell-aliases-file (acdw/in-dir "eshell/aliases" t)))
|
||||
eshell-aliases-file (acdw/in-dir "eshell/aliases" t))
|
||||
(add-hook 'eshell-mode-hook
|
||||
(defun hook--eshell-setup ()
|
||||
"Stuff to do after eshell is done setting up."
|
||||
(define-key eshell-mode-map (kbd "C-d")
|
||||
#'eshell-quit-or-delete-char))))
|
||||
|
||||
;;;; Debugger
|
||||
(setup debugger
|
||||
|
|
Loading…
Reference in New Issue