Snippets and other bits

Using the CIDER debugger in Evil

Jun 6, 2021

When using evil and CIDER together, you might find that rebinding the keys required to control the debugger is a pain. Luckily, you donโ€™t actually have to, you can just enter insert mode instead:

(defun my-cider-debug-toggle-insert-state ()
  (if cider--debug-mode    ;; Checks if you're entering the debugger
      (evil-insert-state)  ;; If so, turn on evil-insert-state
    (evil-normal-state)))  ;; Otherwise, turn on normal-state

(add-hook 'cider--debug-mode-hook 'my-cider-debug-toggle-insert-state)

Borrowed from here.


โ† Back to all articles