Use ":set paste" when pasting into Vim
In the past, when I'd paste code into Vim, it would indent each line one additional level. Now I know the solution is to do:
:set paste
- Paste in code
- Note there's no extraneous indentation!
:set nopaste
(just to reset)
I really wish I had found this sooner...