Skyler Grey | a7feb6e | 2022-08-26 06:51:55 +0100 | [diff] [blame] | 1 | nmap <silent> ]c :call CocAction('diagnosticNext')<cr> |
| 2 | nmap <silent> [c :call CocAction('diagnosticPrevious')<cr> |
| 3 | nmap <silent> <Leader>fs <Plug>(coc-codeaction-selected) |
Skyler Grey | 97efa1a | 2022-10-30 23:10:37 +0000 | [diff] [blame^] | 4 | nmap <silent> <Leader>fb <Plug>(coc-codeaction) |
| 5 | nmap <silent> <Leader>ff <Plug>(coc-codeaction-cursor) |
| 6 | nmap <silent> <Leader>fc <Plug>(coc-codeaction-cursor) |
| 7 | nmap <silent> <Leader>fr <Plug>(coc-rename) |
| 8 | nmap <silent> <Leader>fi <Plug>(coc-fix-current) |
Skyler Grey | a7feb6e | 2022-08-26 06:51:55 +0100 | [diff] [blame] | 9 | nmap <Leader>fe <Cmd>CocCommand explorer<CR> |
| 10 | |
| 11 | function! s:show_documentation() |
| 12 | if (index(['vim','help'], &filetype) >= 0) |
| 13 | execute 'h '.expand('<cword>') |
| 14 | else |
| 15 | call CocAction('doHover') |
| 16 | endif |
| 17 | endfunction |
| 18 | |
| 19 | nnoremap <silent> K :call <SID>show_documentation()<CR> |