My vim configuration
git clone https://mcol.xyz/code/vim-misc
Log | Files | Refs | README

commit d5f9e6e934449c871a12b06a16e38cd4b66c875d
parent 792da2d1f8c345337af41f36552612f21e35dfd3
Author: mcol <mcol@posteo.net>
Date:   Sat,  9 Feb 2019 10:22:58 +0000

updated vimwiki ftplugin

Diffstat:
Mftplugin/vimwiki.vim | 42+++++++++++++++++-------------------------
1 file changed, 17 insertions(+), 25 deletions(-)

diff --git a/ftplugin/vimwiki.vim b/ftplugin/vimwiki.vim @@ -8,41 +8,33 @@ "nmap <Leader>whh Vimwiki2HTMLBrowse " open index wiki in horizontal split -nmap <Leader>ws :sp<CR><Leader>ww +nmap <buffer> <Leader>ws :sp<CR><Leader>ww -" split follow link -nmap <Leader>s <Plug>VimwikiSplitLink -nmap <Leader>v <Plug>VimwikiVSplitLink - -" some html shortcuts -nmap <Leader>b msA<br><Esc>`s -nmap <Leader>i msI<i><Esc>A</i><Esc>`s -nmap <Leader>r mso<hr><Esc>`s -nmap <Leader>R msO<hr><Esc>`s - -" go to pages -nmap <Leader>gp /[[/papers/papers<CR><CR> -nmap <Leader>gl /[[/topics/learning<CR><CR> -nmap <Leader>gb /[[/topics/brain<CR><CR> -nmap <Leader>gd /[[/topics/direction<CR><CR> -nmap <Leader>gm /[[/topics/muscles<CR><CR> +" go to papers page +nmap <buffer> <Leader>gp /[[/papers/papers<CR><CR> " save all as HTML -nmap <Leader>wa :VimwikiAll2HTML<CR> -nmap <Leader>wah :VimwikiAll2HTML<CR>:Vimwiki2HTMLBrowse<CR><CR> +nmap <buffer> <Leader>wa :VimwikiAll2HTML<CR> +nmap <buffer> <Leader>wah :VimwikiAll2HTML<CR>:Vimwiki2HTMLBrowse<CR><CR> " save as HTML and quit -nmap <Leader>wq :VimwikiAll2HTML<CR>WQ +nmap <buffer> <Leader>wq :VimwikiAll2HTML<CR>:wq<CR> " follow next link -nmap g<CR> /[[<CR><CR> +nmap <buffer> g<CR> /[[<CR><CR> " paste copied bullet pointed link as title -nmap <Leader>p 0f\|yy<CR>Pdf\|$xx===o<CR> +nmap <buffer> <Leader>p 0f\|yy<CR>Pdf\|$xx===o<CR> " open pdf from papers page -nmap <Leader>o 0f\|lvt]y:let a = substitute(@*, ' ', '_', 'g') \| !qpdfview --unique "~/work/research/papers/" . a . ".pdf" & +nmap <buffer> <Leader>o 0f\|lvt]y:let a = substitute(@*, ' ', '_', 'g') \| !qpdfview --unique "~/work/research/papers/" . a . ".pdf" & " update papers page with new pdf files -nmap <Leader>u :!vimwiki_add_papers.sh<CR> +nmap <buffer> <Leader>u :!vimwiki_add_papers.sh<CR> + +" run goyo +nmap <buffer> <Leader>g :Goyo<CR> + -setlocal textwidth=80 +setlocal wrap +setlocal linebreak +setlocal breakindent