Learn Thou Editor

AngularJS editor

When it comes to learning your editor, most of us avoid it like the plague. It’s time consuming, opinions run rampant, and quite frankly, we’ve got better things to do!

Yet this avoidance isn’t effective (and we know it). Simple tasks such as performing “find and replace” become much more difficult when we don’t understand how our editor operates…

So why do we still refuse to eat our vegetables? For a few reasons:

It’s overwhelming.

Reviewing an editor, like emacs (or vim, or sublime text) is overwhelming. Not only can the editor accomplish many tasks, but there are multiple ways of doing them! For instance, when performing a “find and replace” on a file in emacs, you can use a regular expression (now you have two problems) or a keyboard macro. All these options can quickly lead you down a rabbit hole and wondering (three hours later) “what did I just do with my time?!”

Getting sidetracked by editor holy wars

When asking a co-worker for advice, if that co-worker doesn’t use your editor of choice the discussion can devolve into: “Emacs is awful. You should use Vim and do it this way.” Then instead of learning your editor, the conversation continues into the merits of one editor versus another, when both could do the job adequately. Avoid this at all costs.

Deadlines

We have work to do. When working on a bugfix or a feature with a tight deadline, you can’t afford to spend time learning your editor. But then, not learning your editor makes your text editing less efficient, which makes development work take longer than it should. Soooo…

A Better Approach

Despite all these variables though, learning your editor is worth it. You just have to get strategic. Here’s my suggestion: while doing your everyday work, keep a notepad with an ongoing “need to learn” list for your editor. Then, when you find yourself wanting to perform a particular task (search across project files) and don’t know how to do it, you can come back to it later vs. stopping everything to figure it out right then and there.

Then once a week, for thirty minutes, take one item on your list and look up how do it. For the coming week, keep in your mind (or a post-it note on your monitor) how to perform this task in your editor, and use it when necessary. This will help you remember the task and how to do it. Next week, you can cross off another item on your list.

This approach requires a small time commitment each week and avoids going down the rabbit hole of configuring your editor during your normal work day.