Need advice about which tool to choose?Ask the StackShare community!
Kakoune vs Neovim: What are the differences?
Introduction:
Kakoune and Neovim are both powerful text editors with unique features and functionalities. While they share similarities, they also have significant differences that set them apart. In this Markdown code formatted document, we will highlight six key differences between Kakoune and Neovim.
Modal editing vs. Normal mode: One of the primary differences between Kakoune and Neovim lies in their approach to editing modes. Kakoune follows a modal editing philosophy, where users switch between insert, normal, and visual modes to perform different actions. Neovim, on the other hand, primarily focuses on the use of normal mode with some support for other modes. This fundamental difference in editing modes ultimately shapes the overall editing experience in each editor.
Multiple selections vs. Vim-style selections: Kakoune boasts a feature called "multiple selections," allowing users to make simultaneous edits in multiple places within a document. This can be convenient for tasks like refactoring or making similar changes. Neovim, inspired by Vim, employs a different approach with its Vim-style selections. Although they may not provide the same level of flexibility as Kakoune's multiple selections, they are still versatile and can be powerful for more targeted editing tasks.
Extensibility and scripting languages: Another important difference lies in the extensibility options and scripting languages supported by each editor. Kakoune offers an expressive scripting language called KakouneScript, which allows users to customize and extend the editor's functionality to a great extent. In contrast, Neovim provides support for a wide range of scripting languages, including Lua, VimL, Python, Ruby, and more. This flexibility in choosing scripting languages can be advantageous for users with specific preferences or requirements.
Tab-based vs. Buffer-based editing: Kakoune primarily operates on a tab-based editing model, where each tab can contain multiple buffers. This approach allows users to manage multiple files within a single editor window efficiently. Neovim, on the other hand, focuses on a buffer-based editing model, with each buffer representing a loaded file. While tabs can still be used in Neovim, the emphasis is more on manipulating buffers, which may appeal to users who prefer a file-centric editing workflow.
Community and ecosystem: Kakoune and Neovim also differ in terms of their respective communities and ecosystems. Neovim, being a fork of Vim, benefits from a large and established community with extensive plugin support. This means that Neovim users have access to a wide range of plugins, themes, and configurations readily available. Kakoune, being a relatively newer project, has a smaller but growing community. While it may not have the same level of plugin support as Neovim, it can still be customized and extended to suit individual needs.
Built-in terminal emulator: Neovim incorporates a built-in terminal emulator, allowing users to seamlessly interact with shells and command-line programs without leaving the editor. This can be particularly useful for tasks that require a combination of text editing and running commands. Kakoune, on the other hand, does not have a built-in terminal emulator. However, external terminal emulators like tmux can be used in conjunction with Kakoune to achieve similar functionality.
In summary, the key differences between Kakoune and Neovim lie in their approach to editing modes, multiple selections vs. Vim-style selections, extensibility options and scripting languages, tab-based vs. buffer-based editing, community and ecosystem, and the presence of a built-in terminal emulator in Neovim. These differences encompass fundamental aspects of the editors and are essential considerations for users when choosing which editor aligns best with their workflow and requirements.
For a Visual Studio Code/Atom developer that works mostly with Node.js/TypeScript/Ruby/Go and wants to get rid of graphic-text-editors-IDE-like at once, which one is worthy of investing time to pick up?
I'm a total n00b on the subject, but I've read good things about Neovim's Lua support, and I wonder what would be the VIM response/approach for it?
Neovim can basically do everything Vim can with one major advantage - the number of contributors to the code base is just so much wider (Vim is ~100% maintained only by B. Mooleanaar). Whatever you learn for Neovim you can also apply to Vim and vice versa. And of course there is the never ending Vim vs Emacs controversy - but better not get into that war.
Actually, the biggest advantage with Neovim (as a VS user) is that you can embed REAL Neovim as the editor UI, rather than using a "Vim emulation", you're using actual NVIM, embedded in VS!
"asvetliakov.vscode-neovim" is the extension you are looking for:
- Install the 'vscode-neovim; extension (https://marketplace.visualstudio.com/items?itemName=asvetliakov.vscode-neovim)
- Install Neovim version 0.5+ nightly
- Start winning.
(You can install neovim-nightly separately for just vscode, I usually build and install it to /opt/nvim - it's enough enough to do - let me know if you need help).
Works wonderfully. It might not work out of the box if you have some 100K epic nvim initialization file, but the plugin documents a workaround for having an embedding/VS specific configuration.
I don't actually notice much of a difference between the two, as the end result looks identical. If you use Vim and are switch to Neovim it's an extremely easy 1-minute process. I switched from Vim to Neovim. I can't say I found much of a difference, but the key points where Neovim could be better than just vim is that first, there are much more people maintaining Neovim compared to vim, which means fewer bugs and a modern code base. It also has a smaller code base which might result in a small speed improvement. Another thing is that it's basically just a fork of vim, so what harm can it do? ;)
I recommend using vim 8+
it has native plugin support
if you need language supports you can install the package vim-nox
which will come with support for python, lua, ruby, etc
The hints on the codebase's contributors and the VSCode integration helped me make up my mind.
I really appreciate all comments, though.
Thanks a bunch!
It truly depends on whether you want to completely avoid GUI and stick to TUI and command lines. If you want to edit all of your codes within a terminal, then Vim or neovim would be the choice. Emacs can be run in a terminal, but the functionality is limited. Most people use Emacs using GUI and emacs-client not to use too much memory.
My general preference is to use an independent text editor, which is better if it is highly customizable and programmable. So, I have used Emacs for several years. For beginners, I guess Emacs requires significant time to learn to fully enjoy its wonderful functionalities. In that sense, using atom would be a recommendable option.
Regardless of all the situations, learning basic vim in the terminal will help you in any case. In summary, I recommend 1. vim as a default editor in the terminal 2. atom if you are a beginner, or 3. Emacs if you have a long-term plan to master a programmable editor
Other editors like sublime text, VS code, and so forth are also worth learning and using. But, no matter which editor you choose, stick to one or two until you become an advanced user. Being able to use most text editors at an intermediate level is waste of time.
I hope it helps.
Pros of Kakoune
- Multiple selections7
- Fast editing7
- Interactivity5
- Consistency of the underlying language4
- UNIX citizen4
- Self documented3
Pros of Neovim
- Modern and more powerful Vim31
- Fast27
- Asynchronous plugins22
- Stable20
- Edit text fast18
- Great community15
- Vim plugins work out of the box15
- Embedable9
- Unix-like8
- Built-in terminal support8
- Plugins in any language4
- External GUIs2
- Great Colorschemes2
- Extremely customizable2