Rowland Carlson

Vim : why and how

2020-05-17

The main tool that I use everyday is a text editor first released in 1991. It's Vim, and I love it. Here are my thoughts on why.

It's probably not for you.

It's not for people looking for something familiar. It's keybinds are built for efficiency, and predate modern keybindings.

If you're looking for special features or formatting, it's not for you. It's designed to edit text. It doesn't have the features of an IDE for coding or the formatting of a word processor.

If you prefer to use the mouse, it's not for you. While its graphical version does allow for the mouse, it's optimized for keyboard use. Vim only becomes more efficient than other tools when it's used through the keyboard.

But, if you're looking for a powerful, versatile text editor, and don't mind relearning hand movements, Vim is for you.

What is it?

It's like Notepad, but better in every way.

It's known for being keyboard-centric. The tool can be used to its full functionality without taking your hands off the keyboard.

It's built for editing, not writing. It uses two main modes for movement and writing, allowing for the reuse of easy to reach keys for movement and editing.

It's commands are composable. Each movement command can be paired with any editing command. This allows for rapid and effective editing with few keystrokes.

Why Vim over other tools?

It's long-lived. Vim has been in use for 29 years. Despite changes in how computers are used, it has a growing community that is actively developing Vim. Vim is a text editor, a tool that will remain useful independent of what languages it is used for.

It's hard to master. I want to pursue mastery in the tools that I use, and I look for tools that reward that drive. Because Vim's commands are composable, there are many ways to accomplish the same thing. Vim rewards each new thing I learn with faster and more versatile ways of doing things.

It's lightweight. Designed for computers with far less power than our current machines, Vim requires few resources to run. I can open Vim directly, edit my file, and rerun a script all without leaving the terminal. This makes it easy to edit files, run tests, and commit to git without moving my hands off the keyboard.

It's portable. I can maintain my workflow on every system I use. Vim works equally well on Windows, Linux virtual machines, and even my OpenBSD server. Since it runs from the command line, I can use the same editor through tty--no graphics needed.

I've spent months learning tools that never ended up being useful. It's refreshing to know that regardless of where I end up, learning Vim will be useful. In fact, this article and the html to turn it into a webpage, were written in Vim.