From 95d79cd39a97daf3bc32b891abff366403802b2b Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Mon, 20 May 2019 18:18:48 +0200 Subject: [PATCH] add basic wiki and zettel structure --- .config/nvim/init.vim | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim index 3ee22fa..e6c5555 100644 --- a/.config/nvim/init.vim +++ b/.config/nvim/init.vim @@ -79,7 +79,7 @@ Plug 'junegunn/limelight.vim', { 'for': ['markdown', 'txt'], 'on': 'Goyo' } " pr Plug 'rhysd/vim-grammarous', { 'for': ['markdown', 'txt'], 'on': 'Goyo' } " integrate vim with languagetool for grammar checking (needs java8) " Note-Taking Workflow -Plug 'fcpg/vim-waikiki' +Plug 'lervag/wiki.vim' Plug 'michal-h21/vim-zettel' " For async completion @@ -141,6 +141,7 @@ function! Prose() " PLUGIN: vim-textobj-sentence " enable extended sentence textobject use on md and plaintext files call textobj#sentence#init() + " hide the markdown cruft set conceallevel=3 endfunction " enable syntax highlighting for codeblocks WITHIN markdown @@ -151,6 +152,24 @@ autocmd FileType markdown,txt call Prose() " or invoke it manually by writing :Prose command! -nargs=0 Prose call Prose() +" PLUGIN: wiki.vim +let g:wiki_root = '~/projects/vim-notes' +" filetypes to automatically enable the plugin for, seems to take file endings +" rather than vim ft +let g:wiki_filetypes = ['md', 'mkd', 'markdown', 'wiki'] +let g:wiki_link_extension = '.md' +let g:wiki_link_target_type = 'md' + +" PLUGIN: vim-zettel +" gives nice short format of YYMMDDHHMM +let g:zettel_format = "%y%m%d%H%M" +" disable the standard key mappings of the plugin +let g:zettel_default_mappings = 0 +augroup filetype_vimwiki + autocmd! + autocmd FileType markdown xmap z ZettelNewSelectedMap +augroup END + " PLUGIN: vim-pencil " set default wrap mode to hard - TODO test which mode works better for " me, it seems hardmode has trouble with markdown lists (see issue #31)