mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-31 14:43:40 -05:00
fix(eval): lookup RET binding in insert if evil
Otherwise, if the REPL was not in insert mode the send-to-buffer would fail.
This commit is contained in:
committed by
Henrik Lissner
parent
3a34894492
commit
9d4d5b756a
@@ -136,7 +136,12 @@ immediately after."
|
|||||||
;; current REPL uses comint. Even if it did, no telling if they
|
;; current REPL uses comint. Even if it did, no telling if they
|
||||||
;; have their own `comint-send-input' wrapper, so to be safe, I
|
;; have their own `comint-send-input' wrapper, so to be safe, I
|
||||||
;; simply emulate the keypress.
|
;; simply emulate the keypress.
|
||||||
(call-interactively (doom-lookup-key (kbd "RET"))))
|
(call-interactively
|
||||||
|
(if (bound-and-true-p evil-local-mode)
|
||||||
|
(evil-save-state
|
||||||
|
(evil-insert-state)
|
||||||
|
(doom-lookup-key (kbd "RET")))
|
||||||
|
(doom-lookup-key (kbd "RET")))))
|
||||||
(sit-for 0.001)
|
(sit-for 0.001)
|
||||||
(redisplay 'force)))
|
(redisplay 'force)))
|
||||||
(when (and (eq origin-window (selected-window))
|
(when (and (eq origin-window (selected-window))
|
||||||
|
Reference in New Issue
Block a user