-
Notifications
You must be signed in to change notification settings - Fork 642
Closed
Labels
Description
I've one single wiki configured with an alternate path:
let g:vimwiki_list = [{ 'path': '~/.wiki/', 'syntax': 'markdown', 'ext': '.md'}]
And before commit 057fa39 I could call either :VimwikiMakeDiaryNote
or call vimwiki#diary#make_note(v:count1)
from anywhere. After that, both calls only work when are called from a wiki page, for example:
- Execute vim
- Inside vim execute :VimwikiIndex
- Execute :VimwikiMakeDiaryNote
But if I execute vim and after that :VimwikiMakeDiaryNote it seems that the plugin tries to use another wiki because it creates the "default folder" (~/vimwiki
) and puts inside it the diary wiki.
If I change line 178 in autoload/vimwiki/diary.vim
by adding one to wiki_nr
variable in case a:wnum is zero, everything works fine:
176 function! vimwiki#diary#make_note(wnum, ...)
177 if a:wnum == 0
178 let wiki_nr = vimwiki#vars#get_bufferlocal('wiki_nr') + 1
179 else
180 let wiki_nr = a:wnum - 1
181 endif