NonGNU ELPA - evil-lisp-state


An evil state to edit Lisp code
evil-lisp-state-8.2.tar (.sig), 2024-Mar-31, 70.0 KiB
Sylvain Benner <>
Atom feed
Browse ELPA's repository
CGit or Gitweb

To install this package from Emacs, use package-install or list-packages.

Full description



Adds a new evil state to navigate lisp code and edit sexp trees using mnemonic key bindings.

Table of Contents


Package manager

You can either install evil-lisp-state from MELPA:

M-x package-install evil-lisp-state

Or add it to your Cask file:

```elisp (source melpa)

(depends-on "evil-lisp-state") ```


Add evil-lisp-state.el to your load path. evil-lisp-state requires both evil, bind-map and smartparens to be installed.


To execute a command while in normal state, a leader key is used. The leader has to be defined with the function evil-lisp-state-leader. By default any command when executed sets the current state to lisp state.


  • to slurp three times while in normal state:

    3 s

  • to wrap a symbol in parenthesis then slurping two times:

    w 2 s

Key Bindings

Key Binding Function
\ switch to lisp state
\ evil jump item
\ ex command
\ insert expression before (same level as current one)
\ insert expression after (same level as current one)
\ go to the end of current sexp
\ hybrid version of kill sexp (can be used in non lisp dialects)
\ hybrid version of push sexp (can be used in non lisp dialects)
\ hybrid version of slurp sexp (can be used in non lisp dialects)
\ hybrid version of transpose sexp (can be used in non lisp dialects)
\ go to the beginning of current sexp
\ absorb expression
\ forward barf expression
\ backward barf expression
\ convolute expression
\ delete symbol
\ backward delete symbol
\ delete word
\ backward delete word
\ delete expression
\ backward delete expression
\ unwrap current expression and kill all symbols after point
\ unwrap current expression and kill all symbols before point
\ previous symbol
\ go to previous sexp
\ switch to insert state
\ go to beginning of current expression and switch to insert state
\ next closing parenthesis
\ join expression
\ previous opening parenthesis
\ next symbol
\ go to next sexp
\ paste after
\ paste before
\ raise expression (replace parent expression by current one)
\ forwared slurp expression
\ backward slurp expression
\ transpose expression
\ undo
\ got to parent sexp backward
\ redo
\ switch to visual state
\ switch to visual line state
\ switch to visual block state
\ wrap expression with parenthesis
\ unwrap expression
\ copy expression


No default binding comes with the package, you have to explicitly bind the lisp state to a key with the function evil-lisp-state-leader For instance:

elisp (evil-lisp-state-leader ", l")

Key bindings are set only for emacs-lisp-mode by default. It is possible to add major modes with the variable `evil-lisp-state-major-modes'.

It is also possible to define the key bindings globally by setting evil-lisp-state-global to t. In this case `evil-lisp-state-major-modes' has no effect.

If you don't want commands to enter in lisp state by default set the variable evil-lisp-state-enter-lisp-state-on-command to nil. Then use the . to enter manually in lisp state