Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [evil]

Evil Mode is a Vim emulation layer for Emacs.

3
votes
0answers
12 views

xref gets confused by similar class names

If I use evil-jump-to-tag or xref-find-defintions on an inherited class module whose name is the same as a class in my current project, I am taken to the definition in the current project. I would ...
0
votes
5answers
37 views

How to define action to happen on triple key press?

I'm using evil mode. I'm looking for a convenient way to type German language Umlaut characters (ä, ü, ö, Ä, Ü, Ö, ß) while using an English US keyboard layout. One idea that came to mind was to ...
1
vote
1answer
26 views

How does one save and close a file in Proof General without all of Evil shutting down?

I am using evil (emacs+vim). I am also using Proof General for the theorem prover Coq. I was trying to work with emacs but whenever I do: :x or :q in my coq .v file all of emacs closes as well (...
2
votes
1answer
45 views

When using `lisp-state`, how can we repeat an action like slurp, and bind a key to easily perform the repeat?

In vim, I frequently used the "." shortcut for repeating the last command. I found this extremely useful especially when working with clojure tools to do things like slurp-ing and barf-ing to refactor ...
0
votes
1answer
23 views

evil mode j and k moves between paragraphs instead of lines on markdown and text modes

evil mode j and k in markdown and text modes moves down paragraphs (and sometimes to other arbitrary points down/up the paragraph) instead of up and down a single line. How can I change this behaviour?...
1
vote
1answer
19 views

Emulate vim modeline in evil mode

As a background, vim modelines is a magic comment in the text file that sets some of the vim options. It is similar to emacs' file variables. A modeline like ;; vim: set expandtab : in a lisp file ...
-1
votes
0answers
37 views

Using PCRE regexes in evil mode search/replace

I have evil-mode installed and am trying to get PCRE regexes working everywhere. I currently have pcre2el installed (https://github.com/joddie/pcre2el) and evil mode installed as well. I also have ...
-1
votes
0answers
18 views

Add minor mode which override evil shortcut

I want to create a minor mode to resize windows in emacs, like the resize mode of i3. I try many things, but evil shortcuts always override my minor mode... My minor mode: (defvar my-window-resize-...
0
votes
2answers
22 views

How to change to evil-insert mode when there is no hook?

I'm trying to change evil-org to evil-insert-state when I add a note to my org files. I've tried to look it up, but can't figure it out. I've configured org-mode to always query me for a note after ...
0
votes
1answer
32 views

How can I get RET to follow org-mode links when using evil-mode?

In org-mode, the link-following behaviour of RET, that should be present when org-return-follows-link is set, doesn't work in evil-mode. MWE from emacs -q: Load an org buffer containing a link. Note ...
0
votes
1answer
57 views

How do I override a keybinding defined by evil-mode?

I've searched for this before but I've only seen questions like the below: https://stackoverflow.com/questions/683425/globally-override-key-binding-in-emacs How to override major mode bindings I don'...
0
votes
1answer
26 views

Making Emacs show the last part of bash-command output

I use the Evil mode inside Emacs for doing a lot of my work. If I need to run a shell-command and see its output all I need to do is type in normal mode :!<bash command>. The window splits into ...
0
votes
0answers
13 views

Apply vim macro to files in helm-ag result?

I am using spacemacs (using evil mode) and want to apply a vim macro (keyboard defined or otherwise) to the files resulting from a search in helm-ag. I'm thinking the easiest way would be to apply a ...
0
votes
1answer
22 views

How to enable bracket navigation in evil mode?

Vim mode has [ ] keys to navigate brackets. See this example. Eg, selecting a comment block can be done this way in vim: [/ v, % Is this possible in emacs with evil mode?
0
votes
2answers
163 views

How can I use multiple cursors in evil/spacemacs

There are multiple multiple-cursors implementations for emacs. I have the impression that extra work has been required to make them work well in evil and spacemacs in particular. I imagine the ...
1
vote
2answers
49 views

Prevent any form of ESC from closing a magit buffer

I'd like to be able to prevent Magit from closing a buffer when I press ESC. I also want to prevent my evil-escape-mode sequence (kj) from closing it as well. Running C-h k ESC gives <escape>...
1
vote
0answers
27 views

Fold all methods in a Python class with Evil

How can I fold all the methods in a Python class? I use Evil and would prefer a pure Evil solution, if possible. I'm looking for a quick way to take something like this: class LongClassIDidNotWrite(...
1
vote
1answer
43 views

Accidentally disabling evil mode in spacemacs

While use spacemacs in evil mode, I sometimes accidentally disable evil mode and I do not understand how I am doing it. And once disabled, I do not know how to reenable the mode without restarting ...
0
votes
1answer
37 views

Evil Mode, how to rebind the caps-lock key to go into normal mode

In addition to the Escape key, I would like to go into Normal mode while editing by pressing the caps-lock key. How do I achieve that? Thus far I have been able to disable the Caps-lock key using ...
0
votes
1answer
20 views

Case insensitive find character in `evil` and `evil-easymotion`

I wonder whether it is possible to make f in evil and/or in evil-easymotion case insensitive?
0
votes
1answer
50 views

Cannot open remote file

I am trying to open a remote file in spacemacs in evil mode on windows using SPC f f. This pops up helm and entering /ssh:myuser@myhost/folder/file.txt produces Wrong type argument: stringp, nil In ...
0
votes
2answers
91 views

how to define an evil-operator to move forward/backward a text-object?

I am trying to define a function that moves to the begin/end of current text-object. First - I define an operator: (evil-define-operator evil-forward-text-object (beg end type) "move to end of ...
0
votes
0answers
7 views

Defining incomplete pairs with evil-surround

Using evil-surround, one can transform word to <em>word<\em> with ysiw<em>. I wonder if there is a general way of defining an incomplete pair (to be completed by em etc.), such that ...
0
votes
1answer
161 views

How do I install the evil package?

First time emacs user trying to install "evil mode". I'm attempting to follow the instructions at https://blog.aaronbieber.com/2015/05/24/from-vim-to-emacs-in-fourteen-days.html. I installed emacs on ...
2
votes
1answer
68 views

How can I make terms searched with `*` or `#` populate the search history?

In my attempt to have * and # work in Spacemacs as they do in Vim, I've followed the solution posted at this question. Those keys now work, but there's one hurdle more to overcome: the searched term ...
1
vote
1answer
69 views

Setting C-p as helm-projectile-find-file

I put this at the very end of my config file: (global-set-key (kbd "C-p") 'helm-projectile-find-file) On Emacs start I can see that it is getting assigned using C-h k C-p. Then when I actually load ...
1
vote
0answers
69 views

How to make Lisp state a default instead of normal?

I'm learning Clojure and Emacs at the same time 🤕 I use Spacemacs with Evil. Recently I've learned about Lisp state and I find it very handy. The only problem is that whenever I switch to insert ...
4
votes
2answers
108 views

Help! Emacs empty my 1 year org file

I have used Emacs Org mode for my notes for several years, and I use Prelude configured with evil. Everything works fine. Until a few minutes ago, I found the note file is empty of content. and the ...
0
votes
0answers
14 views

Surrounding a word at point with `evil-surround`

Using evil-surround, how could one craft a function to surround the full word at point with \(..\)? One might start by adding the bind i (which stands for "inline" or "latex inline math mode") to ...
2
votes
1answer
49 views

Assign TAB in markdown mode

Running emacs 25.2.2, general, evil and markdown-mode installed from MELPA. The problem is when I hit TAB on a heading in a markdown file, it does not cycle visibility of content. C-h k TAB shows it ...
0
votes
2answers
120 views

How to unhighlight after searching in evil mode?

I have a text file opened in Spacemacs with evil mode on. When I search for a term by means of /term [Enter] then found "term"s are highlighed. How do I remove that highlighting? I tried / [Enter] - ...
0
votes
0answers
53 views

Define keybindings for org-agenda starting with SPC

Using emacs 25.2.2, general, evil and evil-collection from MELPA. I have the following in my init.el: (general-unbind 'org-agenda-mode-map "SPC") (general-create-definer my-leader :prefix "SPC")...
0
votes
1answer
42 views

C-x and M-x remapped to SPC and SPC-SPC

What would be the best way to configure Emacs to handle the above keybindings for vanilla Emacs? Specifically, I'd like to have SPC work as C-x and SPC SPC work as M-x. I love Spacemacs for the ...
0
votes
0answers
46 views

org-mode + evil: insert heading, set cursor to line ending, and change to insert mode?

I am using spacemacs which contains org-mode and evil. Whenever I insert a heading (either org-insert-heading, org-insert-heading-after-current or org-insert-subheading), I have to do two extra ...
1
vote
0answers
27 views

How to avoid entering visual mode when clicking a link while using evil?

Emacs newbie here using spacemacs. How to avoid entering visual mode when clicking a link while using evil? This is particularly problematic in org-mode.
1
vote
1answer
26 views

Evil mode leave insert state if save via I C-x C-s?

I use evil-mode (specifically in spacemacs) working in org-mode documents. Many times, after evaling code via C-c C-c or exporting via C-c C-e, I find myself saving via C-x C-s (old habits die hard). ...
4
votes
2answers
65 views

How to replace an object with selection?

In Evil mode, is it possible to prevent change and deletion commands from putting the replaced object into the selection (system clipboard)? I would like yanking to still do so. I'd like to be able ...
0
votes
1answer
49 views

Unable to use ediff with emacs and evil due to window configuration

Running emacs 25.2.2 with evil installed and updated from Melpa. When I run ediff, it asks for usual buffer A and buffer B and then ONLY the ediff buffer in its own frame is visible with 'Type ? for ...
3
votes
1answer
43 views

Ignore tags in `org-end-of-line` and similar motions

Is there a convenient function for jumping to the last non-tag character in the line of an org-mode heading? For instance... * This is |my header :tag1:tag2: I would like a command that moves ...
3
votes
1answer
181 views

spacemacs key bindings in plain vanilla evil emacs

As the title suggests, I would like to use spacemacs like keybindings in plain vanilla evil emacs. The spacemacs key bindings are very intuitive. But the package is too heavy for my low-end laptop. ...
0
votes
1answer
32 views

orgDefine a keyboard binding that works only in org-agenda when under evil

Using emacs 25.2.2 on Kubuntu 18.04 with evil and evil-org. Here is a very basic question that I could not get a clear answer for, despite googling. I want to define a keyboard binding that works ...
0
votes
1answer
30 views

Evil pastes after point

Evil pastes after point; How do I make it paste at point? 123456|789 Current behavior: 1234567sth89 Desired: 123456sth789
0
votes
3answers
38 views

Change Case of last searched pattern

Is there a fast way of changing the case of the last searched pattern? Inside Evil mode, I press # key to quickly search for keywords at point. And I want to change the case of all occurences of ...
0
votes
0answers
157 views

Evil mode not working

Using emacs 25.2.2 on Kubuntu 18.04. Using list-packages I installed evil. Using customize-variable I added (evil-mode t) in my ~/.emacs.d/init.el file. But still when I restart emacs, there is no ...
0
votes
0answers
20 views

Enable Evil jump to work across all panes instead of only active pane

Is there a way to enable evil-jump-forward and evil-jump-backward to use the jump list of all panes instead of only the active pane? In the gif below, here's what happens: Start on left pane at ...
0
votes
0answers
39 views

How to convert a region into a Python function?

I'm using emacs with evil and anaconda mode for Python. Sometimes I'd like to convert a region or a block of selected lines into a def (or for/while loop, or class). Is there a way to do this ...
0
votes
1answer
122 views

Unwanted indentation in org + evil

From an org heading, pressing evil o will open a new line that's indented according to the heading (org level + 1 spaces). Can this behaviour be turned off?
0
votes
0answers
25 views

How do I use the primary, not clipboard buffer?

Aka the equivalent of xclip -o -selection primary, not xclip -o -selection clipboard. primary is selection, clipboard is Ctrl-C usually.
0
votes
1answer
58 views

Add dired buffers to evil jump list

I want dired buffers to be included in jump list so I can visit them with Ctrl-i and Ctrl-o. One possible catch is that My Ctrl-x d binding is taken by ido-dired. What I've tried so far (without ...
1
vote
1answer
42 views

Spacemacs Evil mode does not have :for?

I tried to use :for num in [1-30] today in my spacemacs evil mode. But it says Unknown command for Are :for and such command an extension to Vi that is not available for Spacemacs Evil?