January 3, 2011

How to pipe STDOUT to vim

I usually use ColorDiff when I want to get a colorized diff from the command line.

mike@shiner $ cvs diff -up | colordiff

I was talking with a friend about vim and he showed me how to utilize vim for a similar purpose.

mike@shiner $ cvs diff -up | vim -

This is great because it gives you the same syntax highlighting benefits, but you don't have to install another application.