Ignoring .vimrc file on startup

I have a customized vim file with some settings like this:

set nohls
set ai
set tabstop=4 shiftwidth=4 softtabstop=4 expandtab

This works great for my Python coding since tabs are converted to 4 spaces, etc. The problem I run into is when I need to copy and paste code that is already formatted, I end up with spaces run amok. Easy solution is to start up vim ignoring my .vimrc file, save the file, then reopening my file as normal. To ignore .vimrc on startup run:

vim -u NONE filename

Thanks to Evan Hahn and of course Google search :)

UPDATE: A better solution, IMO, that was just sent to me. Start up vim and use :set paste.

Comments

Popular posts from this blog

Database, schema, and table sizes in Greenplum

Greenplum update with multiple tables

Show running queries on Postgresql/Greenplum