Exploring BibTeX: quick and dirty customization

Hi everybody, I’m working hard on LaTeX, XeTeX and BibTeX in the last weeks, as I have to conclude a couple of research books I am writing. I always have got a problem with bibliography in non-English books, when you have a multiauthored entry like the following one:

@Book{Brown1987,
author = "Brown, Penelope and Levinson, Stephen C.",
title = "Politeness: Some universals in language usage",
publisher = cup,
address = cup:addr,
year = "1987"}

The strings cup and cup:addr are shortcuts for most used names, such as Cambridge University Press for me. The problem is that in many bibliography styles, such as APA, which I am using for a book written in Italian, the output is something like this:

(Brown and Levinson, 1987).

This sounds a bit odd to me, as I’m not writing in English this time — sometimes it does happen that your ideas are still interesting at the periphery of the Research Empire, e.g., in Italy. Well, I do not want to create a BibTeX style for my own only for this purpose. In fact, if you try to do this, from the command line:
$ latex makebst
you will prompted a long series of questions in order to get your custom myBibTeXstyle.bst file, which contains all information for your BibTeX style. Let’s recall how to insert bibliography into your main.tex file. Basically, you should write this couple of lines

\bibliographystyle{/path/to/myBibTeXstyle.bst}
\bibliography{/path/to/myBibliography.bib}

Then, remember to compile bibtex apart in the standard way before latex or xelatex compilation:

$ bibtex main
$ xelatex main.tex

What does the bibtex compilation do? It writes a main.bbl file, that will be included in your tex. This is an ASCII file, so you can edit it easily. Looking to the correspondent entry of the myBibliography.bib file you’ll find a TeX entry like this:

\bibitem[Brown and Levinson, 1987]{Brown1987}
Brown, P. and Levinson, S.~C. (1987).
\newblock {\em Politeness: Some universals in language usage}.
\newblock Cambridge University Press, Cambridge.

It is easy to rewrite it as the following:

\bibitem[Brown \& Levinson, 1987]{Brown1987}
Brown, P. \& Levinson, S.~C. (1987).
\newblock {\em Politeness: Some universals in language usage}.
\newblock Cambridge University Press, Cambridge.

This solves the problem. Of course, it is a quick and dirty customization. I mean, it is useful iff you do not need to modify your .bib file. Of course, if you compile BibTex again, your edits will be lost, as the .bbl file will be rewritten by the BibTeX engine. Anyway, it works, at least for my needs.

One thought on “Exploring BibTeX: quick and dirty customization

  1. Pingback: Exploring BibTeX and LaTeX: the elegant way for ‘and’ and the floats « Federico Gobbo

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s