X-Git-Url: https://git.rmz.io/dotfiles.git/blobdiff_plain/bfa7a2383b6e7742a6659578f4cc1f0ccee5a184..56388f1e2bc97e149a6cb95ae9d9c32bbaa54207:/vim/ftplugin/cpp.vim diff --git a/vim/ftplugin/cpp.vim b/vim/ftplugin/cpp.vim index fcd8066..c053fcc 100644 --- a/vim/ftplugin/cpp.vim +++ b/vim/ftplugin/cpp.vim @@ -18,7 +18,7 @@ let b:load_doxygen_syntax = 1 augroup fswitch_cpp au! - au BufEnter *.h let b:fswitchdst = 'c,cpp,cc' + au BufEnter *.h let b:fswitchdst = 'cpp,cc,c' au BufEnter *.h let b:fswitchlocs = '.,reg:|include.*|src|' au BufEnter *.hpp let b:fswitchdst = 'cpp,c' au BufEnter *.hpp let b:fswitchlocs = '.,reg:|include.*|src|' @@ -91,6 +91,10 @@ function! s:Debug(...) nnoremap :Step nnoremap :Over nnoremap :Finish + nnoremap :call TermDebugSendCommand('advance -source '.expand('%').' -line '.line(".")) + nnoremap :Step + nnoremap :Over + nnoremap :Finish endfunction command! -nargs=* -complete=file -bang Debug call Debug() | Termdebug command! -nargs=+ -complete=file -bang DebugCommand call Debug() | TermdebugCommand