VIM: Show a 3 character border on left of window

vim

Solution

You could use `foldcolumn` to create a gutter:

:set foldcolumn=3

If this adds fold markers to the gutter and you're not using folds at all, then you can set `foldmethod` to `manual` so that no folds are created automatically:

:set foldmethod=manual

Problem

Context I'm using the NERDTree plugin. The one thing that irks me is the visual vertical border between the NERDTree itself and my code. I find it slightly annoying to read my code. My current setup looks something like: ``` ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ........................#________________________________________________ ``` where the ... = NERDTree, the _ = my actual code, and the ### = some vertical grey border. Now, what I want is something like this: ``` ........................# ________________________________________________ ........................# ________________________________________________ ........................# ________________________________________________ ........................# ________________________________________________ ........................# ________________________________________________ ........................# ________________________________________________ ........................# ________________________________________________ ........................# ________________________________________________ ........................# ________________________________________________ ........................# ________________________________________________ ``` The idea is that I somehow inject a 3 character border between the vertical divider of the NERDTre and the left of my actual code. Now, I can almost achieve this via "set nu" -- except instead of getting spaces, I get a bunch of numbers. I would like something like "set nub", except instead of line numbers, I just get spaces. Question: How do I achieve the above?

Original source