-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathchapter-makingbib.tex
More file actions
102 lines (91 loc) · 3.23 KB
/
chapter-makingbib.tex
File metadata and controls
102 lines (91 loc) · 3.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
\chapter{Making the Bibliography with BiB\TeX{}}\label{c:bib}
\index{Making the Bibliography with BiBTeX%
@\emph{Making the Bibliography with BiB\TeX{}}}%
BiB\TeX{}
\index{BiBTeX@BiB\TeX{}}%
allows one to generate automatically the bibliography
from a database of bibliographic
items. You need to do the following:
\begin{enumerate}
\item Create the bibliographic database,
\index{bibliographic database}%
which is a file whose name ends in \texttt{.bib}.
\index{.bib@\texttt{.bib}}%
Let us call it \texttt{diss.bib}. Entries in this file are like this:
\begin{verbatim}
@BOOK{knuth:tb,
author = "Donald K. Knuth",
title = "The \TeXbook",
publisher = "Addison-Wesley",
year = "1984",
}
@TECHREPORT{poorten:sp,
author = "Alf~J.~van der Poorten",
title = "Some problems of recurrent interest",
institution = "School of Mathematics and Physics,
Macquarie University",
address = "North Ryde, Australia 2113",
number = "81-0037",
month = "August",
year = "1981",
}
@ARTICLE{erdos:oap,
author = "Paul Erd{\"o}s and Paul Turan",
title = "On a problem in the theory of uniform
distribution, {I}",
journal = "Indag. Math.",
volume = "10",
year = "1948",
pages = "370--378",
}
\end{verbatim}
\item Include a \cn{bibliographystyle}
\index{commands!bibliographystyle@\cn{bibliographystyle}}%
command in your \LaTeX{} file, say
\cn{bibliographystyle\{plain\}}
and a \cn{bibliography}
\index{commands!bibliography@\cn{bibliography}}%
command to load the bibliography,
in this case \cn{bibliography\{diss\}}, at the point of your
document where the bibliography should be inserted.
The document at this point will look like this:
\begin{verbatim}
\bibliographystyle{plain}
\bibliography{diss}
\end{verbatim}
\item Run \LaTeX{} on your main file, say \texttt{foo.tex}:
\texttt{latex foo}. This generates an auxiliary file
\texttt{foo.aux} with a list of \cn{cite}
\index{commands!cite@\cn{cite}}
references.
\item Run BiB\TeX{} on your file: \texttt{bibtex foo}.
BiB\TeX{} reads the auxiliary file, looks up the
bibliographic database (\texttt{diss.bib}),
and writes a \texttt{.bbl}
\index{.bbl@\texttt{.bbl}}%
file with the bibliographic information formated according to
the bibliographic style file (\texttt{.bst},
\index{.bst@\texttt{.bst}}%
say \texttt{plain.bst})
\index{plain.bst@\texttt{plain.bst}}%
specified. Messages about resources used and error messages
are written to a \texttt{.blg}
\index{.blg@\texttt{.blg}}%
file (in the case of this template, disstemplate.blg).
\item Run \LaTeX{} again: \texttt{latex foo}, which now
reads the \texttt{.bbl}
\index{.bbl@\texttt{.bbl}}%
reference file.
\item Run \LaTeX{} for a third time: \texttt{latex foo},
resolving all references.
\end{enumerate}
This includes all bibliographic items that have been cited
in the document with a \cn{cite}
\index{commands!cite@\cn{cite}}%
command. In order to include non cited items in the bibliography,
use the command \cn{nocite}. For example, \cn{nocite\{knuth:tb\}}
anywhere in the document (after \cn{begin\{document\}}) includes
in the bibliography the item with label \texttt{knuth:tb}.
In order to include \emph{all} items of the bibliographic
database, use the command \cn{nocite\{*\}}.
\index{commands!nocite@\cn{nocite}}%