Created
September 28, 2011 13:14
-
-
Save mmchaney/1247902 to your computer and use it in GitHub Desktop.
.vimrc.local
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:let loaded_netrw = 1 | |
:let loaded_netrwPlugin = 1 | |
let mapleader = "," | |
"set transparency=0 | |
"fix regex | |
nnoremap / /\v | |
vnoremap / /\v | |
filetype off | |
call pathogen#runtime_append_all_bundles() | |
call pathogen#helptags() | |
filetype plugin indent on | |
set nobackup | |
set nowritebackup | |
set noswapfile | |
set cursorline | |
set selectmode=key | |
au BufNewFile,BufRead *.erb,*.rhtml set ft=eruby.html | |
set shell=/bin/bash\ -li | |
map <F1> <ESC>:sil ! rsc<CR> | |
map <F2> <ESC>:IndentGuidesToggle<CR> | |
nmap <silent> <F3> <Esc>:call g:Jsbeautify()<CR> | |
imap <silent> <F3> <C-O>:call g:Jsbeautify()<CR> | |
let g:indent_guides_start_level = 2 | |
let g:indent_guides_guide_size = 1 | |
autocmd BufWritePre * :%s/\s\+$//e | |
nnoremap <silent> <Space> @=(foldlevel('.')?'za':'l')<CR> | |
vnoremap <Space> zf | |
set foldmethod=syntax | |
"statusline setup | |
set statusline=%f "tail of the filename | |
"display a warning if fileformat isnt unix | |
set statusline+=%#warningmsg# | |
set statusline+=%{&ff!='unix'?'['.&ff.']':''} | |
"display a warning if file encoding isnt utf-8 | |
set statusline+=%#warningmsg# | |
set statusline+=%{(&fenc!='utf-8'&&&fenc!='')?'['.&fenc.']':''} | |
set statusline+=%* | |
set statusline+=%h "help file flag | |
set statusline+=%y "filetype | |
set statusline+=%r "read only flag | |
set statusline+=%m "modified flag | |
set statusline+=%#warningmsg# | |
set statusline+=%{fugitive#statusline()} | |
set statusline+=%* | |
set nofoldenable | |
set ignorecase | |
set smartcase | |
set gdefault | |
set incsearch | |
set showmatch | |
set hlsearch | |
nnoremap <leader><space> :noh<cr> | |
nnoremap <tab> % | |
vnoremap <tab> % | |
"Line wrapping | |
set wrap | |
set textwidth=79 | |
set formatoptions=qrn1 | |
set colorcolumn=85 | |
"Sessions | |
map <F5> :mksession! ~/.vimsession <cr> " Quick write session with F2 | |
map <F6> :source ~/.vimsession <cr> " And load session with F3 | |
inoremap jj <ESC> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment