micangl / cmp-vimtex

Vimtex source for nvim-cmp.
MIT License
86 stars 5 forks source link

Fix: handle nonexistent `vimtex.root` #10

Closed jdujava closed 10 months ago

jdujava commented 10 months ago

It can happen that vimtex.root is not a proper directory (for example with plugin gitsigns.nvim, the diff window has vimtex.root as something like gitsigns:///dirpath/.git), leading to errors in vimtex#paths#pushd(b:vimtex.root).

It seems that not starting the parser in such buffers works alright, but I'm not sure if it is the right/optimal solution.

micangl commented 10 months ago

Thanks for the PRs. I would never have caught this issues.