Why mastering VIM will make you a better programmer

04 April 2020


The year is 2020.

Our systems are getting more powerful year by year.

Technology is being innovated at a pace like no other.

Bit by bit, more and more services are being automated and written in various languages by a wide variety of IDE's

Yet, a decades old tool still plays a big part in this process.

What Is Vim?

Vim is a highly configurable text editor, a somewhat improved version of the default vi editor distributed with most UNIX based systems.

It's important not confuse vim as a word editor. However, the tool can be used for all types of text editing, from composing email to editing configuration files.

Why should I use Vim?

  • Persistent, multi-level undo tree
  • Extensive plugin system
  • Support for hundreds of programming languages and file formats
  • Powerful search and replace
  • Integrates with many tools

The setup

While vim comes installed by default on most unix systems, the latest release can be sourced here.

For plugin management, we'll be using vim-plug

Next, let's create a config file (using vim):

this is what code should look like

Our .vimrc will look like this:

Save (:wq), reload the .vimrc and :PlugInstall to install plugins.

Plugins

What makes vim powerful is the extensive list of plugins that can be used to augment the editor's existing functionality. Here's a list of plugins I use when working with React.