You learn it and if you enjoy it you can go deeper. I use VSCode on my desktop and I’m not about to give up a graphical IDE, but it’s great to be able to ssh into any linux server or container and be able to efficiently edit with just a keyboard when you need to.
Don't use Vim for the wrong reasons (2020)
41–50 of 85 posts
Re: Don't use Vim for the wrong reasons (2020)
#42This is four years old. It was outdated at the time it was written, and now it is woefully outdated. For example: > From sketchy terminal integration, to being single-threaded, via the lack of anything resembling a proper internal plugin API, nothing in Vim can be leveraged to give you a convincing Integrated Development Environment. https://neovim.io/doc/user/api.html
Re: Don't use Vim for the wrong reasons (2020)
#43What is the consensus on productivity with Vim? I have thought about trying out the keyboard only approach, but haven't wanted to invest time in it yet. When I see people on YouTube using Vim it slightly feels like there's a whole lot of keypresses happening, but not a lot is actually gained compared to using a mouse or even frequently it seems it takes a while to do something that is much quicker with the mouse. I u…
I think maybe you shouldn't focus on the "productivity" - that's a fairly arbitrary metric, and difficult to measure - it often has more to do with how many bugs you have, how organized you are, and what you are trying to accomplish, how good friends you are with your boss/customer, and very little to do with which editor or what keybindings (or which language, even).
Instead, it is better to think about communication protocols - for a second consider something like the internet - something like handwaves, gestures, while theoretically analog and hence containing infinitely more data, they are very difficult to transcribe, send to the other side of the planet, and interpret.
I'm not saying these things cannot be done, but I imagine the internet would not exist if we had resorted to using thumbs up/down as our method of transferring information between "computers". We used a more appropriate, binary-based, protocol, and now we can send characters and have discussions! Maybe even include a couple hand-wave emojis!
Editors like vim/emacs are similar, they "feel" more productive because they are in some sense, "closer" to the code than a mouse can be. If I mainly am using a mouse (nothing else), then I probably should not be writing code at all and instead should be recording my program with hand waves, or something.
I'm not saying IDE's aren't useful, but that's because programming is neither about those mad FPS skills (mouse) or nor mad text editing skills, they are built to manipulate and mangle symbols, which is what we actually use (for better or worse) to program computers.
That's one reason why I find IDEs (often coupled with an emacs keybinding) mad "productive" - I can mash shortcuts all day long and most of my code writes itself (I'm not even using AI). I'm much closer to communicating with my code/debugger than having to mouse click around. Some of the transforms/translations are sometimes odd, or the UI environment is restrictive, so I'm using the mouse then for those situations. I often, frequently, find myself "out-coding" my peers.
But a good IDE is mostly aimed at being really good at modifying/generating symbols (in the context of a project). Its not very good at text formatting (usually handled by some plugin), for instance. And where it really falls apart, there's no control, i.e. usually it is a complicated product, with lots of pitfalls, speedbumps, "I screwed up and jacked my cache please restart me". And that nixes a lot of the "productivity" gained.
So that remains where a tool like vim/emacs/notepad++ etc shines, when you need to communicate with (roughly structured) text, they won't crash on you, they won't "get in your way", they won't need you to define an AST syntax in order to understand your little mini-language, and, at least of the extensible ones, you can define whatever it is you need or want to. IDEs are usually really, really bad at that sort of thing, if you find yourself needing to do that, you'll often 1) learn to cobble something together in a script 2) learn to cobble together something approaching that in an extensible editor 3) writing a language 4) writing a plugin to write your language in your IDE, to solve whatever it was....
Re: Don't use Vim for the wrong reasons (2020)
#44Ironically text editing is the thing I like least about vim. I would switch to an IDE if it provided the level of programmability Vim has. For example, I have a binding which, when used on a netlink command, opens the corresponding implementation in the kernel. How do you do that in something like VSCode? I guess I could write an extension, but in Vim it takes like 2 lines of code that you write once and forget about…
Thankfully I’m somewhere with sane tooling that watches for changes and only runs relevant tests, but back then this little foray into “how do I make Vim do a thing” saved me a ton of time.
Re: Don't use Vim for the wrong reasons (2020)
#45I'm a big fan of Vim, but I hardly use it as my primary editor anymore (applies for Neovim as well). I think the ecosystem is amazing, but I hardly have the patience to set things up to feature parity with other editors. Debuggers are the biggest missing/hard to configure feature. I do, however, use Vim bindings in every editor that supports them (and extensions for browsers like Vimium). The extensions/Editor functi…
I found a lot of issues with trying to get a “good” setup, or got frustrated that moving from one job to another meant attempting to port my working setup to a new machine and new projects. I recently went back to NvChad and have done almost no custom config and I love it.
Re: Don't use Vim for the wrong reasons (2020)
#46I hate those YouTube videos "turn vim into an IDE". The people who watch those only care about bragging that they use vim, nothing else.
Re: Don't use Vim for the wrong reasons (2020)
#47Re: Don't use Vim for the wrong reasons (2020)
#48What is the consensus on productivity with Vim? I have thought about trying out the keyboard only approach, but haven't wanted to invest time in it yet. When I see people on YouTube using Vim it slightly feels like there's a whole lot of keypresses happening, but not a lot is actually gained compared to using a mouse or even frequently it seems it takes a while to do something that is much quicker with the mouse. I u…
- grab my mouse and click where I want the cursor, fix the typo, and then click back to where I was (or hit End, or was it Ctrl+Right? Opt+End?)
- type Faaar$
Ok, that’s a lot of weird keystrokes, but in my brain my hands just did “jump back to the a in ‘rae’, delete the ‘ra’, type ‘ar’, jump to the end of the line”.
Over a decade of Vim later and these motions are second nature to me, and using my mouse is usually reserved for the times I’m not in Vim. I can’t say I’m faster or more efficient, but I know how to get my cursor to exactly where I want it and how to manipulate, move, copy, delete, etc, in a way that feels natural and intuitive.
Re: Don't use Vim for the wrong reasons (2020)
#49> if you think it's everywhere One of the counterpoint is vim not being available on Windows. But It is. Not by default, but most critical stuff aren't there by default anyway and vim will be one of the easiest block to have ready. Then Windows comes with WSL, where I think most people who even care in passing about vim will spend their time, so we're back to the editor they'd use on Linux anyway. That was to me the…
At the time of writing, the supposed ubiquity of Vim, or rather Vi-clones, was often touted as a strong selling point by people with a severe case of Linux-myopia. The "counterpoint" is not that Vim is not _available_ on Windows. It is that Vim is not on Windows _out of the box_. You must install the native binary to have it or, like you suggest, install _another system_ on your machine… that actually comes with Vim.…
But I also feel that ship has sailed for most software. We joke that windows/macos's default browser is only there to go install Chrome/firefox or any other browser of choice, and I see the wider reality of it as most OSes requirement a decent amount of installation to get to a usable point, even for very basic tasks.
It's still easier to use software that is mostly available everywhere in mostly the same shape and form (also why so many people bet on VSCode I think)
Re: Don't use Vim for the wrong reasons (2020)
#50I hate those YouTube videos "turn vim into an IDE". The people who watch those only care about bragging that they use vim, nothing else.
imaging being so disconnected from reality to think that your editor of choice if something to brag about
Of course, you say, driving some expensive car means you get more attention, right? Well, yes, and it doesn't make you any better of a person...if your text editor is your car and people care about what car you drive, then maybe it also gets you some attention...
But yes it is sad that we get wrapped up in the unimportant things in life. Good to have some escapes, too, though.