On 08/18/2016 06:07 PM, Rich Shepard wrote:
>   It's been a decade since my book, written using LyX, was sent to
> Springer
> as a collection of .tex, .aux, .bib, and other files. I now have a paper
> accepted by a science journal and when I export the file as plain LaTeX
> there is a .tex file but no .bib file.
>
>   The end of the .tex file has:
>
> \bibliographystyle{humannat}
> \bibliography{3_home_rshepard_documents_jabrefdb}
>
>   How do I save a .bib file containing only the references cited in the
> article so I can send that to the editor?

Easiest way: Open your user preferences file in a text editor. (Look at
Help> About LyX if you need to find your user directory. Open the
"preferences" file from that directory.) Now add:

    \format "ltxbib" "tex" "LaTeX (With Bib)" "" "" ""
"document,menu=export" ""

to the Format section, and

    \converter "pdflatex" "ltxbib" "python -tt
$$s/scripts/include_bib.py $$i $$o" "needaux"

to the converter section. When you restart LyX, you should have an
export option "LaTeX (with Bib)". This will actually produce a LaTeX
file with the contents of the bib file replacing the two lines you
mentioned. You can just send that.

We do not include this by default with LyX because it does not work with
sectioned bibliographies.

Richard

Reply via email to