Jens Oliver Meiert

Use my latest work: latest tech book · latest non-tech book · latest optimization tool · latest defense tool

Tip: vi Configuration

Published on May 25, 2008 (updated Aug 17, 2024), filed under . (Share this post, e.g., on Mastodon.)

This and 133 other posts are also available as a well-behaved ebook: On Web Development.

Long story short: It’s easy to modify the vi editor’s standard configuration. The most useful changes probably relate to encoding (UTF-8) and display of line numbers. In order to do that, go to your home directory (enter cd), create a file called .exrc (or, for Vim, .vimrc) unless it already exists (enter vi .exrc, press i or a, paste the following, and save by pressing esc and entering :wq):

:set encoding=utf-8
:set number

That’s it. If you’re interested in additional options, perhaps have a look at a vi cheatsheet (PDF). It includes additional :set parameters (you can enter these in command mode, too). Or check out a book about vi—yes, the editor infamously, “unofficially pronounced ‘six’ because of the feeling one gets when using vi that it may be the text editor of the antichrist.”

Update (February 17, 2013)

Here’s my vi configuration, a few years later:

:set encoding=utf-8
:set number
:syntax on

This also enables syntax highlighting.

About Me

Jens Oliver Meiert, on March 2, 2026.

I’m Jens (long: Jens Oliver Meiert), and I’m an engineering lead, guerrilla philosopher, and indie publisher. I’ve worked as a technical lead and engineering manager at various companies (e.g., Google); I’m an active web and tool developer (code optimization, digital defense), a contributor to web standards (like HTML, CSS, WCAG), and a book author (O’Reilly, Frontend Dogma).

I love trying things—in web development and engineering management, but also in politics and philosophy, where I hold to one idea in particular: that we can only be well if we take good care of everyone. Here on meiert.com I talk about some of my perspectives and experiences. (Interpret charitably but be critical—and share feedback and advice that makes my work better.)