0

In jupeter-repl-mode, when the cursor is on an empty line, right next to the prompt, exiting Evil insert state moves the cursor back to the previous line. I solved this like this:

;;; Fix cursor going up a line when exiting the insert mode at the prompt.
(defun a2/evil-exit-insert-state-leave-cursor-here ()
  ""
  (interactive)
  (evil-normal-state)
  (evil-next-line))

I wonder whether other people have encountered this problem. This only works because if the cursor stays put, there is no next line to go to.

Setting evil-move-cursor-back to nil doesn't help.

I am using Doom Emacs. I had a similar problem before with IPython REPL as well, I think.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.