Modern IDEs like VSCode + Vim bindings is my preferred platform
Modern IDEs like VSCode + Vim bindings is my preferred platform
And casual keyboard-commands just don't scale well. Moving cursor x chars means you must type the movement-key x times. With vi you just type the number x and the movement, and usually save big time.
Aditionally, vi has more knowledge about textual objects, which are all interchangable. So whether you move 3 chars, words, paragraphs, pages or functions, it's all the same, just with different letters.
Vi's command-language is highly composable and thus very dense, so it will alwys be faster than mouse and casual editor-commands. Of course as long as you habit them.
I recognise there are other better ways to move around but they too often have drawbacks, like moving somewhere with ‘/‘. You have to parse the line you want to move to for a unique string that’s close to where you’re going. Then you have to scan over all the text in between to make sure it doesn’t occur too much there.
Maybe I’m still just doing it wrong.
Correction - you must move your mouse hand from the keyboard, move the mouse to the desired location, _then_ click.
Ergonomic concern often goes side-by-side with editors like vim.
I'm also not convinced that comparing the simple editor things is demonstrating the value of vim much. It's how easy vim handles the _not_ simple things, and also how easy it is to motion the often unique or rarely used edits, combined with drop-of-the hat programmability, that makes vim a good choice.
>how easy vim handles the _not_ simple things
Agreed, despite any minor differences in movement speed, even '.' by itself is useful enough to never switch back.
While it's true that most programming is spent thinking about the problem rather than manipulating text, the benefit of modal editing and Vim bindings is not only in the saved time, but also in removing the barrier from thinking about how you want to change the code to actually changing it. That leaves you more time to think about the problem, but also doesn't interrupt "the flow" by having to think about moving and positioning a mouse cursor in a GUI, which is always a more mentally draining action than typing a few keystrokes.
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 think you just said it. Its not interesting/nor a priority for you to optimize things to that level. Those using vim properly and trying to move away from the mouse consider it better for efficiency and ergonomics (debatable).
Its not that you fail to understand. Its more so that you don't care that much.
I have doubts whether the efficiency gains are that useful in every day life. There will some days where I make some pretty widespread refactoring changes over files or the yanking/register stuff can be quite useful, but in general, every day programming, I don't see the efficiency gains.
I have another theory for why people like Vim so much.
Using vim makes you feel like the old-school, crazy powerful, very smart programmers shown in Hollywood. It makes you realize the dream that the little child had when he saw programmers on TV. ( at least for me ) and honestly, its more fun to be doing that so I do it. :)
Maybe I am not that good at vim. But at my level, i don't see great efficiency gains. I simply see more fun gains, and that's good enough for me.
Vim bindings are a gain because you don’t have to use the mouse.
I can comment out a function/block/line from anywhere in the function without looking at either the screen or the keyboard. And I do it without consious effort.
You probably use keyboard shortcuts to go to the end/start of the line anyway, if you expand that to all the vim movements that's what you gain. Adding composition and macros are just the icing on the cake.
Also, I find that preventing constant movement from the keyboard to my mouse and back helps mitigate wrist pain and discomfort from long sessions at my PC.
With vim bindings it’s easier to do things like rewriting arguments in a function, without having to carefully select them with a cursor or using ctrl+shift+Right arrow the right amount of times.
The speed I find it’s only a plus when having to work with old/sluggish machines, because it breaks my flow way less, but that’s completely personal preference.
If you don't mind moving back and forth between mouse and keyboard, or smashing ctrl-arrow to move, then it's fine.
VSCode is at the edge of an editor and an IDE though, or so is my feeling at least. I feel like the massive need for ease of use and speed clashes with the needs of power users (e.g. for Java EE or database developers), and that this push vs pull might to be the downfall of VSCode in the future (unless MS throws a pile of money and devs on the codebase).
Secondly, trying to discern between an “IDE” and a “text editor” in 2020 is a fools errand. It’s pointless because there’s such a grey area between where one definition starts and ends.