Open cherryramatisdev opened 1 year ago
Hello.
You can use setlocal tagfunc=v:lua.zettelkasten.tagfunc
so that <C-]>
can take you to a tag. If you want to use completion, then you would need the following options (You can see these in :help zettelkasten.nvim
and the default filetype plugin should set these as well).
setlocal tagfunc=v:lua.zettelkasten.tagfunc
setlocal isfname+=-,:
setlocal iskeyword+=:,-
setlocal suffixesadd+=.md
setlocal keywordprg=:ZkHover
setlocal completefunc=v:lua.zettelkasten.completefunc
This is the only thing that comes to mind when I see those errors. Can you confirm your completefunc
and tagfunc
options?
My completefunc is v:lua.zettelkasten.completefunc and my tagfunc is v:lua.zettelkasten.tagfunc
Disclaimer: My <C-]>
for tagfunc jumping and my <C-x><C-u>
for completefunc is working just fine, my problem is with <C-x><C-]>
and with :tselect
commands
I see. My assumption was that this would work but looks like :tag
and friends don't do completion when no tag file is present. You can still do things like :tag work
and it'll take you to the tag though.
I'm not sure why <C-x><C-]>
is not working. With no tags file, I can use <C-x><C-]>
to get a list of the available tags. I notice that at 0:14, you get a list of the notes. Maybe the completion plugin you are using interfering with something? I don't use a completion plugin so I don't know if it could cause problems.
If you are able to provide a minimum configuration, I can try to see if I can reproduce it here and find a solution if I can.
I don't use a completion plugin either, and maybe I can generate the tags file with some command?
for the minimal config, I can reproduce with this minimal
call plug#begin()
if has('nvim')
Plug 'Furkanzmc/zettelkasten.nvim'
endif
call plug#end()
if has('nvim')
lua require'zettelkasten'.setup { notes_path = "/Users/cherryramatis/Library/Mobile Documents/com~apple~CloudDocs/mybrain" }
endif
With neovim 0.8.3
Thank you for sharing a minimal example. I'll try to look into it in a day or two.
In the mean time, you can take a look at here to generate tags: https://github.com/Furkanzmc/zettelkasten.nvim/wiki#generate-tags-using-universal-tags
Sorry if it's a noob question but I can't use the tags functionality like
:tj
or<C-x><C-]>
because the tags files don't exists as shown below:PS: I can use
<C-]>
on links normally.https://asciinema.org/a/vfLxFzxcPw0woUeSpyUa0FBZX