trevor elliott

Vim Mapping Context

If you’re like me, you’ve got a lot of filetype-specific macros defined in your vim config. I tend to put these in $VIM/after/syntax so that I can keep it all self-contained, but up until recently, macros had been bleeding into different filetype contexts. The problem was that I had been installing all macros into the global scope, instead of the buffer scope, like this:

Vim Register Trick

Well, it’s new to me.