To install this package, run in Emacs:
M-x package-install RET evil-lisp-state RET
Adds a new evil state to navigate lisp code and edit sexp trees using mnemonic key bindings.
**Table of Contents** - [evil-lisp-state](#evil-lisp-state) - [Install](#install) - [Package manager](#package-manager) - [Manually](#manually) - [Principle](#principle) - [Commands and key bindings](#commands-and-key-bindings) - [Configuration](#configuration)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
.
Examples:
to slurp three times while in normal state:
to wrap a symbol in parenthesis then slurping two times:
Key Binding | Function
--------------------------|------------------------------------------------------------
\lisp state
\k</kbd> | hybrid version of kill sexp (can be used in non lisp dialects)
<kbd>\<leader\>
ps</kbd> | hybrid version of slurp sexp (can be used in non lisp dialects)
<kbd>\<leader\>
tinsert state
\insert state
\visual state
\visual line state
\visual block state
\
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
lisp state