How I started using Vim

I’ve been using Vim as my primary editor for the last two years and it’s not because I can’t get out of it .

I tried using it several times before, but I couldn’t quite get used to it. A lot of it had to do with the fact that Vim is not like any other regular editor, it’s a modal editor. Other normal ‘modeless’ editors have only one mode, where you can start entering or editing text right away. In Vi or Vim, there are two primary modes- insert mode where you edit or insert text and the normal mode where you perform other operations likes searching, moving around the document or enter commands. You don’t need to use the mouse at any time. It was quite confusing, and I found it cumbersome to work with the keyboard all the time.

Due to the whole cult around Vim and Emacs, I kept coming back to it several times, but I couldn’t fully get into it, and I would eventually fall back to using my regular editor. There is this popular conception that you’re not a real programmer if you don’t know or use one of either Vim or Emacs, so I was quite determined to learn it.

The vanilla Vim is quite minimal and doesn’t come with many features that are common in editors like Sublime and VS Code. This was one of the reasons I would always fall back to using other editors after trying out Vim for a couple of days. As I became more comfortable with Vim, I found out about plugins and how they can be used to make Vim behave the way you want it to.

The plugins made a lot of difference, and now I don’t feel the need to go back to Sublime or VS Code anymore.  Especially, the combination of FZF and NERDTree makes working with multiple files a breeze.

The keybindings made much more sense when I started using them. The thing with Vim keybindings is that they not a bunch of unrelated keyboard shortcuts that you have to memorize, but composable in the sense that you can combine them to manipulate text. When you realize this simple idea, the key combinations seem a lot more intuitive. This video explains it in a much better way than I can.

After a few weeks of Vim, I got so used to the keybindings that I went ahead and installed chrome extension to make them work with the Google Chrome.

I have also tried using Emacs, but I couldn’t quite get the hang of it. Mostly because I am addicted to Vim key bindings now? Maybe I should start with Spacemacs? I feel a lot more productive with Vim, but I have heard some good things about Emacs too. Maybe, I will give it a shot.