The minimum vi(m) you need to know
Tiger asks… how do I edit text files in my commandline?
Vim (and vi) is a commandline text editor. And let’s just say, it can do a LOT.
Too much, some would say. As the old joke goes, you can lean on your keyboard while using the darn thing and whatever you land on, it actually means something.
I don’t personally embrace vim as my text editor of choice.
Still, having even only a moderately powerful text editor in your commandline is very beneficial. Whether you want to work with git or have to ssh onto a server and edit something, even working with your database can become easier in certain circumstances.
This article is not a complete tutorial on vim
or even vi
. There’s plenty of “cheat sheets” online already, after all.
But if you’ve ever looked at some of them, they may look quite intimidating and overwhelming.
The goal of this article is to teach you some very basic stuff. Enough so you can work with vim and maybe feel less overwhelmed if and when you do want to look up how to do more advanced stuff.
VI vs VIM
vim
stands for “vi
improved”, adding a lot of functionality on top of vi
like code highlighting etc, that are irrelevant to us here who only want to know the bare minimum to get by.
There are some important differences worth noting, though: