Questions tagged [evil]

Evil Mode is a Vim emulation layer for Emacs.

Filter by
Sorted by
Tagged with
0
votes
2answers
21 views

C-i combination doesn't work with lowercase i [duplicate]

I've configured Doom emacs to run an interactive evil-ex command in visual mode, the reaconfiguration is as below: (defun evil-insert-into-lines () (interactive) (evil-ex "'<,'>norm I&...
1
vote
2answers
28 views

How can I prevent pasting after org-copy-visible leaving cursor at end of text?

In evil-mode, if I use 3yy to copy three lines, then move somewhere else in my file and do P (evil-paste-before), the three lines are pasted before the line with the cursor, and the cursor is left at ...
0
votes
0answers
25 views

How to write the result of running an external command to a scratch buffer?

I'm running this ex command in evil mode: :%!grep -E "^\#" how can I write the result to some arbitrary buffer, instead of replacing the content of the current buffer?
0
votes
1answer
55 views

Override org-mode indentation function in evil insert mode

How can I override the org-mode indentation function of TAB in evil-insert-state-map? I'd like it to always fold and unfold the current or parent header, and switch the indentation functionality to ...
0
votes
1answer
14 views

Close only code folds using evil

How do I close all code folds (but not comments) with evil's code folding? For now I'm using evil-close-folds and evil-open-folds, but it closes all folds, including comments. I'm using spacemacs 0....
1
vote
0answers
22 views

Vim help on Emacs using evil-mode?

It would be nice to have the help system present in Vim when using Emacs evil-mode (:help command). I searched online and could not find a way to do this since only the native Emacs C-h help menu is ...
0
votes
0answers
27 views

Is it possible to replicate vim-unimpaired [p paste behaviour?

Evil-unimpaired (https://github.com/zmaas/evil-unimpaired/) tries to replicate vim-unimpaired, but the paste behaviour is just a dumbed down version of the original. The evil-unimpaired behaviour on [...
0
votes
0answers
16 views

How to use Ctrl+K as evil escape?

I understand that the way to rebind the "escape" function while using the eVil mode is something on the lines of (setq-default evil-escape-key-sequence "jj"). But I want to set my &...
0
votes
0answers
20 views

How to use C-j C-k to move window in term mode using evil?

The bindings of C-j C-k to evil-window-down[up] work well every where apart form term mode. term mode rebinds these to C-w j C-w k - this is super annoying! How can i make term use the C-j/C-k ...
0
votes
1answer
36 views

Doom emacs dired +ranger not obeying evil-mode

I am using doom emacs and in my init file I have (dired +ranger) The problem is when I open dired, I cannot press tab to select for example. I have first to toggle off evil-mode. If I do, I lose all ...
1
vote
2answers
24 views

How do I make Evil's C-o work with Org's C-c C-o?

Org mode's org-open-at-point (C-c C-o) works great for internal links, e.g. Stuff to buy: - <<food>> food: - tomato - potato - banana - <<drinks>> drinks: - juice - ...
1
vote
2answers
33 views

How to copy one register to another?

In vim :let @"=@* will copy the content of* register to the " register. How can it be done with evil?
0
votes
0answers
31 views

How <dd> evil keymap works?

d seems to be bound to evil-delete which requires beg and end arguments. I suspect they are somehow obtained from d motion. Let's say I have defun my-delete-line (body). What should go in body to ...
0
votes
0answers
17 views

Preserving evil mode search/replace command history

In evil mode, I use a lot of search/replace with %s/pattern/replacement. I have (evil-select-search-module 'evil-search-module 'evil-search) in my ~/.emacs file. However, some of the past search/...
1
vote
0answers
45 views

Dvorak input mode wrong letters when typing fast, correct, when typing slow

I have dvorak keyboard layout set as input when I am in evil-input mode. However, when I type relatively fast when typing the I get thd. This is just an example, some other "typos" occur as ...
0
votes
1answer
62 views

Regex to handle unicode strings in evil mode

I'm using evil mode on Emacs2 27.1 on OSX. My goal is to search and replace some text containing unicode strings using either of emacs' replace-regex or vim's search/replace functionality. To begin ...
1
vote
0answers
21 views

show which package repo was used to obtain a package

I'm trying to submit a bug report to emacs-evil, and they ask me from which repo evil was installed. I'm just using the version that came bundled with doom-emacs. How can I know which source was used ...
0
votes
2answers
77 views

pipe result of elisp function to a shell command

I wanna pipe the output of an elisp function (emacs-version) to a shell command (xclip). How can I do this? I accept vanilla emacs and evil solutions.
0
votes
0answers
184 views

Adding a custom keybinding in Doom Emacs

I am using evil-mode and am very new to emacs and doom. How would I be able to map Ctrl-s to :w or save. Also, how would I be able to bind Ctrl-n to neotree-toggle? I have been searching and trying ...
0
votes
0answers
30 views

centered cursor with evil-window-bottom and evil-window-top

I'm trying to achieve both: persistent centered cursor (cursor stays in center of a window except when near the line 0 and count-lines-page augment the way evil-window-bottom and evil-window-top work ...
0
votes
1answer
44 views

doom-modeline module with line(w) status

As the title implies, what package or feature does line(w) denote? When active, it deletes lines in evil-insert-state upon pressing Enter and then i immediately afterward.
0
votes
0answers
41 views

Configure ryo-modal to execute function from evil-ex-commands alist

I would like some help in configuring ryo-modal, via use-package, to run a command from the evil-ex-commands alist, using ("ll" (cdr (assoc "wq" evil-ex-commands))); however, I'm ...
0
votes
0answers
33 views

Pass keymap as an argument to a function

I have the hard time straggling of passing elisp keymap to a custom function. I expect that after major mode has loaded (in my case it's clojure-mode) my new keybindings become available, but they don'...
0
votes
1answer
50 views

Swap TAB and Escape in all modes including evil

Escape is too far away on modern keyboards and Tab could be easily typed as Ctrl+i in terminal applications. So I found it convenient to replace them in my alacritty terminal key bindings. I am used ...
0
votes
0answers
113 views

From stock Emacs to Emacs Doom - Issues with Key Bindings and de-activating Evil-mode - ORG-MODE use

I have migrated to emacs-Doom and wish to keep the emacs vanilla key-bindings. I also use emacs exclusively for org-mode I have amended the init.el file to remove the evil and removed any attributes ...
1
vote
1answer
34 views

c w movement up to next word instead of end of word

In vi, c w stops at the end of the current word (that movement is normally e, as in c e). This is different from w alone or d w, which go up to the beginning of the next word. A popular Vim ...
0
votes
1answer
18 views

evil-mode exec register ignores pipe

In vim, assume :r!ls | grep foo is in the register l. You can then do: @l to exec ls | grep foo and insert the contents matching foo in to the current buffer. In evil-mode I get: Usage: grep [OPTION].....
0
votes
0answers
261 views

Getting the TAB key to work the same in Doom as in Spacemacs

When using the TAB key in a magit status/overview buffer, it says: Buffer is read-only. If I manually disable read-only mode, the pressing TAB indents the text instead of expanding or contracting ...
0
votes
0answers
56 views

Autoloading of evil fails: failed to define function evil

I get the error: run-hooks: Autoloading file /home/xxxx/.emacs.d/elpa/evil-collection-20210203.811/modes/unimpaired/evil-collection-unimpaired.elc failed to define function evil at startup. Here is ...
0
votes
1answer
47 views

How to save vim registers in evil mode for use after restarting emacs

In evil mode, I can save text in named registers with "ay etc. These registers are lost whenever emacs is restarted. Is there a way to save these registers? Vim seems to do this automatically.
0
votes
0answers
59 views

Can I combine key-chord-mode with evil-define-key?

I like to use evil-define-key like so: (evil-define-key 'normal projectile-mode-map (kbd "M-o") 'projectile-switch-to-buffer) This is great because I can make bindings for both an emacs ...
0
votes
0answers
23 views

Programmatically call evil-search-forward and then paste

How do I create an elisp function to call evil-search-forward and then paste to search for the last text yanked/copied? I've tried calling commands such as evil-paste-after or yank (see below) but ...
0
votes
0answers
7 views

How can I make the cursor place properly when hitting enter inside an empty object, without exiting “insert mode”

This is mainly for js2-mode, but would love to have it in python or other programming languages as well. I would like to have the cursor placed as seen in the below image when hitting enter inside an ...
0
votes
1answer
39 views

Execute function by using evil-set-register

I use evil and I want to execute a function by using Emacs macro system. Let's say I have the following macro. (evil-set-register ?f [?i ?f ?o ?o ?b ?a ?r escape]) I can run the macro by using @f. ...
0
votes
0answers
23 views

Symbol Highlight Transient State select all words

I am using Spacemacs. I want to move between variables easily and while using #spacemacs/enter-ahs-backward function. I want to select the even word near of some special characters like $!:<> ...
0
votes
0answers
37 views

Adding custom text above and below a buffer

Is there an easy way to wrap a buffer in emacs with text of my choice? For e.g if my selected buffer is like this, This is the first line of a verse with । And here comes the second line ॥ 1.2 ॥ I ...
0
votes
0answers
27 views

Echo area in Evil mode

I was wondering if it is possible to convert the echo area into something like what you get when you press C-f after : (in ex-mode)? One of the packages I am using gives me a modifiable (long) string ...
0
votes
1answer
254 views

Search and replace in evil mode

I'm an emacs newbie and am using evil mode for text formatting. I have some text in the following format: word1 = meaning with elaboration; word2 = simpler meaning; word3; word4 = much long ...
0
votes
2answers
32 views

How to act on the currently highlighted search result with evil mode?

When using evil mode search, is there a way to act on the currently highlighted search result by... Converting it into a selection. Treating it as a text object. Having the ability to specify the end ...
1
vote
2answers
201 views

Make Evil Mode “s” key behave like Vim

Doom Emacs' s key does not behave like Vim's implementation. In Vim, s deletes the character under the cursor and puts you into insert mode whereas Evil Mode performs a search, similar to f and t. Is ...
0
votes
0answers
11 views

Can't run command using C-. keybinding with Evil

I'm trying to use racket-mode for programming Racket. One of the racket-mode commands is bound to C-c C-. (control c, control period). However, whenever I try to press C-c C-., it appears to get ...
0
votes
1answer
131 views

Leave evil's insert state with Control + c

I would like to be able to leave the insert state (I think that's what it's called in emacs?) using the Ctrl+c combination I know from vim. I'm using doom-emacs in case that's important, and I'm ...
0
votes
0answers
63 views

How to set leader-key-like chord sequence in Evil mode?

I am using Spacemacs with evil mode and this works: (define-key evil-normal-state-map (kbd "m") 'set-input-method) However, I would like to use something like this: (define-key evil-normal-...
0
votes
1answer
32 views

How can I move the cursor from a shell window to another window in Evil mode?

Imagine I have following four windows in Emacs: Window 1 is a shell window (M-x shell). Windows 2, 3, and 4 are normal windows with files open. Evil mode is enabled. If I am the shell window, how can ...
0
votes
1answer
105 views

How can I re-enable `C-z` in evil mode (to pause Emacs)?

I have been using Emacs for a while and recently started using evil mode. I exclusively use emacs-nox (command line emacs). The only thing that's missing for me is C-z to pause emacs and bring me back ...
0
votes
1answer
60 views

Any way to remap the meta key with evil?

Function modifiers in Emacs conflicts with many hotkeys I have (for example, conflicts with i3wm). By using evil I could use evil to avoid most of conflict hotkeys. However, I do still need to use ...
0
votes
3answers
137 views

elpy (and evil-mode) do not react on TAB

This is my elpy-config 1Elpy Configuration 2 ...
3
votes
2answers
306 views

Improve emacs performance when working on large files

I'm a former vim user that switched to emacs + evil with a still relatively simple configuration with only 36 packages. I'm really happy with the additional functionality emacs delivers, but one thing ...
0
votes
2answers
64 views

How to loop over keymaps and assign keys?

If I have a key binding I want to apply to multiple keymaps, for example. (evil-define-key 'visual c-mode-map (kbd "C-M-?") 'c-comment-from-c++) (evil-define-key 'visual c++-mode-map (kbd &...
0
votes
2answers
297 views

How do I auto save evil buffers for specific file types?

I'm a new Doom Emacs user that can't get used to having to save files manually. I found a way to auto save evil buffers, but the problem with this approach is that I'm not able step out of vterm (an ...

1
2 3 4 5
10