SublimeText / LaTeXTools

LaTeX plugin for Sublime Text
https://latextools.readthedocs.io/
2.01k stars 365 forks source link

Multibib and No bib files found #1348

Open jankollmitz opened 6 years ago

jankollmitz commented 6 years ago

Hi,

unfortunately the cite auto completion is not working when using the multibib package ("No bib files found!" Error message).

The error is not hard to find: Using multibib creates new commands to insert the bibliography, e.g. \bibliographyA and \bibliographyB. I think the issue is, that the statement in line 243 of latex_cite_completions.py elif c.command in MULTI_BIBCOMMANDS: results in False and the no bib file is loadde for auto completion.

Anyway I solved the issue for now by adding my usual multibib commands to the MULTI_BIBCOMMANDS set, but this is only a temporary solution.

Could you add a better solution to add multibib support?

Thanks and regards, Jan

ig0774 commented 6 years ago

This can be added to the to-do list. Unfortunately, proper support for multibib is a bit of a complex ask. Not just the \bibliographyA commands, but also \citeA need support (which might interfere with other packages and thus need some internal differentiation). Finally, we’d probably need to address the multiple aux file thing (for individual purposes, something that did the equivalent of bibtex *.aux is acceptable, but not as a general solution, since multiple aux files might legitimately exist in the same directory without all being related to the same document).

Probably the best short-term solution is to add support for a setting that contains a list of bib files to use for completions.