vim does really lovely autoindenting. But what happens when you want to paste in pre-formatted text from somewhere else? All your code indents way off to the side, oh noes! Here's what to do.
:set pasteOkay, now paste.
:set nopastePerfect. I rated
this tip "life-changing".