Fix languageClient configuration

ada
blallo 2022-01-28 15:57:47 +01:00
parent a34ebb1abf
commit fb3eb54de8
Signed by: blallo
GPG Key ID: 0CBE577C9B72DC3F
4 changed files with 6 additions and 3 deletions

View File

@ -0,0 +1 @@
let g:LanguageClient_fzfOptions = fzf#vim#with_preview().options

View File

@ -32,6 +32,7 @@ let g:LanguageClient_loggingFile = expand('~/.vim/LanguageClient.log')
function LC_maps()
if has_key(g:LanguageClient_serverCommands, &filetype)
nnoremap <F5> :call LanguageClient_contextMenu()<CR>
nnoremap <silent> K :call LanguageClient#textDocument_hover()<CR>
nnoremap <silent> gdd :call LanguageClient#textDocument_definition()<CR>
nnoremap <silent> gdi :call LanguageClient#textDocument_implementation()<CR>

View File

@ -5,17 +5,17 @@
" set grepformat=%f:%l:%c:%m,%f+%l+%c+%m,%-G%f\\\|%l\\\|%c\\\|%m
" endif
if executable('rg')
let $FZF_DEFAULT_COMMAND = 'rg --files --hidden --follow --glob "!.git/*"'
let $RG_DEFAULT_COMMAND = 'rg --files --hidden --follow --glob "!.git/*"'
set grepprg=rg\ --vimgrep
command! -bang -nargs=* Find call fzf#vim#grep('rg --column --line-number --no-heading --fixed-strings --ignore-case --hidden --follow --glob "!.git/*" --color "always" '.shellescape(<q-args>).'| tr -d "\017"', 1, <bang>0)
endif
" Search in files with ripgrep + preview with bat
" Search in files with ripgrep + preview with bat
function! Fzf_dev()
let l:fzf_files_options = '--preview "bat --style=numbers,changes --color always {2..-1} | head -'.&lines.'"'
function! s:files()
let l:files = split(system($FZF_DEFAULT_COMMAND), '\n')
let l:files = split(system($RG_DEFAULT_COMMAND), '\n')
return s:format_list(l:files)
endfunction

1
vimrc
View File

@ -32,6 +32,7 @@ source $VIMHOME/config/before/vim-rooter.vim
packloadall
source $VIMHOME/config/after/ale.vim
source $VIMHOME/config/after/language-client.vim
""" general