]> git.rmz.io Git - dotfiles.git/commitdiff
vim: map `:YcmCompleter Goto` in ftplugin
authorSamir Benmendil <me@rmz.io>
Thu, 7 Apr 2016 10:15:54 +0000 (11:15 +0100)
committerSamir Benmendil <me@rmz.io>
Thu, 7 Apr 2016 10:15:54 +0000 (11:15 +0100)
vim/ftplugin/cpp.vim
vim/vimrc

index 7dd40e60d9239aa5f98ec1e98a78c22e39cda2df..5f68c35097d7c46754c2c6c087fd6e9198f91142 100644 (file)
@@ -21,6 +21,9 @@ augroup fswitch
     au BufEnter *.cpp let b:fswitchlocs = 'reg:/\Csource/include/'
 augroup END
 
+nnoremap <buffer> gd :YcmCompleter GoTo<CR>
+nnoremap <buffer> <C-W>d :vs<CR>:YcmCompleter GoTo<CR>
+
 setlocal foldmethod=syntax
 " set foldlevel according to number of matches of 'namespace' and 'class' not
 " containing ';'
index 25fa46045b05c4e4a33e152ddd4c8166ae5cdf65..cb6eceaf315ac8c6d1e20a0b5007319b015c9004 100644 (file)
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -691,7 +691,6 @@ let g:ycm_complete_in_comments = 1
 let g:ycm_complete_in_strings  = 1
 let g:ycm_autoclose_preview_window_after_insertion = 0
 "let g:ycm_extra_conf_vim_data = ['%:p']
-nnoremap gd :YcmCompleter GoTo<CR>
 
 " vim-easy-align {{{2
 " start interactive EasyAlign in visual mode