Fix up java test
This commit is contained in:
parent
b0d41eb347
commit
bdca96f663
5 changed files with 52 additions and 4 deletions
24
support/test/java/test_project/java.vim
Normal file
24
support/test/java/test_project/java.vim
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
let g:ycm_java_jdtls_extension_path = [
|
||||
\ expand( '<sfile>:p:h:h:h:h:h' ) . '/gadgets/macos'
|
||||
\ ]
|
||||
|
||||
let s:jdt_ls_debugger_port = 0
|
||||
function! s:StartDebugging()
|
||||
if s:jdt_ls_debugger_port <= 0
|
||||
" Get the DAP port
|
||||
let s:jdt_ls_debugger_port = youcompleteme#GetCommandResponse(
|
||||
\ 'ExecuteCommand',
|
||||
\ 'vscode.java.startDebugSession' )
|
||||
|
||||
if s:jdt_ls_debugger_port == ''
|
||||
echom "Unable to get DAP port - is YCM initialized?"
|
||||
let s:jdt_ls_debugger_port = 0
|
||||
return
|
||||
endif
|
||||
endif
|
||||
|
||||
" Start debugging with the DAP port
|
||||
call vimspector#LaunchWithSettings( { 'DAPPort': s:jdt_ls_debugger_port } )
|
||||
endfunction
|
||||
|
||||
nnoremap <silent> <buffer> <Leader><F5> :call <SID>StartDebugging()<CR>
|
||||
Loading…
Add table
Add a link
Reference in a new issue