Greetings and salutations to all fellow Vim lovers and potential recruits/victims.
The goal of this post is to encourage anyone who is curious about learning to use Vim to make the effort to do so. I’m not trying to take away your favorite GUI text editor. If you are happy using Kate or Mousepad or Gedit that’s fine with me. Since there are plenty of online videos to teach you how to use Vim, I’m going to concentrate on the why and not the how. Vim’s built-in learning module, vimtutor, is probably the best place to start for most people and that is well documented. So please allow me to share my enthusiasm about why Vim is a great gateway or maybe even a gateway to greatness.
I cannot think of anything that is better than Vim to have in your Linux toolbox. Knowing how to use the Vim key bindings sets you up for a natural progression to really useful things like Ranger and Vifm. I’m completely blown away by these two terminal file managers and I would never have bothered with either one if I hadn’t learned Vim first. And the nice thing about Linux is that you can have your cake and eat it too so I don’t have to settle for just one. That’s a practical and useful benefit that I got almost immediately. I’m looking at other terminal based programs now like Calcurse but I’ll cut this list off here so this post doesn’t get too long.
A little bit of background: My original notion in learning Vim was to use it as a stepping stone to also learn LaTeX. I think that the combination of Vim and LaTeX is probably the ultimate word processor. I’m just a regular (whatever that means) user, not a coder or programmer but I do write a lot of long documents.
The pandemic gave me a lot more time at home and I used this to start learning Vim. I’m glad I did and I wish I had made the time to learn this awesome editor years ago.
A couple of caveats about the learning process; mainly the timeline. Don’t plan on learning Vim on a Friday night when you have a project or homework due on Monday morning. They say it takes 3 weeks to learn a habit and I think that’s an accurate number. It took me a full 30 days to be comfortable in Vim but I’ve always been a slow learner. Hey, if I can learn how to do this, anyone can. It’s not that complicated. It just takes a little practice.
My practice went like this. I committed to spending at least 15 minutes a day, every day, for 30 days to learn Vim. I did it without skipping a day. A couple of those days were only 15 minutes and a few were as long as 2 hours but I would say my average practice per day was around 30 minutes. It worked. The first several days of using vimtutor, the built-in learning tool, were extremely rough and I think I invented a boatload of new curse words. The second week was still clumsy but I was encouragd. By week 3 I was high fiving myself in the mirror. The fourth week I’m sure I had a huge smile on my face because I could honestly say, “I’ve got this and it’s great.”
After a month of Vim practice, I was thoroughly corrupted, er, that is, converted to Vim. Not only was I comfortable using it but I enjoyed the speed and efficiency and now the thought of using Mousepad makes me cringe.
About the modal thing. Yes, Vim has modes, like insert mode, normal mode, command mode, and a couple of other niche cases that I don’t really use very much. Do not let this scare you and do not listen to the online nay-sayers who say that this is “just stupid.” Once you get used to Vim’s modal-way of doing things, it’s fantastic. The title of a popular Vim book is something like “Edit text at the speed of thought” and it turns out to be true.
I’ve tried a lot of so called Note-Taking programs over the years and have never been thrilled with any of them. Yes, syncing notes between devices is useful, but the programs themselves are clunky and boring. Enter Vim. I don’t think I’ll ever try another Note-Taking application now because I don’t need them anymore. They don’t offer the speed and power of Vim and since I pretty much always have my notebook with me I don’t miss the syncing aspect. Text files composed with Vim are good enough for my notes, especially when I can write them at warp speed.
To recap about Vifm and Ranger, learning the Vim key bindings has literally streamlined my entire way of using my computer. I guess that’s what people mean when they talk about their work flow. I feel like I actually have a work flow now. A much better, extremely fast, more efficient work flow.
I’m a few months into my Vim journey at this point. I have by no means achieved Vim-Mastery but I am very satisfied with the results so far. I’m still using vanilla Vim but I’m at a point where I have a good enough understanding to start using some plug-ins to do some productive things as well as adding some eye candy to make vanilla Vim a little nicer to look at. There’s even a Vim game plug-in that lets you hunt sheep. I kid you not.
So, if you are actually still reading this too long thread, what are you waiting for?
Open a terminal, type “vimtutor” and begin your Vim journey. I guarantee it will be, as Mr. Spock would say, long and prosperous. A journey you will enjoy.
Now if you will excuse me, I have to start learning LaTeX. If that goes as well as Vim, I will write another post later. Wish me luck.
Best regards to all.