summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lisp/td-shell.el9
1 files changed, 6 insertions, 3 deletions
diff --git a/lisp/td-shell.el b/lisp/td-shell.el
index 88714aa..ad76884 100644
--- a/lisp/td-shell.el
+++ b/lisp/td-shell.el
@@ -71,9 +71,12 @@ current line input."
(use-package eshell
:ensure nil
- :hook (eshell-first-time-mode . td/eshell-configure)
- :bind (("C-x E" . eshell)
- ("C-l" . td/eshell-clear))
+ :hook ((eshell-first-time-mode . td/eshell-configure)
+ ;; Workaround to bind keys locally to an eshell buffer.
+ ;; Apparently `:map eshell-mode-map' in `:bind' won't work.
+ (eshell-mode . (lambda ()
+ (define-key eshell-mode-map (kbd "C-l") #'td/eshell-clear))))
+ :bind (("C-x E" . eshell))
:config
(td/meow-insert-state 'eshell-mode))