dotfiles/nvim.configlink/settings/vimwiki.vim

31 lines
839 B
VimL
Raw Normal View History

2021-04-12 00:49:42 +00:00
" VimWiki
"--------
let g:vimwiki_list = [
\ {
\ 'path': $NOTES_PATH,
\ 'syntax': 'markdown',
\ 'index': 'home',
\ 'ext': '.md'
\ }
\ ]
let g:vimwiki_key_mappings =
\ {
\ 'all_maps': 1,
\ 'mouse': 1,
\ }
2021-04-22 13:34:57 +00:00
let g:vimwiki_auto_chdir = 1 " Set local dir to Wiki when open
let g:vimwiki_create_link = 0 " Don't automatically create new links
let g:vimwiki_listsyms = ' x' " Set checkbox symbol progression
let g:vimwiki_table_mappings = 0 " VimWiki table keybinds interfere with tab completion
2021-04-28 12:58:14 +00:00
" Insert from command-mode into buffer
function! PInsert(item)
let @z=a:item
norm "zpx
endfunction
command! AddTag call fzf#run({'source': 'rg "#[\w/]+[ |\$]" -o --no-filename --no-line-number | sort | uniq', 'sink': function('PInsert')})
autocmd FileType markdown inoremap ;tt <Esc>:AddTag<CR>