let s:search_dir = ' ~/diaries ~/journals ~/notes ' command! -bang FzfNoteFiles \ call fzf#run(fzf#wrap(fzf#vim#with_preview({ \ 'source': 'fd --type f . ' . s:search_dir, \ 'sink': 'edit', \ }), 0)) command! -bang -nargs=* FzfNoteRg \ call fzf#vim#grep( \ 'rg --column --line-number --no-heading --color=always --smart-case -e ' \ . shellescape() . s:search_dir, 1, \ fzf#vim#with_preview(), 0) nnoremap ww :edit ~/journals/index.md nnoremap wn :edit ~/journals/gtd.md nnoremap wf :FzfNoteFiles nnoremap wr :FzfNoteRg