diff options
author | eug-vs <eug-vs@keemail.me> | 2021-05-05 23:08:10 +0300 |
---|---|---|
committer | eug-vs <eug-vs@keemail.me> | 2021-05-05 23:11:30 +0300 |
commit | 5369c3370ddc54de57e864b20e2d07a8f8608756 (patch) | |
tree | d3124e65b721ea62888c0dff6ad6f76d2206b438 /.vimrc | |
parent | 3a89762ed354a491107c3b9c1020472cd84935c0 (diff) | |
download | dotfiles-5369c3370ddc54de57e864b20e2d07a8f8608756.tar.gz |
feat(vim): install coc.nvim and calendar.vim
Diffstat (limited to '.vimrc')
-rw-r--r-- | .vimrc | 24 |
1 files changed, 22 insertions, 2 deletions
@@ -127,7 +127,7 @@ set tags+=.git/tags " enable typescipt highlighting augroup SyntaxSettings autocmd! - autocmd BufNewFile,BufRead *.tsx set filetype=typescript + autocmd BufNewFile,BufRead *.tsx set filetype=typescriptreact augroup END " easier indentation @@ -138,7 +138,14 @@ vnoremap > >gv autocmd BufWritePre * %s/\s\+$//e " Vimwiki -let g:vimwiki_list = [{'path': '~/Documents/wiki/', 'syntax': 'markdown', 'ext': '.md'}] +let g:vimwiki_list = [ + \ {'path': '~/Sync/', 'syntax': 'markdown', 'ext': '.md', 'auto_generate_links': 1}, + \ {'path': '~/Documents/wiki/', 'syntax': 'markdown', 'ext': '.md'}, +\] + +let g:vimwiki_markdown_link_ext = 1 +let g:calendar_options = 'nornu' + nnoremap <Leader>c :let &cole=(&cole == 2) ? 0 : 2 <bar> echo 'conceallevel ' . &cole <CR> function! VimwikiLinkHandler(link) @@ -158,4 +165,17 @@ function! VimwikiLinkHandler(link) endif endfunction +" Coc.nvim +nmap <silent> gd <Plug>(coc-definition) +inoremap <expr> <cr> pumvisible() ? "\<C-y>" : "\<C-g>u\<CR>" +nnoremap <silent> <Leader>t :call <SID>show_documentation()<CR> + +function! s:show_documentation() + if (index(['vim','help'], &filetype) >= 0) + execute 'h '.expand('<cword>') + else + call CocAction('doHover') + endif +endfunction + " TODO: command to toggle comments https://www.chrisatmachine.com/Neovim/09-vim-commentary/ |