Open nilsleh opened 2 years ago
It sounds like maybe your latex process is not calling biblatex/biber.
Try: (setq org-latex-pdf-process (list "latexmk -shell-escape -bibtex -f -pdf %f"))
that seems to work for me.
That indeed does fix it, thank you for the fast reply. I now realize that it was also a suggested option in the manual, but I somehow missed that, apologies.
I am running into the same problem even having this lilne on my initfile:
(setq org-latex-pdf-process (list "latexmk -shell-escape -bibtex -f -pdf %f"))
My buffer test.org
looks like this:
#+STARTUP: overview
#+STARTUP: indent
# #+OPTIONS: toc:2
#+OPTIONS: date:nil
#+LATEX_COMPILER: xelatex
#+LATEX_CLASS: article
#+OPTIONS: broken-links:t
#+TITLE: Title
#+AUTHOR: author1^{*,a}, aauthor2^{b,c}
*SUMMARY
[[cite:&Dirac1994]]
[[cite:&Dirac2000]]
* REFERENCES
[[bibliography:/Users/atomic ness/Documents/Dropbox/BibTex/mypaper.bib]]
[[bibliographystyle:journalZ]]
[[printbibliography:]]
LOG OUTPUT:
LaTeX Warning: Citation `Dirac1991' on page 1 undefined on input line _.
LaTeX Warning: Citation `Dirac2000' on page 1 undefined on input line _.
(./test.bbl)
! Undefined control sequence.
l.46 \printbibliography
?
! Emergency stop.
l.46
End of file on the terminal!
printbibliography requires you to use biblatex. From the look of your org file, you can probably just remove that line. The bibliography link is where the bibliography will go.
It looks like there is a space in the bibliography path. That sometimes causes problems.
You should see if the examples here work: https://github.com/jkitchin/org-ref/tree/master/examples
Thanks. I had a look at several examples.
I am uncertain about what Latex options to set up at the beginning of the org buffer (never used Latex before).
I just have these that I copied from somewhere:
#+LATEX_COMPILER: xelatex
#+LATEX_CLASS: article
#+LATEX: \printbibliography
Not sure if #+LATEX: \printbibliography
is necessary.
Also uncertain about whether it is better to use bibLatex and how to make Emacs use it.
I changed my REFERENCES section like this:
[[bibliography:/Users/atomicness/Documents/Dropbox/BibTex/mypaper.bib]]
[[bibliographystyle:unsrt]]
Got a similar error message:
! Undefined control sequence.
l.30 \printbibliography
?
! Emergency stop.
l.30
End of file on the terminal!
I just want to write my paper in Orgmode and then export to PDF with all the org-ref
functionality.
you can't just copy things from places and hope they work. you are mixing bibtex and biblatex here, which does not work. As I suggested earlier, remove #+LATEX: \printbibliography. And, see if the org-ref examples work for you. If they do slowly adapt one of them to your document, one step at a time, until your document works.
Thanks.
When you mentioned earlier to remove printbibliography
i thought you meant [[printbibliography:]]
, not the latex line.
Now I have removed it and it works.
Thank you for this fantastic work, being able to access, manage and work with citations inside org-mode is incredible. The last step that I cannot figure out how to achieve is exporting the org-mode file to a pdf. I am sure it is simply something that I am not understanding from the manual but I cannot figure out why.
This is my org-mode file.
This is the bibliography:
This is the output from running
M-x org-ref
in the org-mode file:In my emacs init file I have the following:
So to export to pdf I am attempting to run
C-c C-e l o
from test.org. There are no errors being produced when the pdf is created, however, the citation is not formatted and the the bibliography does not show up, i.e:Thank you in advance.