Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
xpac27 committed Nov 23, 2017
1 parent 1f62e1e commit ded7773
Showing 1 changed file with 12 additions and 13 deletions.
25 changes: 12 additions & 13 deletions .vimrc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ call plug#begin('~/.vim/plugged')

" Magic
" -------------------------------------------------------------------------
Plug 'valloric/YouCompleteMe', { 'do': './install.py --clang-completer' }
Plug 'valloric/YouCompleteMe', { 'do': './install.py --clang-completer --system-libclang' }
Plug 'w0rp/ale'
Plug 'brookhong/cscope.vim'

Expand Down Expand Up @@ -274,9 +274,6 @@ nnoremap vv ^vg_
vnoremap < <gv
vnoremap > >gv
" search selected text
vnoremap // y/<C-R>"<CR>
" clear searches
nnoremap <ESC><ESC> :nohlsearch<CR>
Expand All @@ -303,10 +300,10 @@ noremap <unique> <Leader>y viw"wy
noremap <unique> <Leader>p viw"wp
" Compile/test
map <Leader>m :AsyncRun make compile<CR>
map <Leader>t :AsyncRun make test<CR>
map <Leader>c :AsyncStop<CR>
map <Leader>C :AsyncStop!<CR>
map <Leader>m :wa<CR>:AsyncRun make compile<CR>
map <Leader>t :wa<CR>:AsyncRun make test<CR>
map <Leader>c :wa<CR>:AsyncStop<CR>
map <Leader>C :wa<CR>:AsyncStop!<CR>
" Cscope
nmap <leader>x :cs find s <C-R>=expand("<cword>")<CR><CR>
Expand All @@ -332,12 +329,14 @@ nmap <silent> <Leader>s :FSHere<cr>
" Not usefull
nmap K <nop>
nmap <C-s> <nop>
nmap ^S <nop>
" Repurpose cursor keys
nnoremap <silent> <Left> :cnext<CR>
nnoremap <silent> <Down> :cprevious<CR>
" nnoremap <silent> <Left> :cpfile<CR>
" nnoremap <silent> <Right> :cnfile<CR>
nnoremap <silent> <Up> :cprevious<CR>
nnoremap <silent> <Down> :cnext<CR>
nnoremap <silent> <Left> :cpfile<CR>
nnoremap <silent> <Right> :cnfile<CR>



Expand Down Expand Up @@ -451,7 +450,7 @@ vnoremap <C-c> :TComment<CR>j
let g:clang_format#auto_format_on_insert_leave = 0
let g:clang_format#auto_format = 0
let g:clang_format#detect_style_file = 1
autocmd FileType cpp nmap <SPACE><SPACE> :%s/\s\+$//e<CR>:set nohlsearch<CR>:ClangFormat<CR>
autocmd FileType cpp nmap <SPACE><SPACE> :%s/\s\+$//e<CR>:set nohlsearch<CR>:ClangFormat<CR>zz

" Git-Gutter
Expand Down

0 comments on commit ded7773

Please sign in to comment.