[rss]

Vim anecdotes

Programmers have an unquenchable thirst for discussions about tools and technology. I've participated in my share of editor and framework discussions, perhaps too much. I've begun noticing patterns — the same arguments show up repeatedly, which begets much of the same responses.

There is no surer trigger for discussions than vim. Just uttering it's name causes both fanatics and iconoclasts to crawl out of the dark to engage in ideological wrestling matches. So much brain power is spent on defending or defaming vim. I've been watching these exchanges, taking note of my favorite anecdotes.

Opinions often arise from feelings or lived experiences, which can sometimes be hard to translate into verbal ideas. This means that we get to see a lot of allegories, anecdotes and similes used to express people's thoughts.


Rotundo

The learning curve can be steep but once you learn vi/Vim you can never go back to an IDE like VScode because it is so unbelievably limited.

When you get comfortable with vi it really begins to feel like you can type text in VScode but you can't edit it.

"feel like you can type text in VScode but you can't edit it"

This one is short, yet very powerful. Vim is all about making it easier to edit, not to type.


tasty_freeze

If you tell me to just download a vi mode for vscode, I can tell you that the basic motions work, but that last 10% cause unending grief. It is like eating pasta where every 10th noodle is actually a rock disguised to look like a noodle -- completely disruptive.

This is just an excerpt, but I had to include it for the amazing pasta simile.


helaoban

For some (myself included) the high speed and efficiency of proficient modal editing serves as a thinking aid, like sketching with a pencil and eraser. I tend [to] "play" with the code: chopping it up; splitting lines and inserting a bunch of white space; duplicating lines dozens of times to act as placeholder values (e.g filling an array literal); renaming variables across a file many many times before settling on the right name; moving helpers functions to the top, then to the middle, then next to their first invocation etc.... All doable with other editing styles, but at a higher cost, and the cost of manipulation has to be very low in order to reap those meditative qualities.

Manipulation far outweighs input. And manipulation is fundamentally thinking, at least for me.

This seems to get at one of the fundamental disconnects between some programmers. I am like helaoban; I like to move around and mould the code as if working with clay, until it turns into something good. Oops — I made my own simile.


martindbp

> Simply put, text manipulation is not at all a productivity bottleneck for me

I once believed this and this comment could have been written by me verbatim. But I decided to seriously give vim a try and I'm still very happy 8 years later. I don't know for sure that vim makes me a better programmer, but going from vim to another editor is a bit like going from your large desktop screen to a 13" laptop working at a café. I can do the work but it's just slower and not as enjoyable.

Maybe it's not so much vim specifically, although I enjoy the modal editing part, but just 100% investing in a single editor and getting really good at navigating and editing code with it. It's always fast and responsive and always available. Before vim I used different editors for different jobs, Emacs, BlueJ, Eclipse, Visual Studio, Sublime, XCode etc and I never truly invested in any of them. Once you make a decision to just use the one editor, it's a powerful thing.

This is an argument everyone can get behind. "It's not the editor, it's what you do with it" — taking the time to learn your tools; reading their user manual, looking up the shortcuts, configuring to your liking, is such an obvious truth that everyone can get on board with it. Yet very few people seem interested in actually doing it. Vim has the effect that it forces you to learn the tool in order to be productive. Most modern editors simply work the same as MS Word or notepad, with no suggestion that there's anything deeper to learn.


rewgs

It’s flow state/reducing cognitive load, not just literal typing speed. I know that might sound insane —- I was extremely weary of such claims for a long time and thought vim was stupid —- but after getting over the “hump,” I get it and absolutely can’t go back.

I have no idea why rewgs chose to combine EM-dashes with normal dashes.


zokier

Fast typing speed and efficient editor practice are transformative; when human-computer interface becomes frictionless you unlock notation as a tool of thought, and really be able to use the computer to design your programs instead of doing design first in your head/pen-and-paper/whiteboard and then transcribing near-final code to computer. Or at least that is the idea; I'm not 100% certain if it is not just pipedream for the majority of us.

This is the same argument as helaoban, but I appreciate the uncertainty added to the conclusion.


gorgoiler

Being able to juggle text really comes into its own when you now have to move it around from one module into many, appease the linters, search-for then factor-out a common pattern, or rewrite your idea in place without breaking it. These are all things we do to take code from the “it works” stage to the “it’s correct” stage, namely self documenting modular code that is human as well as machine readable.

Vim makes light work of the back breaking chores involved with code gardening, which indeed bears little resemblance to programming.

"code gardening". A great allegory.


SkyMarshal

The whole point of vim binding is to reduce context-switching to the mouse, better maintaining flow.

Once you get good at Vim + a tiling window manager, constantly swapping to a mouse to do things interrupts your flow. It’s akin to forced context-switching, which programmers hate because that also interrupts flow and concentration.

But it does take practice to master enough Vim commands to be able to use it without referring to help docs (which also interrupts flow). You won’t really understand this flow advantage until you’ve done that.

Fwiw, Wall Street culture has something similar around Excel. The best, most proficient Excel masters can use Excel with keyboard only, no mouse, b/c they’ve mastered all the keyboard shortcuts for navigation, data entry, and calculation. They judge each other based on this ability. It’s not unprecedented in the software development community only.

I like the comparison to context-switching. How many programmers haven't complained about being interrupted by a coworker while deep into coding?


soyiuz

I would suggest that Vim is about more than speed, it is about flow. Think about the difference between ctrl-c and navigating to the menu to copy with your mouse. One just feels more fluid and requires less thinking. Games use extensive keybindings for the same reason.

Once again, flow is a central theme to many vim users.


facorreia

I use vim not because I think I can type faster in it, but because I have used so many editors in so many different platforms over my career, and I realized that I could settle for just one that I can trust will be around (and be very effective, and available on any platform I choose to use) for as long as I'm alive.

The "old as stone" argument, with an "and be very effective" snuck in there.


DarkTree

The thing about Vim is that I cannot imagine creating it and thinking, "This will be much faster and easier than a mouse eventually". But, I also wouldn't think that I could learn how to type fast without looking at the keys if I just stumbled across a keyboard, but both are undoubtedly true. Like anything physical, it requires practice and muscle memory. Would you rather go back to looking at every single key to type? That's how vim users feel about regular text editors. Try it out.

Another great allegory which gets at the heart of the feeling of using vim. It doesn't attempt to convince by proof of efficiency, it simply describes how it feels to vim users.


iLemming

Learning modal editor - vim, nvim, emacs is like skiing or snowboarding. For anyone uninitiated this whole endeavor may seem dumb - you have to spend so much money, time and effort, so you can just descent from a mountain peak to its base on a piece of wood? Absurdly bananas.

Some may even try hitting the greenest, flattest, most beginner-friendly slopes with great confidence, only to find themselves face down in the snow minutes after getting on the lift. They try again. Sometimes, falling for the fourth or fifth time reinforces their belief that it's really is dumb and they just quit at that point.

Some newbie skiers, after a few successful runs, get overly excited and head to the lift for the steeper slope, only to regret their decision. If falling all the way down doesn't make them quit, they may eventually start enjoying it.

At some point, they'd gain so much experience - their movements become smooth and graceful, their speed intimidating. Suddenly, they'd discover an enormous, indescribable feeling of joy. There's so much tacit - emotional, mental and physical enlightenment that is almost impossible to convey to another soul who's never experienced it or rose to that level.

Then there's a spectrum of differences - some still fall all the time yet enjoy it nonetheless, and they enthusiastically discuss with other beginner skiers how awesome they feel. Some, after mastering the most difficult carving techniques, somehow forget their own beginner's journey and become apathetic toward rookies.

So, then why ski (vim) at all? Well, it is truly one of the most efficient, fastest, healthy ways of getting back to the base (dealing with text). But most importantly it's tremendously fun. Often, in quite indescribable ways. I'm afraid you would never understand the appeal until you do try it. But even then, it's never guaranteed you'd find that thrill; then maybe skiing (vimming) isn't for you. Even though these activities literally for everyone (unless they have physical/mental barriers).

I honestly can't take seriously any programmer who doesn't know the basics of vim - doesn't that suggest they've never used sed, less, or read through man pages? Have they never had to ssh to a remote machine in the terminal? I do though get it, when people say "I tried it and ain't for me". I suppose, it just means they've never hit the spot that inspired them to keep going.

Many people reach for allegories when trying to explain their love for vim. I particularly like that this one emphasises the fun aspect of using vim.