tmalsburg/helm-bibtex

`helm-bibtex-with-local-bibliography` need to work in orgmode also!

Opened this issue · 6 comments

I have a local bib file in the org file directory. I have tried to load this file in the org buffer with this bib using:

#+BIBLIOGRAPHY: file
#+LATEX_HEADER: \bibliography{file}
#+LATEX_HEADER: \addbibresource{file.bib}
\bibliography{file}

None of them worked with helm-bibtex-with-local-bibliography! While when I exported to latex, it worked to load this local bib file even without the addition of any of the previous headers and tags!

Finally, running helm-bibtex-with-local-bibliography inside the bib buffer itself works fine, but I want a way to tie it to org-mode?

We're using reftex-get-bibfile-list to detect local bibliography but it doesn't appear to work on org files. We could create a workaround in helm-bibtex but ideally reftex would support org files as well (incidentally, reftex was originally written by Carsten Dominik who's also the original author or org mode). Would you mind asking the reftex maintainers whether they'd like to support finding bibliographies in org files?

@tmalsburg yes sure, but where can I ask them?

Thanks. The reftex page says that the AucTeX maintainers are responsible. Perhaps they have a mailing list? Not sure.

I found a solution to work with now to avoid reftex problems. By declaring the variable like that in the first line of the org buffer.

# -*- bibtex-completion-bibliography: ("./bibfile.bib"); -*-

you can work with helm-bibtex directly.

That's a neat hack. Didn't think about that. The only downside is that you lose access to your main bibliography while you're in that buffer, but perhaps that's okay. I'll leave this issue open, since it will be a nice addition to be able to use the local bib in org files in addition to the global bib.

I think this issue may have been solved since you can now use org's new #+BIBLIOGRAPHY: keyword to set bibliographies. Do you agree?