1

I'm a current Neovim user who happens to be interested in Emacs. I like Org mode, as well as some other features of Emacs. However, every time I've tried to use evil mode, it's felt crippled. (The Emacs side has been fine, however.) The reason for this, I believe, isn't that Evil is an imperfect vim implementation, but that I would never in a million years want to use stock vim for editing. I use lots of plugins for vim (35 at the moment), and most of them don't have an equivalent in Emacs that works fluidly inside of evil mode. I've tried spacemacs, and it's also not really satisfying. I believe, however, that there is a good solution to this problem:

Neovim, as a project, makes vim better-suited to be used as a component in an IDE. It can be run inside of other programs rather cleanly. Some examples of projects using this functionality are NyaoVim and ONI vim, as well as some projects which use Qt, Electron, etc. I would like to know if anyone has tried to run Neovim within Emacs, or if it's likely to gain some attention soon. It would be wonderful to have Neovim work inside of Emacs so that I could use Emacs as my development environment, then use standalone Neovim for other purposes, all with the same configuration and functionality.

Edit: (not sure if this should be in main post or a comment)

I now use spacemacs (emacs with a configuration that gives it better evil integration and makes it more useful out of the box), and have found that evil suits the vast majority of my needs, and I don't miss vim much if at all. One of the things I miss is the way that keybindings were handled. map, noremap, nmap, nnoremap, inoremap, etc. were all so easy to use and had their own syntax, true to the composable nature of vim's keybindings. However, the modes really are different in emacs. Transient states are great in spacemacs, so is the major/minor mode setup. I would still love to see the neovim team get their editor ("the future of vim") to lower the barrier of entry to arbitrary programs having vim keybindings by simply allowing programs to connect to a neovim backend. That would be great in my opinion. Evil really isn't vim, but it allows you to use most of vim with emacs. However, for now, Spacemacs is great, and offers the strength and ease of configuration of emacs.

  • Please clarify what your question is. – Dan Jan 17 '17 at 14:21
  • Is it currently possible to use Neovim inside of Emacs? If so, what are some difficulties that need resolving? – mckryall Jan 17 '17 at 14:23
2

Imagine a disclaimer about future predictions usually being flat-out wrong

I consider it rather unlikely to happen. The reason one implements Vim in Emacs is to have first-class integration into it. In Evil, you can customize a significant amount of tunables (the most important one being the list of modes per initial state as it makes or breaks your editing experience), extend it by writing your own hook functions and inspect its current state and code to write your own packages for it. You would have none of that in a Neovim client for Emacs.

  • All that's really needed is a way to switch between Emacs and Neovim, though. A state on Emacs' side for Neovim to attach to. Then, all the tunables are separate. The point about hooks is a good one, but I believe that Neovim passes information when used inside of another program that allows for exactly that. And, as well, first-class integration and tunables can't match having all of the vim/neovim plugins and community available. – mckryall Jan 17 '17 at 9:01
  • On another note, I'm not saying that there aren't useful and interesting things that you can do with something fully integrated like evil, but rather that having "full" neovim is often more important from an everyday productivity and usability perspective. – mckryall Jan 17 '17 at 9:10
0

Yes, you can run Neovim inside Emacs. Type M-x term <ret> and enter nvim <ret> at the prompt. Viola, Neovim inside Emacs.

  • I experimented with running vim (not nvim) within term and saw that term-mode has problems updating and interpreting certain characters in the popular plugin known as nerdtree. I do not know whether nvim will have better luck. – lawlist May 9 '17 at 1:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.