]> git.rmz.io Git - dotfiles.git/blobdiff - vimrc
zsh: use XDG_{CONFIG,CACHE}_HOME
[dotfiles.git] / vimrc
diff --git a/vimrc b/vimrc
index 243745e479041713308ef938376d415224a073e7..db95efec73ff7dbc17d9c6dc91e1ea23eafffe45 100644 (file)
--- a/vimrc
+++ b/vimrc
@@ -3,10 +3,25 @@
 " Author:   Samir Benmendil <samir.benmendil[at]gmail[dot]com>
 "
 
 " Author:   Samir Benmendil <samir.benmendil[at]gmail[dot]com>
 "
 
-filetype plugin indent on
+filetype off
+set rtp+=~/.vim/bundle/vundle/
+call vundle#rc()
+
+Bundle 'gmarik/vundle'
+Bundle 'wincent/Command-T'
+Bundle 'bling/vim-airline'
+Bundle 'ctrlp.vim'
+Bundle 'fugitive.vim'
+Bundle 'Gundo'
+Bundle 'The-NERD-tree'
+Bundle 'surround.vim'
+Bundle 'Syntastic'
+Bundle 'Tagbar'
+Bundle 'tComment'
+Bundle 'Valloric/YouCompleteMe'
+Bundle 'elzr/vim-json'
 
 
-" pathogen.vim runtime path manipulation
-silent! call pathogen#infect()
+filetype plugin indent on
 
 " moving around, searching and patterns {{{1
 set incsearch           " show match for partly typed search command
 
 " moving around, searching and patterns {{{1
 set incsearch           " show match for partly typed search command
@@ -20,6 +35,15 @@ nmap <silent> <Leader>n :silent nohl<CR>
 nmap <Leader># :%s:<C-R>/::gn<CR>
 " center cursor after search
 nnoremap n nzz
 nmap <Leader># :%s:<C-R>/::gn<CR>
 " center cursor after search
 nnoremap n nzz
+" disable arrows
+inoremap <Up> <NOP>
+inoremap <Down> <NOP>
+inoremap <Left> <NOP>
+inoremap <Right> <NOP>
+noremap <Up> <NOP>
+noremap <Down> <NOP>
+noremap <Left> <NOP>
+noremap <Right> <NOP>
 
 set nostartofline       " don't  move the cursor to the first non-blank char of a line
 set path=.,**           " current + subdirectory search for :find, :grep:, ...
 
 set nostartofline       " don't  move the cursor to the first non-blank char of a line
 set path=.,**           " current + subdirectory search for :find, :grep:, ...
@@ -178,6 +202,9 @@ set undodir=$HOME/.vim/backupdir
 
 set autowrite                   " automatically write a file when leaving a modified buffer
 
 
 set autowrite                   " automatically write a file when leaving a modified buffer
 
+" save with sudo
+cmap w!! w !sudo tee % > /dev/null
+
 " command line editing {{{1
 set history=500                 " how many command lines are remembered
 set wildmode=longest:full       " specifies how command line completion works
 " command line editing {{{1
 set history=500                 " how many command lines are remembered
 set wildmode=longest:full       " specifies how command line completion works
@@ -233,6 +260,12 @@ let g:tagbar_autoshowtag = 1
 let g:tagbar_width = 25
 let g:tagbar_iconchars = ['+', '-']
 
 let g:tagbar_width = 25
 let g:tagbar_iconchars = ['+', '-']
 
+" YouCompleteMe {{{2
+let g:ycm_extra_conf_globlist = ['/mnt/data/src/*']
+
+" vim-json {{{2
+let g:vim_json_syntax_conceal = 0
+
 " functions {{{1
 " Convenient command to see the difference between the current buffer and the
 " file it was loaded from, thus the changes you made.
 " functions {{{1
 " Convenient command to see the difference between the current buffer and the
 " file it was loaded from, thus the changes you made.