212 comments

[ 2.8 ms ] story [ 249 ms ] thread
> It's less a war at this point than a grumbling shuffle of ingrained habit and stubborn resistance to change.

That is just silly.

I have VSCode and the JetBrains IDEs on my desktop, but Vim is _everywhere_ I work - even Windows servers if desired. If I'm working on a server, or another workstation, I can use a common editing environment.

There is nothing stubborn about it, consistency is powerful.

That's exactly the point; the very first section header is:

>Vim: The high availability IDE

It's not merely nostalgia or availability. I continue to use emacs because it has the features that I want, where other software does not.

Some things I want out of an editor:

* Never having to touch the mouse in any way.

* The ability to customize any feature for my current project or mindset on a whim.

* No UI, as much as possible. Show me the content I'm editing and nothing else.

* A good, extensible, set of keybindings with a bunch of features for editing of raw text

I run my project in an IDE and will sometimes use a feature, but I generally don't develop there.

The great thing about both Emacs and Vim is that you can "customize any feature." All of the other things you're looking for just naturally flow out of that.
The extensibility of Emacs is a major boon. Here an example: I never did real Emacs hacking, but I learned some Lisp stuff over the years, a bit of Clojure, Racket, and Common Lisp each. Now, I have a very experienced senior coworker which was asking for help - there was a feature which was just not working for his flow, he had tried to configure it but without success. Now, I looked into the Emacs library code and that was a pleasant experience, it is very transparent and readable and easy to modify, so that it was not difficult to adapt it to my coworkers's needs.

The extensibility also means that, because there are many many people hacking on Emacs, that it stays very up-to-date. For example, Magit which is, I think, the best git front-end in existence. Or there is ranger mode, (ranger is a console file manger). In this sense, Emacs is not "antiquated", as the blog article insinuates, but it is much more recent and modern than any IDE. Take, as an example, git support: It took Visual Studio about fifteen years to add git support, in part obviously because the vendor company did not think supporting git was helpful to the companies objectives. In comparison to that, Emacs picked up version control options such as subversion or git almost immediately. As a result, Visual Studio users were left for fifteen years without support for the perhaps most important technical advance in programming. You may now argue, that the "modern" IDEs of course do have support for git, but there are surely other things which will be missing, just because it does not fit some companies narrative or marketing strategy. Another brewing revolution is that programming culture is drifting away from C++ and Java, in parts even from OOP, which is not any more the best option for every case, and companies which are invested in these "technologies" (uh, what a word), will again try to stop the clock, in order to squeeze a bit more money out of it.

I would add to your list of features: it runs from the comfort of the command line, and cleanly inside the terminal.
5) Starts up _right now_, and uses up minimal memory.
I got into vim due to all the hype. It's not the best for me but knowing it is a huge win. If I'm in the terminal on a remote PC I have a powerful text editor ready to go.
Plus, with extensions, it’s easily a huge vim as well.
One word: latency. As software gets more convoluted the UI latency increases.
I have to second this. I've been using PyCharm for the last 6 months after 25 years as a primarily-Vim user (I've used various IDEs over the years before and during). The features of PyCharm are undoubtedly very useful, but actually typing code is like swimming through molasses in comparison.
Haha I use VSCode set up with Spacemacs keybindings...that way I get the best (and worst) of all 3 worlds (:
Similarly, I use vsvim. I like vim, it’s much more responsive, but setting up vscode to work with debuggers and external tools is so much more streamlined. I do desktop, web and embedded development and have never spent more than half an hour setting everything up. This isn’t true for vim.
Why wouldn't we use them?

- FOSS, That means we don't have to pay money to be allowed to code by somebody else

- Available everywhere, even in terminals

- Low resource usage, so I have more available for the other tools I need to use (browser, chat, vm, compiler, streaming...)

- Fast, they are extremely fast at editing code, with low latency

- Easy to extend, at least Emacs is, you write a function in a file and boom, done

- Feature rich, at least for some languages like Ruby there is nothing commercial editors offer you that you don't already have, or 99% there

- No mouse needed, so my wrist does not hurt anymore.

- No spyware, seriously, why do I have to disable google anlytics in my code editor, and keep an eye out in case an update re-enables it

And the "price" you have to pay to use them? Just learn their keybindings, literally what you have to do in any code editor as each has their own, just that these two have more, and they're quite different compared to what you might already know.

Note, I've tried out many editors over the years: Visual Studio, Notepad++, Eclipse, Netbeans, Intellij and it's language specific clones like WebStorm and RubyMine, Sublime, Atom, VSCode, pure Vim, pure Emacs, and now finally Spacemacs. Only the last one managed to fit the bill for me perfectly, being feature rich, fast, and it stood out of my way when I needed to focus.

If they dissapeared over night, it might surprise you, but I would go back to Netbeans, for the same reasons, as far as I'm concerned, giving me just enough functionality and then staying out of my way when I need to do my work is what I value the most in them.

That being said, I acknowledge both Vim and Emacs have their quirks and baggage, but so do the others, and I preffer to deal with learning Vim movements compared to staring blankly at a screen until I remember where to click through menues.

My advice, use all of them, but take it seriously, dedicate x > 2 months to each one you would like to try and use them intensively, learn as much about their capabilities as possible. At the end choose what works best for you. And don't just use something because somebody else tells you (or makes fun of you because you're not on the latest trend). You are you, not them. It might not be what I would choose but why do you, or I, care?

> Why wouldn't we use them?

On an individual level: learning curve, company policy, integrations to dev ops flavor-of-the-week and the initial difficulty to extend the editor.

With that said, learning Vim is a good way to get exposure to a very different type of user experience in software. Plus, you may see an increase in productivity. I don't see that increase, but I at least gave it a fair shake 10 years ago.

My increase in productivity was because of the auto completion feature from Sublime that I could not turn off, I found myself typing two letters and then waiting half a second for the drop down to appear so I could select the word. When I tried making a Jupyter notebook for a presentation I was planning and tried to type code there I realized: "I don't know the syntax, because I never needed to learn it. If I present like this I'll look like someone who doesn't know how to code". Was really ashamed of myself at that point.

So I forced myself to write code in Vim without any plugins for two weeks until I could type fluently. I was in insert mode most of the time, and did not use hjkl movement naturally, but it worked wonders, I could write words without interruption, my thoughts flowed freely.

Then I tried switching back to Sublime and felt less precise. Like vim was this stone path I was walking with confidence, and Sublime this fluid river I needed to row a boat on. Also for some reason I noticed that when using Vim, my wrist would feel lighter, while switching back to Sublime and using a mouse my wrist would suddenly gain "pressure". That's when I made the switch to Vim permanently and started customizing it. Only switched to Emacs, and later Spacemacs due to poor "Find and replace in project" functionality.

Lets you code like the coders you see in movies and TV. It's like the difference between touch-typing versus hunt-and-peck. For when you have to make a lot of mindless code movements.
The word "still" turns a honest question into a loaded, ugly question. There's thousands of people who are starting to use vim today. You can ask, why do they? That is a relevant question. The question of why old users of these editors keep using them is mostly uninteresting.
Not to mention the condescension in calling them, right off the bat, “a grumbling shuffle of ingrained habit and stubborn resistance to change”.

Habit and sticking with something that works are, like, good things most of the time!

This presumption really bothered me too. The tone of the authors is very anti-vim without ever stopping to mention that vim can be dressed up with plugins, command line tools, unix philosophy, etc.

It appears that neither of the authors are developers... the quality of the article would have been a lot better if they hadn't stereotyped vim users so much / admitted there are legitimate reasons to prefer a text-based interface over a GUI for en editor in 2020.

I'm surprised that a company like Stack Overflow would publish such a narrow-minded article on their company blog... surely they have developers internally using vim they could have talked to...

I skimmed through the article and there's quite a bit more of this:

> This has led users to literally turn Atom into Vim, unable to let go of the past, unwilling to fully embrace the future of code editing.

> unable to let go of the past, unwilling to fully embrace the future of code editing.

W-what?

As the parent says, this sounds like a loaded question. In fact, it sounds just like som marketing departmetn which wants to promote some IDE is trying to gather reasons and possibly features which need to be added to some "competitor" IDE, in order to gather more market share. I write that because to me, the interest to actual answer to the question - why people use these open-source editores - seems somewhat thin.

But, as somebody who uses Emacs, why not use the attention for some Emacs marketing.

Before going on, I use Emacs mostly since about 22 years. I am also occasionally using vi (mostly for system administration) or mg (which is a very light-weight editor with basic emacs keybindings). I've also used a host of other tools, for example in some work environments there was really no other alternative than to use Visual Studio, or Eclipse, and in some the most practical thing to use was notepad++.

So, why Emacs?

At first, and something that might be interesting to beginners, basic editing in Emacs, such as to produce similar results to using notepad++, is actually quick to learn. It has a nice on-line tutorial and very good interactive documentation. The fundamental philosophy it has is that basic text editing is modeless, that is, one uses a (possibly large) number of key combinations to modify text, and the basic combinations are universal. And this is already the main difference to vi/vim, where the meaning of basic key commands always depends on the mode. Emacs does have modes, however, for advanced commands which modify different /kinds/ of text.

Emacs supports a large number of programming languages out-of-the-box, which includes anything you need to write for documentation. This saves a lot of time when setting up projects. It is also very quick to set up additional packages and modes.

Emacs and vi/vim both are based on the notion that code is text: They are optimized for text editing, and in my experience this is absolutely the right thing to do. I had the dubious pleasure to use several systems which use code as kind of point of entry to some kind of database or graphical system or whatever, and these are, universally, just a pain in the ass.

Compared to IDEs, Emacs loads and starts very, very fast. In cases where one want it even faster and don't need that many features, one can use emacsclient, or the mg editor, or, of course, vi. It is also possible to use Emacs in a text terminal, which is invaluable for remote work on servers or embedded systems, and it also has good support for the shell's job control: Running in terminal mode (starting with the "-nw" option), Ctrl-Z will bring you to the shell, and "fg" will bring you back to your Emacs session.

Agreed, the word "still" and quite frankly the rest of the article shows the author hasn't taken the effort to understand why someone likes something they don't like themselves.

This could have been an article written by a windows10 user who asks the question "why are so many people "still" using linux?". New people start to use linux today and quite frankly there's a lot of good reasons to use it over the newest windows. Obviously same can be said about vim.

because Vim is beautiful.
What I want from an editor:

1. no code completion -- rarely works well. To get it to work well, it requires set up, and when I start a project, I don't want to waste time setting anything up. Also, doesn't work for interesting things, like code generation. I realize most programmers rarely do anything like that, but I do.

2. Customizability -- emacs is super-customizable. Lisp is easy to understand and you can basically do anything.

3. No mouse -- I'm faster just using keyboard shortcuts

4. Runs in terminal or graphical -- When I ssh into a machine, I want to be able to use Emacs through the terminal

5. Orthogonal user-interface -- In Emacs, everything is a buffer. I can use the same interface to navigate through Emacs 'configuration' as I can through my code. I can use the same interface to navigate through the Emacs terminal emulator as my code as well. This is amazing. Contrast this to 'newer' editors like Sublime or Eclipse, where the configuration dialog, git interface, etc, are all custom UIs. To understand why this makes a difference compare and contrast the experience of using a Web-based App via a browser to the feeling of using a Native App. The native app may 'feel' nicer when you look at it, but nothing beats the consistency of the browser interface (back button, copy/paste integration, links, etc.). There's a reason HTML based interfaces are so popular

6. Universal support -- emacs runs on basically everything. So does VIM (Probably more than emacs)

7. Support for large numbers of libraries, languages, etc -- I've rarely found any new language, framework, etc, which doesn't have support in Emacs. With some changes to my init.el, the package is installed (thanks to use-package), and I'm done.

8. Easy dot files -- I have several computers. To set up emacs on a new computer, I just copy my .elisp directory.

In other words, the advantages of Emacs and VIM over other editors are:

1. Text-based interfaces 2. Universal support 3. Customizability 4. Adherence to the UNIX philosophy (everything represented as text)

Considering the popularity of Vim and Emacs I sometimes wonder if I'm missing out by not using them over my preferred editor, but whenever people describe their reasons for using them in lists like this, I see nothing that I would consider an advantage over my current setup, and then just forget about the whole thing.
> whenever people describe their reasons for using them in lists like this, I see nothing that I would consider an advantage over my current setup, and then just forget about the whole thing.

TBF, you've just described exactly how us emacs and vim users feel every time someone says "why aren't you using shiny new editor X? It has feature Y!"

As an emacs user who has used a few IDE's in my time, some nice things you might be missing (but which you may not care enough about to switch):

    Easily recording and playing back macros.
    Delete-rectangle / insert-rectangle
    Undo tree
    Jumping backwards/forwards a whole word with a keypress.
    Can be run inside terminal, when a command needs an $EDITOR
Thank you.

1. Notepad++ has macros when I need it.

2. Rectangular selection is available is VSCode and I use it a lot. The generalisation, multiple cursors (with each cursor having its own clipboard), is the best thing since sliced bread in a text editor.

3. I don't have undo tree, I can see it being useful sometimes. Hope it appears in VSCode soon [1]. Fequent automated backups (file history) works OK as an alternative.

4. Ctrl+left, ctrl+right jumps a word in every editor in Windows. In VSCode you can also jump a fraction of a word (to an underscore or the next part of a camel case name).

5. Well this I can't do but never needed to.

[1] https://github.com/microsoft/vscode/issues/84297#issuecommen...

It's your list so make it however you want. But to me it looks more like a list of reasons you love emacs than a list of requirements.
Personally, it's because I can't set up X11 forwarding on every machine I SSH into
Do you need to? Both VSCode and IntelliJ have remote coding capabilities.
VSCode remote works great. But IntelliJ doesn't have remote coding capability as far as I could search when needed it. You can use sshfs but it is not really a feature of IntelliJ and doesn't work well enough to be comfortable in, atleast in my experience.
VSCode Remote is a nice solution to this problem.
> That said, if you’re new to programming, a modern IDE could be helpful. With code completion, Git control, and even automatic deployment systems, modern IDEs are a Swiss Army Knife of features.

Just in case anyone reading here is as colossally ignorant as the writer, let me state for the record that emacs has those features. I don't use vim but I'm pretty sure it has them too. An accurate list of how newer IDEs benefit newbies follows:

1. Familiar key bindings

Biggest problem with IDEs is they are a big in-your-face hurricane of features that is often too much.

As a newbie you want to create a single-line Hello World program but the goddamn IDE wants you to create a workspace, and then within that workspace create a project, and within that project create a bunch of infests and manifests and resources and XML files, and pretty soon you're lost.

To be fair, emacs and vim suffer from other equally baffling problems for newbies. Otherwise this wouldn't be such an upvoted question on SO:

https://stackoverflow.com/questions/11828270/how-do-i-exit-t...

That's just a meme at this point; pretty much every intro resource for vim gives an answer to this specific question.
And the fact that that information needs to be repeated so often clearly highlights that it's not intuitive from vim itself.
What is unintuitive, is the concept of modes. One, because it is a unique concept and Two because many people who accidentally end up in vim have no use for it.

Once you grasp this concept, exiting vim is one of the most intuitive actions:

* [ESC] <- This is the "modal" part, the hard part, what you probably call unintuitive. * : <- The other part of "modal", difference between commands and navigation. Also a unique concept, that is not hard to grasp, but probably hard to know that one has to grasp it at all. * quit, exit, close * Some error may show up, telling you what to do instead, E.g. * :quit!

That is all: `[esc]:quit` a series of keystrokes that make little sense when you are not familiar with some basic concepts of vim. But entirely guessable, without reading a single line of help, if you do grasp the very basic concepts.

I'm a native vim-er now so a lot of it is second nature, but there's absolutely nothing about "modal" that suggests one mode is "commands + navigation" a priori. For instance, why isn't navigation a command? It's not necessarily bad that it's unintuitive -- lots of things require you to know something before you interact with it -- but to suggest that anyone who doesn't immediately guess the syntax has somehow failed only introduces needless elitism.
I think we are saying the same thing.

I was pointing out that the basic concepts like "modes", "commands" and "navigation" are unintuitive. But the commands, or navigation itself is not.

And from that, I state that it is not unintuitive to "close vim" in itself. But that "using vim at all" is.

That's the matter of your intuition itself. Being familiar with editor modes concept and the idea of editor commands (e.g. "actions" in IntelliJ Idea or "command palette" in VSCode) - you can figure out how to quit quite quickly.
One thing that command-line tools have over IDEs for beginners is that they don't litter your hard drive with surprising artifacts (which, in some cases, create unexpected behavior months or even years later). If you're experimenting with code in vi, you can delete everything when you're done and be absolutely certain that no trace exists.
> Biggest problem with IDEs is they are a big in-your-face hurricane of features that is often too much.

This is another aspect. They suck up attention, which is a scarce resource. It is just like you start a web browser to look up some documentation, and it shows a dozen of interesting sites you might want to read because the browser developers got some money from these sites, or whatever.

Good software typically has a sparse feeling (depending on which are its intended users), in the sense that it does not distract.

But this is just a symptom of a bigger issue that they are not really friendly to the developer.

Not only does Emacs have those features. Magit is far and away the best git interface available.
Can you explain why? Reading their official website, I can't figure out what it does or what it looks like.
Screenshots [1]

If I had to describe it, I'd say it visually shows you your current git status and lets you manipulate it using an interface that provides a thin wrapper around git commands. It provides all the functionality of git in a convenient and discoverable way.

[1] https://magit.vc/screenshots/

For git in Vim I use the fugitive plugin[1] and I find it's really good. If you find it lacking in any way you can always combine it freely with other plugins. For instance gitgutter[2] that shows diffs in the sign column, giving you an easy view of which lines have been added, removed or changed.

There are solutions for the others too. Neovim has for example support for the Language Server Protocol[3] that gives you code completion, jump to definition and the like.

The only thing with Vim/Emacs at this point is that you have to do some configuration and find some plugins to get the IDE features you want. For me personally, as I use Vim for everything, it's not that big of a deal.

[1]: https://github.com/tpope/vim-fugitive

[2]: https://github.com/airblade/vim-gitgutter

[3]: https://nathansmith.io/posts/neovim-lsp/

2. More features are part of core distribution, and they're developed by focused, professional[0] teams, so they end up being more polished[1].

--

[0] - I mean primarily the sense of "being paid for it".

[1] - Well, except for Eclipse. At least as of few years ago, default Eclipse had worse overall experience than even my worst beginner Emacs configs.

> as colossally ignorant as the writer

Your bias is showing. They never said that Vim/Emacs _doesn't_ have those. And modern IDEs generally make them much more discoverable and usable.

No-one is saying that "Vemacs" can't do everything that IDEs can do - they clearly can, with sufficient configuration, plugins, and so on. But the IDEs are generally "ready to go out-of-the-box"

You are technically correct that they never said vim/emacs lacks those features. A tiny bit of reading comprehension effort can illuminate the intent of juxtaposed sentences.
> Familiar key bindings

Well, Emacs user interface and key bindings are by experience much more stable over time, especially if you consider that in ten year's time, that "new" IDE probably is probably not going to be around any more.

That also means that some default configurations do not have a "modern" feel like copy/paste key bindings. However stability in the long term is important for users of a complex and powerful program, which Emacs is. And if you want, you can always change the key bindings to your liking.

There are also options like the betterdefaults package which modernize bindings and add features without breaking anyones flow.

Actually I disagree with the premise itself (that if you’re new to programming, a modern IDE could be helpful). There's a LOT of distraction in an IDE, and it does a lot of magic behind the scenes that you need to be aware of, because sometimes it does something unexpected and you have to be able to tell it not to. If you're learning something, you need to be able to focus on the piece that you're learning, master it, and then expand from there - that's how everything is taught, for good reason.
I make all my programmers learn both vim and emacs (with evil mode). They complain but it’s part of their on boarding.
Sounds more like hazing than good leadership.
A non trivial amount of on boarding is because "this is the most efficient information to ensure these learning agents have as they navigate their environment seeking rewards"
I don’t believe in hazing. I am paying them to learn something that I believe will make them more productive for my business in the long run and likely help them in their career when they leave as well. They can still use their favorite other editor if they want, but they should be able to teach vim and emacs to the new programmers I hire after them. Also if they can’t learn emacs, I have less faith they can learn other useful things also when needed.
Is that a joke?
In the early nineties, when we were coding on Sun Sparcstations, the only real options were vi and emacs. I'd tell new college grads to use vi. After a few weeks I'd tell them about the existence of emacs.

Some would switch, most never did.

Nobody was forced to use an editor against their will, but before ubiquitous Linux availability in college, it's not as if they had any practical Unix experience.

Because emacs is awesome. Every key press runs a program(!). Easily customized by writing code. Easy to pop up in a terminal and pop back out quickly. Can't imagine using something else, unless it's a modernized emacs.
Because you only need to know one tool for every type of work you do. Except for inherently graphical tasks like drawing and diagramming.

When you use Emacs or Vim and live on the command line every project has the same workflow. You don't need to install 10 different IDEs and learn 10 different workflows for 10 different projects. You don't need to go through 117 layers of menus to apply compilation options because your IDE invokes the compiler for you. You don't need to use a mouse. No googling "how to X in PyCharm" 5 minutes after googling "How to X in Eclipse".

> Except for inherently graphical tasks like drawing and diagramming

Let me introduce you to graphviz.

https://graphviz.org

> When you use Emacs or Vim and live on the command line every project has the same workflow. You don't need to install 10 different IDEs and learn 10 different workflows for 10 different projects.

When I was demonstrating emacs to some co-workers last week, I opened up code in three different languages and pointed out how the comments were all the exact same color. It's little things like that. And having things like hl-todo-next/previous and flycheck-next/previous-error bound to the same keys in multiple programming languages, or binding F4/F5 to compile/recompile, and that works for any command I want to run, then I can parse through error and warning messages with next/previous-error, or cruise through blocks of code with C-M-a/C-M-e. And all of this works in C/C++, Python, Lisp, Perl, etc.

I have been using my same vim workflow now for twenty years, ever since I switched from Visual C++ 6... and, at the time, I configured some of the colors in vim to match parts of what I had been previously getting from Microsoft's editors. I thereby have had largely consistent colors for like, "a quarter of a century". Despite thinking a lot about syntax highlighting for various reasons, it honestly never once occurred to me--before reading your comment--that some (many?... _most_?!?) software developers don't have consistent syntax highlighting even across different languages much less through their career. OMG.
It may well just be me, but what I find valuable about syntax highlighting isn't the colours per se, but the differentiation between different kinds of token in the language (comments, keywords, argsb etc.) Therefore I don't really notice the individual colours, I notice when the colour changes.
This is what I'm talking about. It's that comments are one color, function/method/class/struct definitions are another, keywords are another. And it's the same, no matter what language I'm programming in. Heck, I can open up a language I haven't touched in years (or ever) and just start to get a feel for the structure based on the syntax highlighting alone.
I love blowing minds with using multiple major modes. IE, executable code snippets in Org, or Javascript inside HTML.

There many Emacs packages that can do this, for example: https://polymode.github.io/screenshots/

This is really neat.

And AFAIK not something that Vim does well. At least, in my vim setup, nested modes are clumsy.

Code-inside-markdown means Markdown has to support the syntax (and snippets and shortcuts etc). Or requires a entire language (or dialect) like erb being both Ruby and HTML which cannot leverage the ruby and HTML at the same time, AFAIK.

What is, or are the common vim solution for nested or mixed modes?

People often brag about "advanced" features of vim or emacs like you do, but everything you say is pretty standard these days. Vscode does the same. So does Intellij.
It seems you missed the point. It was not to "brag about advanced features". But to show that these features work exactly the same, wether you are in a Rails project, A Python script, a Rust crate or an Android App codebase.
JetBrains products work (mostly, I will concede) the same across all their products.

Literally whether I open RubyMine, PyCharm or CLion I feel at home.

I have the same positive experience of efficient consistency with their products, also the reliability on keyboard shortcuts as well as the advanced navigation features make a big difference in my everyday work
AFAIK this is the main selling point by and for JetBrains products.

Still, there seems no JetBrains for Bash, ansible(yaml), HTML, Latex, Rust (though there is a plugin), or markdown. For me, at least, those are not my daily drivers, but I do spend substantial time hacking them. Same for "frameworks" RubyMine does Rails really well, but really gets in the way when hacking on some KibaETL or Chef scripts (also Ruby, deep down).

I'm convinced this comes from the fact that IDEs have to be both highly opinionated and very flexible: supporting all of flask, django, pandas+Jupyter and ansible, properly, is tough: all are Python, all are really different. Either you turn Pycharm into something that does not work good for anyone (lowest common denominator) or you have to leave out communities.

And also need to do everything on their own (or clumsily integrate) instead of leveraging community tools and standards like, say rustfmt, xmllint or jq through "unix".

> Still, there seems no JetBrains for Bash, ansible(yaml), HTML, Latex, Rust (though there is a plugin), or markdown.

There are very high quality third party plugins for everything you mentioned except maybe Latex? HTML support is built-in for sure in all the web-focused IDEs (pycharm, rubymine, phpstorm, webstorm). I generally edit almost all my files in a JetBains IDE, heavily using the "scratch" feature.

The Rust plugin is not ideal yet, although it is officially supported so in time it will probably have the same support and quality other products have.

> I'm convinced this comes from the fact that IDEs have to be both highly opinionated and very flexible: supporting all of flask, django, pandas+Jupyter and ansible, properly, is tough: all are Python, all are really different. Either you turn Pycharm into something that does not work good for anyone (lowest common denominator) or you have to leave out communities.

Yes, some frameworks are not fully supported, which is inevitable. The most popular frameworks will usually have an official plugin. I wish more framework/language communities would take developing a JetBrains plugin more seriously.

The language plugins do usually leverage community tools when possible, but sometimes it is prohibitively expensive performance-wise.

In conclusion: Vim and Emacs do win in ubiquity for sure. It is unfortunate though that many communities only focus on getting those type of setups working well. The JetBrains IDEs are MILES ahead of what Vim, Emacs or Visual Studio Code can do with their hodge-podge of plugins that I would never trust with a context-aware automatic refactor in my life. Those editors are in fact a "lowest common denominator", and people lose so much productivity because of them.

In fact, I will consider a language "niche" until it gets proper JetBrains support for the above reasons.

I think it is the combination of consistency and adaptability.

There are a huge number of interesting features and tweaks out there, and every once in a while one encounters a useful gem. For example, I have started to use Unicode more heavily in documentation, and I am also a latex user, so now there is a mode which lets one enter any kind of unicode symbol by typing the latex sybol name.

Or another, I found that syntax highlighting is neat but what is really helpful instead is to give any identifiers in functions different colors, which makes the data flow in the function much more salient and quicker to understand - including spelling mistakes. And that works in many languages.

> Or another, I found that syntax highlighting is neat but what is really helpful instead is to give any identifiers in functions different colors, which makes the data flow in the function much more salient and quicker to understand - including spelling mistakes. And that works in many languages.

Oh yeah, I just discovered rainbow-identifiers-mode. Pretty sweet!

Indeed. There is a similar mode to match parenthesis :-D
Based on Lisp, Emacs has also very good support for REPL, or read-eval-print-loop programming. My impression is this is becoming more important. Anyway this is an extremely valuable feature if one programs Common Lisp, Racket, Clojure, Forth, or Python (noting that Python has only partial support for that kind of programming, but it still helps a lot).
Python's getting there! I recently went on a tear of going through "elpa-*" packages in Debian and setting them up, and one was elpy, which now gets closer to SLIME's C-x C-e.
> When I was demonstrating emacs to some co-workers last week, I opened up code in three different languages and pointed out how the comments were all the exact same color.

I don't get this. That is normal in any modern editor. What is so special about this?

> I don't get this. That is normal in any modern editor. What is so special about this?

So other editors have finally caught up with emacs? Nice to know. Last time I tried opening different languages in "advanced" IDEs, it was plain black lettering on white background.

To add to all these good points, also the fact that vi/emacs isn't going away on the whim of some company that comes and goes. So the effort to learn these (and any long-lived open source components) is amortized over my lifetime, not the short lifetime of a commercial tool.

Whenever I change projects or jobs I know emacs will be there as efficient as always so I can concentrate on being productive instead of on learning yet another ephemeral IDE.

I haven't even been a developer long, but I remember everyone was using Eclipse then Sublime then Atom then Brackets then VSCode. This was all within a span of 3 years.

I've been using vim for most of my career but will use other tools when pairing or working with others, the only thing I regret is not learning the intricacies of vim more.

I'm not proficient but every few months I improve more and more, and it's nice to use a tool that has been around for decades and will continue to be around for decades more.

> I remember everyone was using Eclipse then Sublime then Atom then Brackets then VSCode. This was all within a span of 3 years.

Yes. The half-life of these things is rather short. And there are few reasons to expect that this will be better with the IDEs which are currenyly touted by one marketing department or another.

In the meantime I am using Emacs since over 20 years. I can adapt it to new things (such as magit) when this is useful but it never breaks my flow.

The most important advantage of Emacs and vi are, these are open systems, which come out of an open culture, not just "open source" but really free software, with no strings attached. Granted, open source is having its successes, so companies are trying to jump onto that bandwagon, but this has mainly the consequence that the strings attached are less visible - like "telemetrics", inacceptable spyware, waste of attention, artificial obstacles to competitor languages / systems, unwarranted and empty hype, and so on. It is important to recognize the tone of that, and to listen to it, and to think about it, because it can warn you before making bad decisions.

Also, Emacs has top-notch documentation. While basic commands are not that hard to learn, there is certainly a lot of stuff one can learn, so much that it takes some amount of conscious effort to learn a good fraction of what is relevant to certain tasks. That said, Emacs also makes fantastic use of a undervalued property of the human brain, which is automatic decluttering, forgotting and blending out things which are not in use, like a diligent and friendly housemaid which brings anything which you haven't really used in the last year into the attic ;-)

But, jokes aside, exactly like learning the Linux command line well, learning some Emacs is an /excellent/ use of ones time as a programmer, because the half-life time of the knowledge you gather is much much longer than when you just learn the latest IDE. Chances are that your IDE du jour will be mostly forgotten five or six years from now. Chances are high that the basic command-line tools and Emacs commands you learn now will still be useful twenty and thirty years from now.

This also applies to using modern graphical text editor such as Sublime Text or VS Code.
Tbh if I was starting now, I would probably use one of those and be happy with them.

But I started using Emacs in 1992, and it still does what I need (thank you language server protocol).

Will VS Code exist and offer the same experience over a whole career?

I have started with Visual Studio, then moved to Eclipse, then I've learned Vim and then Emacs and I stuck to Emacs finally.
I think you may be overly generous to Emacs. When I use Emacs, it's more I need to go through hundreds of lines of others' Emacs Lisp configurations to figure out how to do the thing I want to do or spend many times 5 minutes Googling how to do <x> in Emacs. A good example of this is Elixir's helpful coloring and tab completion in its help documents. When I tried running Iex in an Emacs terminal, it just didn't work, and after Googling, it's just a mess of solutions. It literally just works in Visual Studio Code's terminal.

I forced myself to learn Emacs for a class, and it was really quite painful. I get the power of the bindings and all that, but it's really a mess of an ecosystem, and I encountered plenty of bugs. Even then, I never got things to work just right, and it worked poorly when doing things across Windows and WSL boundaries. Another thing was that any time someone used my Emacs, they couldn't because it wasn't like their Emacs.

So I've just gotten used to Visual Studio Code because I spend more time doing the thing I wanted to do than finding out how to do something simple in the editor. I add a single custom keybinding for toggling between the terminal and the code window, which can now be synced using a Microsoft account. I just install whatever extension I want (through one extension manager) and go at it. Combine this with the extremely powerful and useful extensions of Remote - SSH and Remote - WSL that allow you to use Visual Studio Code on basically any other computer with your extensions as they work on Windows, then you have a one-stop shop for development.

https://code.visualstudio.com/docs/remote/remote-overview

And by the way, Visual Studio Code can do graphical tasks: https://marketplace.visualstudio.com/items?itemName=hediet.v...

Is Visual Studio Code perfect? No. Can someone be more productive in Emacs than Visual Studio Code? Yes, but likely only if they've spent an inordinate amount of time learning Emacs and Emacs Lisp. But Visual Studio Code provides a nice balance of a single environment across languages that evolves with users' needs and basically anyone can be productive in it today.

My personal preference is to use the standard IDE with whatever language I am using, and then to default to Visual Studio Code whenever there is no such standard. I also use a fair amount of visual languages that text editors do not work for.

    Another thing was that any time someone used my Emacs, they couldn't because it wasn't like their Emacs.
You hit the nail on the head. I spent months forcing myself to use nothing but Emacs to get past the "this is unfamiliar and therefore hard" stage. My final conclusion after the experience was that Emacs is pretty powerful out of the box but it is absolutely a general purpose environment and you have to meld it to your own workflow to truly unlock its potential.

Even though I don't use Emacs these days, one thing I did keep was swapping capslock and ctrl on my keyboard. That is useful for so many other things and I'm never going back.

I can't speak for Emacs, but just this week I went through my vimrc file and deleted half of the configuration. Turns out now that I've started to grok the finer points of the editor, the heap of cool mappings, functions, and must-have plugins I found on the internet are more hindrance than help.
Any kind of set-up is done in textual configuration. And this is a major plus. That means you get quickly to see what you have configured, you can put it into version control and check it out on a different machine, and so on. This is a big ergonomical difference to IDEs.

As the technical foundation, it is rock-solid. Emacs is based on lisp which has basic text manipulation instructions implemented in native code. This makes it both extremely easy to configure and extend it. It is also from a time when Linux was not yet existant, Unix was not yet universal, and Lisp machines were a thing, so it has a certain platform feeling - while also having good access to the OS. It is certainly possible to use Emacs in text mode as a login shell or as a terminal manager.

To that adds another quality of Emacs and vi, one which these IDE enthusiasts can not even understand, which is that the user interface is incredibly stable. And this means that something you have become used to will not change and drift under your feet like quicksand. And in the long run, this really saves a ton of time. That does not mean you can't change things, rather you can change stuff under your control, like using the better-defaults setup.

I'm not sure I would consider Emacs's technical foundation rock-solid. Elisp is a bit of a relic, with little in the way of modern niceties, some anti-features, and a slow implementation. And heavy use of cons lists causes a lot of pointer-chasing.
So, it might please you to read that there is a slow but steady process to replace elisp by Guile:

https://www.emacswiki.org/emacs/GuileEmacs

And to me, this is a indication of a solid foundation: That you can swap out some base infrastructure for another when you need to, without messing everything up. (Another example is that Racket was switching the core implemenation to be based on Chez scheme, which compiles to native code).

I've watched someone struggle for literally hours in Emacs wading through dependencies to track down an issue. He then resorted to grep and kept spending time.

The same task would be accomplished in one click in Eclipse.

There is a reason why specialized tools exist.

I don't follow. How is it that graphical tasks require multiple tools, but for every other type of work you need just one tool?

That seems just obviously incorrect to me.

I do all sorts of things, and use all sorts of tools. Am I missing something?

If you learn vim or emacs, you will discover that for literally any task that is interacting with text in some form (plain text, code, spreadsheets, presentations), there is almost always an extension in these "text editors" (which really are working environments) that facilitates that work. Hence the claim that you only need to learn one tool rather than a dozen.
I've been using Emacs for a lot of things for a quarter of a century. Mostly programming. Or, really, editing program source code plus some haphazard IDE features I've bothered to hack in.

Emacs is definitely is not the only tool I need. It is ill suited for graphical tasks, sure, but it is also not the best tool for email, web browsing, taking notes, calendars, and a wide variety of other things.

Sure, you CAN do most of those things in Emacs, but it's not the best tool out there for any of them. Emacs is a great IDE, but it simply doesn't exist on most of the platforms I use all the time to make in a realistic contender.

Home surveillance? Password management? Backups? Website authoring? Keeping basketball scores? Managing personal photos? Learning a new language?

Literally (and NOT figuratively!) most tasks are better done not in Emacs, but some other tool. I'm not sure why this needs to be said out loud.

Yes, like a piece of paper, you can use it for any of those tasks. Almost anything can be viewed as a "text task". But it there are better tools out there for almost all of them.

> Emacs is a great IDE, but it simply doesn't exist on most of the platforms I use all the time to make in a realistic contender.

Emacs is available on Windows, Mac, and all extant forms of Unix, so... are you talking about mobile platforms?

That's basically what I have with Jetbrains tools. They all look the same, they are just slightly specialized for the language.
Right, but you only have Jetbrains installed locally. It's useless if you're SSH'ed into a remote machine (usually through a jump box for security reasons).
So buy the deluxe edition of IntelliJ and you will get the same workflow for most modern programming languages.
Sometimes I need to edit a 10GB text file. Good luck with anything other than vim.
sed, perl? I don't know why you would ever need to load a 10 gig file to memory.
Vim doesn't load it all into memory. Sed and perl means you are writing a program to deal with it. I already have a program that can deal with it.
Sublime can do that. I bet intellij could pull it off if you had sufficient ram which you probably do if your editing 10 gb files
Last time I had to edit a huge file vim failed and vscode succeeded. Is there some special mode you need to be in while using vim on huge files?
disable syntax highlighting.
I use terminal Vim mainly because of tmux and all of the benefits that come along with using it.

Being able to split projects up by sessions, persisting everything and seamlessly jumping between varying layouts of terminals and code editing is something I haven't been able to reproduce with any other editor (even if it has a built in terminal).

For me, I've been using Emacs for 20 years. It comes down to two things:

  1. I never have to move my hands from home row. Pretty much anything I need to do, I can do in Emacs (including file browsing, PDF viewing, web browsing, music playing, git, shell stuff, etc), and faster, because I can rebind keys at will. Emacs is just too darn flexible.
  2. Anything good from other editors will eventually make it into emacs. The first thing that comes to my mind is snippets which I think came from TextMate. Again, emacs is just too darn adaptable and flexible.
That said, I don't recommend non-programmers or even new programmers learn emacs. It's a steep learning curve, it's just I've already climbed it, and now I delve even deeper to learn more about it whenever I can. I just don't have the technical investment in any other editor, and it's highly unlikely that any other editor, IDE, etc will ever have enough advantage to switch.

Edit: Ooh, I just remembered this one: I'm not a big user of TRAMP, even though it's awesome, but it's even more awesome than I realized. A couple of weeks back, I was test-compiling and running our codebase on a new version of the OS, using a remote machine via ssh (forgot the -Y). I quickly found myself missing the M-g n and M-g p for moving through compile warnings and errors, so I loaded a remote edit session on my local emacs and without even thinking just ran a compile. To my wonder, it just Did What I Meant, and ran the compile on the remote machine, no special setup required! I mean, it was utterly seamless. It's this sort of thing that keeps me learning emacs and just marveling at how awesome it is!

> To my wonder, it just Did What I Meant, and ran the compile on the remote machine, no special setup required! I mean, it was utterly seamless. It's this sort of thing that keeps me learning emacs and just marveling at how awesome it is!

This will blow your mind then (as it did mine, when I discovered it): it also works like this for GDB sessions.

> That said, I don't recommend non-programmers or even new programmers learn emacs.

Emacs is definitely more useful to people who use it somewhat frequently, as one has to memorize some key strokes. But, there is a good interactive tutorial, and I don't think that learning Emacs to the equivalent of a beginner's level of competence takes very long. A few afternoons perhaps, and one can go extending from that.

And if you forget things, it is because you do not need them that often. This is also a kind of economy in there. Maybe other things are more important.

I stopped reading immediately after this: The endless war between Vim and Emacs users has continued ad nauseam over the years. "It's less a war at this point than a grumbling shuffle of ingrained habit and stubborn resistance to change."
Honestly emacs and vim haven't been at war for ages. We joined in an unofficial peace treaty when the common enemy of graphical IDEs appeared.
I use vim because it’s the only real option for my workflow. I work on an extremely large codebase that easily eats up several hundred GB of disk space.

This code lives on a workstation under my desk. I do my coding on a laptop.

I want only one feature: Low latency for typing, find/replace, search over a wireless connection from my laptop to my workstation, possibly while I’m traveling.

Nothing beats ssh’ing into my workstation and launching vim. (Emacs will also work - I just prefer vim because I’m used to it)

I would love to use an IDE and the powerful features that come with it. But I wouldn’t trade off latency for those features.

Additionally, there are a ton of people who use the same workflow as me - ssh + vim. Any impact from changes to a network security policy will quickly be fixed because it impacts soo many of us.

Genuinely curious: How do you efficiently navigate such an extremely large code base using vim? ctags? Any plugin recommendation?
I use ripgrep[0] to look for things. It’s incredibly fast - I have found that it’s usually faster than what an IDE takes on a much smaller project.

Once ripgrep has found something, jumping to that file is super easy (and fast!)

I use ctags on smaller subdirectories when I’m not familiar with the codebase and I need to jump around a lot to find definitions within a small number of files.

[0] https://manpages.debian.org/testing/ripgrep/rg.1.en.html

Similarly here. The codebases I work on are smaller, but then, I sometimes work on a go from a sidearm 2-in-1 computer. It's lovely to be able to just SSH (well, mosh) into my beefy desktop and run Emacs in a terminal, and have it both look and work identically to the GUI version I use at home.
What is the language of your codebase? And which industry are you in so I can avoid it. My goodness, several hundred GB of code sounds like pure misery.
> I use vim ... I work on an extremely large codebase

That's surprising to me - it's usually once I get up into the triple-digit file count that I give up on command-line tools and start letting an IDE index things for me.

(comment deleted)
I was recently given some money and splashed out £150 on an i5-6th gen desktop which lives in my roofspace. The i5 replaced my trusty dual-core.

A long time ago I centralised my projects to the headless roofspace box and now run up Sublime remotely for each project (using lxc). It works great and I can code from any computer on my network.

This seems easier to me than running vim and spending a month getting on top of my vimrc.

I'm only slightly older than Vim itself (but much younger than vi), but I've used it for virtually my whole career. The one thing the author's missing is the real reason every Vim user uses it:

Vim is not an editor. It's a language. A text-editing language.

When I'm editing, I'm thinking things like:

- change these 2 words: "c2w"

- remove everything in these parentheses: "di)"

- delete this line: "dd"

- where is this declared: "gd" (this is a custom CoC.vim mapping)

Any editor implementing that language would probably see very good adoption in Vim user circles (e.g nvim).

> Why are so many coders

It is unclear how many coders do in fact. There's a very LOUD subset of programmers that absolutely do, because they'll tell you they do every chance they get. But if you only listened to the comment section on sites like this you'd think that nobody uses Visual Studio, IntelliJ, Eclipse, etc rather than them being more stereotypical for professional shops than Vim/Emacs.

If you look at Stackoverflow's survey[0] it gives you some idea, but because it is a [Select All that Apply] question it can inflate IDEs that are good for occasional/general purpose usage (e.g. Vim, Emacs, Notepad++, VS Code, etc). They should ask people what IDE they use MOST.

It is the same thing as Windows, you come to any programming message board you'd think 99% of programmers use Linux professionally, but in the corporate world (which is the majority of programmers) Windows rules the roost.

[0] https://insights.stackoverflow.com/survey/2019#technology-_-...

VS Code is the best IDE for TypeScript, which is rapidly growing. I think that's the more likely reason than accident.
> Modern IDEs are magic. Why are so many coders still using Vim and Emacs?

The title answers the question to some extent - I prefer Vim over IDEs because I am allergic to "auto-magic". Also, unlike most IDEs, Vim will still be there after 5 years, 10 years, or 15 years.

I feel the same way. The beauty of Vim is that it's not only flexible but also respects the user; unlike most IDEs it doesn't blindly make assumptions, auto-format code while it's being written, auto-close brackets and tags, it has no "plugin XY has a new update!" popups. It just reacts to input and nothing more.

Vim can have most of those things if needed, but after years of usage my tolerance for "smart" features declines constantly. Which in turn made me gravitate towards using more CLI utilities, as those follow the same philosophy and go hand in hand with Vim. The "no automation but efficient shortcuts" approach just feels more reliable and predictable.