Sometimes copying code from webpage to vim can be painful. You might end up loosing all the newlines.  So I prefer to copy (from webpages)  using html source.  If you use html source, you will have to replace >, < .. and lot more to  <,> and stuff. 
The following will do it automatically for you.
:%!perl -pne 'use HTML::Entities; $_=decode_entities($_)'
Thanks to godlygeek from #vim .
Thursday, May 15, 2008
Subscribe to:
Comments (Atom)
