Vim Core Config

This post has also a video version available:

In this article I want to share my thoughts and ideas about working with vim. If you are interested or you already use vim, I assume that you have a passion for improving and optimizing your workflows.

To take our text editing to the next level, we should start defining our goals, so we can keep improving in that direction.

It’s a good practice to idealize when defining goals, you know, aim for the stars and if we fail, we’ll land on the moon.

So for me, what I would ideally love to achieve when editing text is summarize very well in a sentence that you’ve probably read in many vim articles, and this is:

Text editing at the speed of thought

Hopefully in the far future we will have other input devices that will allow us to achieve such a goal with very little effort, but for the moment the keyboard seems to be our best brain-to-computer interface option for text editing. I think the mouse and touch screens can have their use cases, but vim allows us to avoid context switching and never have to leave our hands from the keyboard, which is great.

To this goal this I would add:

Text editing aligned with thoughts 

My point to “editing aligned with thoughts” is that I want to avoid having to internalize and mechanize weird key combinations as much as possible.
To be honest, I think that vim does a more than decent job in achieving so. Think about it, you can teach most of the commands just looking at them once:
d for delete, r for replace, b for back, e for end, u for undo, p for paste, o for open a new line, w for word, i for insert, a for amend,
I mean, some concepts behind these keys can be rather complex, but I don’t think they could be better aligned. We should strive to keep this characteristic, it is very powerful and can ease our mind to focus on thinking about the text in addition that it makes it easier to teach.

Having a clear and short path from thought to execution should be key within our editing goals. We should aim for easy to teach and easy to adopt mechanics. For me the way to achieve this is alignment is mnemonics. I want that anybody could learn the way I use vim after just looking at it once. But we will leave that for future more in depth videos. In this video we are just going to focus on the core configuration. Backward compatibility is also an important thing, I don’t want people to forget whatever they already know, knowledge should always be improved and reused. So my configuration tries to be as less intrusive as possible and respect all the default vim keybindings.

//File navigation:

    (E)dit (R)ecent         := e+r
    (E)dit in (P)project    := e+p

//File explorer:

    e(X)plorer (O)pen       := x+o
    e(X)plorer (L)ocate     := x+l
    e(X)plorer (P)roject    := x+p

//File Content Searching:

    (S)earch (P)roject      := s+p
    (S)earch (F)file        := s+f

//Undotree History:

    (U)ndo (O)pen          := u+o

  • Post Author:
  • Post Category:vim