public
Last active

YieldThought's .vimrc

  • Download Gist
.vimrc
VimL
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
"Set Mapleader
let mapleader = ","
let g:mapleader = ","
 
"Theme
colo zenburn
 
"NERDTree
map <Leader>, :NERDTreeToggle<cr>
 
"Taglist
let Tlist_Ctags_Cmd = '/usr/local/bin/ctags'
let Tlist_WinWidth = 50
map <Leader>. :TlistToggle<cr>
 
"Check python syntax
let g:pcs_hotkey = '<LocalLeader>x'
 
"Quick Open
let g:CommandTMaxFiles=30000
set wildignore+=*.o,.ddt-*,.treeserver-*
let g:CommandTMatchWindowAtTop = 1
 
"Scratch buffer
map <Leader>k :ScratchOpen<cr>
 
"RT
map <Leader>rt "zyiw:ScratchOpen<cr>:0r!~/Work/code/util/rt show -f id,Subject,Queue,Status,Creator,Owner,LastUpdated,Priority ticket/<C-R>z<cr>o<Esc>
map <Leader>tt "zyiw:r!~/Work/code/util/rt show -f Subject ticket/<C-R>z \| grep Subject \| cut -d' ' -f2-<cr>kA:<Esc>Jj
 
"ctags
set tags=tags;$HOME
 
"Rebuild cscope
map <Leader>cs !cscope -bqk<cr>:cs add cscope.out<cr>
 
"Buffer shortcuts
map <Leader>f :b#<cr>
 
"ddt log files
map <Leader>gdb :!cdata-from-log % >/tmp/cdata.log<cr>:e /tmp/cdata.log<cr>
 
"Disable virtual bell
set vb t_vb="
 
"Make backspace work
set backspace=2
 
"Code navigation
map <Leader>gd ?^{<cr>kf:ll
 
"Misc stuff
set autoread
set hidden
set hlsearch
set incsearch
set ignorecase
set smartcase
set smartindent
map <Leader>c :let @/ = ""<cr>
syntax enable
set nu
set textwidth=0 " No annoying word wrapping
set tabstop=4
set shiftwidth=4
set expandtab
set guifont=Menlo:h14
filetype on
filetype plugin on
set nocp
autocmd FileType python set omnifunc=pythoncomplete#Complete
autocmd FileType javascript set omnifunc=javascriptcomplete#CompleteJS
autocmd FileType html set omnifunc=htmlcomplete#CompleteTags
autocmd FileType css set omnifunc=csscomplete#CompleteCSS
autocmd FileType xml set omnifunc=xmlcomplete#CompleteTags
autocmd FileType php set omnifunc=phpcomplete#CompletePHP
" Replaced by clang_complete for now
" autocmd FileType c set omnifunc=ccomplete#CompleteCpp
autocmd FileType ChangeLog set tw=80

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.