set nocompatible " Use Vim defaults (much better!) set clipboard="" " fix braindead clipboard handling set bs=2 " allow backspacing over everything in insert mode set ai " always set autoindenting on set tw=74 " always limit the width of text to 74 filetype indent on "set cindent shiftwidth=3 for c programming, make it auto-detect! "set cinoptions=t0 map :so ~/.vimfoldrc set backup " keep a backup file set viminfo='20,\"50 " read/write a .viminfo file, don't store more " than 50 lines of registers " Don't use Ex mode, use Q for formatting map Q gq map u :nohl " toggle 'paste' mode with F5 map :set paste!:set paste? " toggle syntax highlighting with F7 map :if exists("syntax_on") \| syntax off \| else \| syntax enable \| endif set wildmode=longest,list " filename completion longest first, then list set scrolloff=3 " keep 3 lines of context at all times set incsearch " incremental searching set ignorecase " ignore case when searching set smartcase " unless case is specified in search string set mouse= set expandtab " expand tabs to spaces set tabstop=3 " set number of spaces in a tab syntax on " turn on syntax highlighting set backupdir=$HOME/tmp " if &term =~ "xterm" " if has("terminfo") " set t_Co=8 " set t_Sf=[3%p1%dm " set t_Sb=[4%p1%dm " else " set t_Co=8 " set t_Sf=[3%dm " set t_Sb=[4%dm " endif " endif set background=dark