Hacker News new | ask | show | jobs
by jb1991 56 days ago
I used emacs full-time for many many years. Then I switched to Vim or other editors with Vim modes, also for many years. I have to be honest, I don’t see a particularly clear winner between them. Model editing is a bit unusual in many ways. There are some things that it certainly makes easier, but I personally found that the overall process of editing and writing code in real time for me was more efficient in a single mode emacs.
2 comments

> I don’t see a particularly clear winner between them

Because deep down they are incomparable categorically. Separate the tools from the foundational ideas and you see the very different value. Vim-model of text navigation is fantastic, practical, brilliant idea. Once you grok it - you can take it anywhere. You can use it in your editor, browser, terminal, WM. Emacs is rooted in another, even more brilliant idea of practical notation for lambda calculus. These ideas have no overlap. But understanding the philosophy of each (ideally both) could open so many different possibilities.

Why not both? Evil is a reimplementation of Vim in Emacs and it is great.
Evil is not just great. It's the only "true" vim layer outside of vim/nvim worth commending. Gary Bernhardt once said: "there's no such thing as vim mode", in the sense that every single attempt to emulate vim outside of vim/nvim is a bleak imitation. None of them - not a single VSCode vim plugin, not Sublime's, not IdeaVim in IntelliJ, no browser extensions are without some glaring omissions. While Evil+evil plugins in Emacs are not just 'close' - they are better than the source of inspiration. Gary just probably didn't know that.
I used evil for about one year actually.
You can take modal editing anywhere, but that doesn't mean you should.
Huh. So what do you think "modality" is? Emacs is inherently a modal editor. Transients, isearch, chords (when it expects another key after C-c or C-x) - that's all modality. VSCode has tons of modal features built-in - multi-cursor/selection state; snippet tab stops, rename symbol, breadcrumb nav - all that modality. Submlime has a genuine first-class modality built into its core.

The idea of vim navigation simply offers some structure and mnemonics - why should I learn hundreds of different ways to deal with text in every app, if there exists an established, well tested, popular way that can simplify it all?

My vim muscle memory has paid off more for me than my emacs muscle memory. Emacs was the better editor, though. Anything that doesn't have Vimscript is an automatic winner IMO.
I use ^a to go to the beginning of a line and ^e to go to the end nearly everywhere. Many Emacs keystrokes are so pervasive that they're not often thought of as Emacs keystrokes.
Aren't they actually readline keystrokes, and emacs is "readline-aware"?
I'm pretty sure the navigation shortcuts date back to when Emacs was literally just a set of TECO macros, and GNU Readline adopted them
Yep. Readline’s modeled after what Emacs was already doing.
Strangely enough I tried using vi mode for readline and hated it even though I use them constantly in vim. I just hated having to switch modes on my terminal
The thing about emacs and muscle memory is that all of the standard emacs keyboard shortcuts are also the standard all throughout the Mac operating system, so when you’re writing in text boxes in a webpage, writing in a Google doc, anywhere you type, throughout macOS, it’s emacs shortcuts. That has a lot to do with building my muscle memory.
Evil is a tried-and-true Vim implementation that doesn't use Vimscript!