BSD 4_4_Lite2 development
[unix-history] / usr / share / man / cat1 / refer.0
REFER(1) BSD Reference Manual REFER(1)
N\bNA\bAM\bME\bE
refer - preprocess bibliographic references for groff
S\bSY\bYN\bNO\bOP\bPS\bSI\bIS\bS
r\bre\bef\bfe\ber\br [ -\b-b\bbe\ben\bnv\bvC\bCP\bPR\bRS\bS ] [ -\b-a\ba_\bn ] [ -\b-c\bc_\bf_\bi_\be_\bl_\bd_\bs ] [ -\b-f\bf_\bn ]
[ -\b-i\bi_\bf_\bi_\be_\bl_\bd_\bs ] [ -\b-k\bk_\bf_\bi_\be_\bl_\bd ] [ -\b-l\bl_\bm_\b,_\bn ] [ -\b-p\bp_\bf_\bi_\bl_\be_\bn_\ba_\bm_\be ]
[ -\b-s\bs_\bf_\bi_\be_\bl_\bd_\bs ] [ -\b-t\bt_\bn ] [ -\b-B\bB_\bf_\bi_\be_\bl_\bd_\b._\bm_\ba_\bc_\br_\bo ]
[ _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be... ]
D\bDE\bES\bSC\bCR\bRI\bIP\bPT\bTI\bIO\bON\bN
This file documents the GNU version of r\bre\bef\bfe\ber\br, which is
part of the groff document formatting system. r\bre\bef\bfe\ber\br
copies the contents of _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be... to the standard out-
put, except that lines between .\b.[\b[ and .\b.]\b] are interpreted
as citations, and lines between .\b.R\bR1\b1 and .\b.R\bR2\b2 are inter-
preted as commands about how citations are to be pro-
cessed.
Each citation specifies a reference. The citation can
specify a reference that is contained in a bibliographic
database by giving a set of keywords that only that refer-
ence contains. Alternatively it can specify a reference
by supplying a database record in the citation. A combi-
nation of these alternatives is also possible.
For each citation, r\bre\bef\bfe\ber\br can produce a mark in the text.
This mark consists of some label which can be separated
from the text and from other labels in various ways. For
each reference it also outputs g\bgr\bro\bof\bff\bf commands that can be
used by a macro package to produce a formatted reference
for each citation. The output of r\bre\bef\bfe\ber\br must therefore be
processed using a suitable macro package. The -\b-m\bms\bs and -\b-m\bme\be
macros are both suitable. The commands to format a cita-
tion's reference can be output immediately after the cita-
tion, or the references may be accumulated, and the com-
mands output at some later point. If the references are
accumulated, then multiple citations of the same reference
will produce a single formatted reference.
The interpretation of lines between .\b.R\bR1\b1 and .\b.R\bR2\b2 as com-
mands is a new feature of GNU refer. Documents making use
of this feature can still be processed by Unix refer just
by adding the lines
.\b.d\bde\be R\bR1\b1
.\b.i\big\bg R\bR2\b2
.\b..\b.
to the beginning of the document. This will cause t\btr\bro\bof\bff\bf
to ignore everything between .\b.R\bR1\b1 and .\b.R\bR2\b2. The effect of
some commands can also be achieved by options. These
options are supported mainly for compatibility with Unix
Groff Version 1.08 30 December 1993 1
REFER(1) BSD Reference Manual REFER(1)
refer. It is usually more convenient to use commands.
r\bre\bef\bfe\ber\br generates .\b.l\blf\bf lines so that filenames and line num-
bers in messages produced by commands that read r\bre\bef\bfe\ber\br out-
put will be correct; it also interprets lines beginning
with .\b.l\blf\bf so that filenames and line numbers in the mes-
sages and .\b.l\blf\bf lines that it produces will be accurate even
if the input has been preprocessed by a command such as
s\bso\boe\bel\bli\bim\bm(1).
O\bOP\bPT\bTI\bIO\bON\bNS\bS
Most options are equivalent to commands (for a description
of these commands see the C\bCo\bom\bmm\bma\ban\bnd\bds\bs subsection):
-\b-b\bb n\bno\bo-\b-l\bla\bab\bbe\bel\bl-\b-i\bin\bn-\b-t\bte\bex\bxt\bt;\b; n\bno\bo-\b-l\bla\bab\bbe\bel\bl-\b-i\bin\bn-\b-r\bre\bef\bfe\ber\bre\ben\bnc\bce\be
-\b-e\be a\bac\bcc\bcu\bum\bmu\bul\bla\bat\bte\be
-\b-n\bn n\bno\bo-\b-d\bde\bef\bfa\bau\bul\blt\bt-\b-d\bda\bat\bta\bab\bba\bas\bse\be
-\b-C\bC c\bco\bom\bmp\bpa\bat\bti\bib\bbl\ble\be
-\b-P\bP m\bmo\bov\bve\be-\b-p\bpu\bun\bnt\btu\bua\bat\bti\bio\bon\bn
-\b-S\bS l\bla\bab\bbe\bel\bl "\b"(\b(A\bA.\b.n\bn|\b|Q\bQ)\b) '\b',\b, '\b' (\b(D\bD.\b.y\by|\b|D\bD)\b)"\b";\b; b\bbr\bra\bac\bck\bke\bet\bt-\b-l\bla\bab\bbe\bel\bl "\b" (\b("\b" )\b)
"\b";\b; "\b"
-\b-a\ba_\bn r\bre\bev\bve\ber\brs\bse\be A\bA_\bn
-\b-c\bc_\bf_\bi_\be_\bl_\bd_\bs
c\bca\bap\bpi\bit\bta\bal\bli\biz\bze\be _\bf_\bi_\be_\bl_\bd_\bs
-\b-f\bf_\bn l\bla\bab\bbe\bel\bl %\b%_\bn
-\b-i\bi_\bf_\bi_\be_\bl_\bd_\bs
s\bse\bea\bar\brc\bch\bh-\b-i\big\bgn\bno\bor\bre\be _\bf_\bi_\be_\bl_\bd_\bs
-\b-k\bk l\bla\bab\bbe\bel\bl L\bL~\b~%\b%a\ba
-\b-k\bk_\bf_\bi_\be_\bl_\bd
l\bla\bab\bbe\bel\bl _\bf_\bi_\be_\bl_\bd~\b~%\b%a\ba
-\b-l\bl l\bla\bab\bbe\bel\bl A\bA.\b.n\bnD\bD.\b.y\by%\b%a\ba
-\b-l\bl_\bm l\bla\bab\bbe\bel\bl A\bA.\b.n\bn+\b+_\bmD\bD.\b.y\by%\b%a\ba
-\b-l\bl,\b,_\bn l\bla\bab\bbe\bel\bl A\bA.\b.n\bnD\bD.\b.y\by-\b-_\bn%\b%a\ba
-\b-l\bl_\bm,\b,_\bn l\bla\bab\bbe\bel\bl A\bA.\b.n\bn+\b+_\bmD\bD.\b.y\by-\b-_\bn%\b%a\ba
Groff Version 1.08 30 December 1993 2
REFER(1) BSD Reference Manual REFER(1)
-\b-p\bp_\bf_\bi_\bl_\be_\bn_\ba_\bm_\be
d\bda\bat\bta\bab\bba\bas\bse\be _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be
-\b-s\bs_\bs_\bp_\be_\bc s\bso\bor\brt\bt _\bs_\bp_\be_\bc
-\b-t\bt_\bn s\bse\bea\bar\brc\bch\bh-\b-t\btr\bru\bun\bnc\bca\bat\bte\be _\bn
These options are equivalent to the following commands
with the addition that the filenames specified on the com-
mand line are processed as if they were arguments to the
b\bbi\bib\bbl\bli\bio\bog\bgr\bra\bap\bph\bhy\by command instead of in the normal way:
-\b-B\bB a\ban\bnn\bno\bot\bta\bat\bte\be X\bX A\bAP\bP;\b; n\bno\bo-\b-l\bla\bab\bbe\bel\bl-\b-i\bin\bn-\b-r\bre\bef\bfe\ber\bre\ben\bnc\bce\be
-\b-B\bB_\bf_\bi_\be_\bl_\bd.\b._\bm_\ba_\bc_\br_\bo
a\ban\bnn\bno\bot\bta\bat\bte\be _\bf_\bi_\be_\bl_\bd _\bm_\ba_\bc_\br_\bo;\b; n\bno\bo-\b-l\bla\bab\bbe\bel\bl-\b-i\bin\bn-\b-r\bre\bef\bfe\ber\bre\ben\bnc\bce\be
The following options have no equivalent commands:
-\b-v\bv Print the version number.
-\b-R\bR Don't recognize lines beginning with .\b.R\bR1\b1/.\b.R\bR2\b2.
U\bUS\bSA\bAG\bGE\bE
B\bBi\bib\bbl\bli\bio\bog\bgr\bra\bap\bph\bhi\bic\bc d\bda\bat\bta\bab\bba\bas\bse\bes\bs
The bibliographic database is a text file consisting of
records separated by one or more blank lines. Within each
record fields start with a %\b% at the beginning of a line.
Each field has a one character name that immediately fol-
lows the %\b%. It is best to use only upper and lower case
letters for the names of fields. The name of the field
should be followed by exactly one space, and then by the
contents of the field. Empty fields are ignored. The
conventional meaning of each field is as follows:
A\bA The name of an author. If the name contains a
title such as J\bJr\br.\b. at the end, it should be sepa-
rated from the last name by a comma. There can be
multiple occurences of the A\bA field. The order is
siginificant. It is a good idea always to supply
an A\bA field or a Q\bQ field.
B\bB For an article that is part of a book, the title of
the book
C\bC The place (city) of publication.
D\bD The date of publication. The year should be speci-
fied in full. If the month is specified, the name
rather than the number of the month should be used,
but only the first three letters are required. It
Groff Version 1.08 30 December 1993 3
REFER(1) BSD Reference Manual REFER(1)
is a good idea always to supply a D\bD field; if the
date is unknown, a value such as i\bin\bn p\bpr\bre\bes\bss\bs or
u\bun\bnk\bkn\bno\bow\bwn\bn can be used.
E\bE For an article that is part of a book, the name of
an editor of the book. Where the work has editors
and no authors, the names of the editors should be
given as A\bA fields and ,\b, (\b(e\bed\bd)\b) or ,\b, (\b(e\bed\bds\bs)\b) should be
appended to the last author.
G\bG US Government ordering number.
I\bI The publisher (issuer).
J\bJ For an article in a journal, the name of the jour-
nal.
K\bK Keywords to be used for searching.
L\bL Label.
N\bN Journal issue number.
O\bO Other information. This is usually printed at the
end of the reference.
P\bP Page number. A range of pages can be specified as
_\bm-\b-_\bn.
Q\bQ The name of the author, if the author is not a per-
son. This will only be used if there are no A\bA
fields. There can only be one Q\bQ field.
R\bR Technical report number.
S\bS Series name.
T\bT Title. For an article in a book or journal, this
should be the title of the article.
V\bV Volume number of the journal or book.
X\bX Annotation.
For all fields except A\bA and E\bE, if there is more than one
occurence of a particular field in a record, only the last
such field will be used.
If accent strings are used, they should follow the
charater to be accented. This means that the A\bAM\bM macro
must be used with the -\b-m\bms\bs macros. Accent strings should
Groff Version 1.08 30 December 1993 4
REFER(1) BSD Reference Manual REFER(1)
not be quoted: use one \\b\ rather than two.
C\bCi\bit\bta\bat\bti\bio\bon\bns\bs
The format of a citation is
.\b.[\b[_\bo_\bp_\be_\bn_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt
_\bf_\bl_\ba_\bg_\bs _\bk_\be_\by_\bw_\bo_\br_\bd_\bs
_\bf_\bi_\be_\bl_\bd_\bs
.\b.]\b]_\bc_\bl_\bo_\bs_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt
The _\bo_\bp_\be_\bn_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt, _\bc_\bl_\bo_\bs_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt and _\bf_\bl_\ba_\bg_\bs components are
optional. Only one of the _\bk_\be_\by_\bw_\bo_\br_\bd_\bs and _\bf_\bi_\be_\bl_\bd_\bs components
need be specified.
The _\bk_\be_\by_\bw_\bo_\br_\bd_\bs component says to search the bibliographic
databases for a reference that contains all the words in
_\bk_\be_\by_\bw_\bo_\br_\bd_\bs. It is an error if more than one reference if
found.
The _\bf_\bi_\be_\bl_\bd_\bs components specifies additional fields to
replace or supplement those specified in the reference.
When references are being accumulated and the _\bk_\be_\by_\bw_\bo_\br_\bd_\bs
component is non-empty, then additional fields should be
specified only on the first occasion that a particular
reference is cited, and will apply to all citations of
that reference.
The _\bo_\bp_\be_\bn_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt and _\bc_\bl_\bo_\bs_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt component specifies
strings to be used to bracket the label instead of the
strings specified in the b\bbr\bra\bac\bck\bke\bet\bt-\b-l\bla\bab\bbe\bel\bl command. If either
of these components is non-empty, the strings specified in
the b\bbr\bra\bac\bck\bke\bet\bt-\b-l\bla\bab\bbe\bel\bl command will not be used; this behaviour
can be altered using the [\b[ and ]\b] flags. Note that leading
and trailing spaces are significant for these components.
The _\bf_\bl_\ba_\bg_\bs component is a list of non-alphanumeric charac-
ters each of which modifies the treatment of this particu-
lar citation. Unix refer will treat these flags as part
of the keywords and so will ignore them since they are
non-alphanumeric. The following flags are currently rec-
ognized:
#\b# This says to use the label specified by the s\bsh\bho\bor\brt\bt-\b-
l\bla\bab\bbe\bel\bl command, instead of that specified by the
l\bla\bab\bbe\bel\bl command. If no short label has been speci-
fied, the normal label will be used. Typically the
short label is used with author-date labels and
consists of only the date and possibly a disam-
biguating letter; the #\b# is supposed to be sugges-
tive of a numeric type of label.
[\b[ Precede _\bo_\bp_\be_\bn_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt with the first string
Groff Version 1.08 30 December 1993 5
REFER(1) BSD Reference Manual REFER(1)
specified in the b\bbr\bra\bac\bck\bke\bet\bt-\b-l\bla\bab\bbe\bel\bl command.
]\b] Follow _\bc_\bl_\bo_\bs_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt with the second string speci-
fied in the b\bbr\bra\bac\bck\bke\bet\bt-\b-l\bla\bab\bbe\bel\bl command.
One advantages of using the [\b[ and ]\b] flags rather than
including the brackets in _\bo_\bp_\be_\bn_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt and _\bc_\bl_\bo_\bs_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt is
that you can change the style of bracket used in the docu-
ment just by changing the b\bbr\bra\bac\bck\bke\bet\bt-\b-l\bla\bab\bbe\bel\bl command. Another
advantage is that sorting and merging of citations will
not necessarily be inhibited if the flags are used.
If a label is to be inserted into the text, it will be
attached to the line preceding the .\b.[\b[ line. If there is
no such line, then an extra line will be inserted before
the .\b.[\b[ line and a warning will be given.
There is no special notation for making a citation to mul-
tiple references. Just use a sequence of citations, one
for each reference. Don't put anything between the cita-
tions. The labels for all the citations will be attached
to the line preceding the first citation. The labels may
also be sorted or merged. See the description of the <\b<>\b>
label expression, and of the s\bso\bor\brt\bt-\b-a\bad\bdj\bja\bac\bce\ben\bnt\bt-\b-l\bla\bab\bbe\bel\bls\bs and
a\bab\bbb\bbr\bre\bev\bvi\bia\bat\bte\be-\b-l\bla\bab\bbe\bel\bl-\b-r\bra\ban\bng\bge\bes\bs command. A label will not be
merged if its citation has a non-empty _\bo_\bp_\be_\bn_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt or
_\bc_\bl_\bo_\bs_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt. However, the labels for a citation using
the ]\b] flag and without any _\bc_\bl_\bo_\bs_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt immediately fol-
lowed by a citation using the [\b[ flag and without any _\bo_\bp_\be_\bn_\b-
_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt may be sorted and merged even though the first
citation's _\bo_\bp_\be_\bn_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt or the second citation's _\bc_\bl_\bo_\bs_\bi_\bn_\bg_\b-
_\bt_\be_\bx_\bt is non-empty. (If you wish to prevent this just make
the first citation's _\bc_\bl_\bo_\bs_\bi_\bn_\bg_\b-_\bt_\be_\bx_\bt \\b\&\b&.)
C\bCo\bom\bmm\bma\ban\bnd\bds\bs
Commands are contained between lines starting with .\b.R\bR1\b1 and
.\b.R\bR2\b2. Recognition of these lines can be prevented by the
-\b-R\bR option. When a .\b.R\bR1\b1 line is recognized any accumulated
references are flushed out. Neither .\b.R\bR1\b1 nor .\b.R\bR2\b2 lines,
nor anything between them is output.
Commands are separated by newlines or ;\b;s. #\b# introduces a
comment that extends to the end of the line (but does not
conceal the newline). Each command is broken up into
words. Words are separated by spaces or tabs. A word
that begins with "\b" extends to the next "\b" that is not fol-
lowed by another "\b". If there is no such "\b" the word
extends to the end of the line. Pairs of "\b" in a word
beginning with "\b" collapse to a single "\b". Neither #\b# nor ;\b;
are recognized inside "\b"s. A line can be continued by end-
ing it with \\b\; this works everywhere except after a #\b#.
Groff Version 1.08 30 December 1993 6
REFER(1) BSD Reference Manual REFER(1)
Each command _\bn_\ba_\bm_\be that is marked with * has an associated
negative command n\bno\bo-\b-_\bn_\ba_\bm_\be that undoes the effect of _\bn_\ba_\bm_\be.
For example, the n\bno\bo-\b-s\bso\bor\brt\bt command specifies that references
should not be sorted. The negative commands take no argu-
ments.
In the following description each argument must be a sin-
gle word; _\bf_\bi_\be_\bl_\bd is used for a single upper or lower case
letter naming a field; _\bf_\bi_\be_\bl_\bd_\bs is used for a sequence of
such letters; _\bm and _\bn are used for a non-negative numbers;
_\bs_\bt_\br_\bi_\bn_\bg is used for an arbitrary string; _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be is used
for the name of a file.
a\bab\bbb\bbr\bre\bev\bvi\bia\bat\bte\be* _\bf_\bi_\be_\bl_\bd_\bs _\bs_\bt_\br_\bi_\bn_\bg_\b1 _\bs_\bt_\br_\bi_\bn_\bg_\b2 _\bs_\bt_\br_\bi_\bn_\bg_\b3 _\bs_\bt_\br_\bi_\bn_\bg_\b4
Abbreviate the first names of
_\bf_\bi_\be_\bl_\bd_\bs. An initial letter will
be separated from another initial
letter by _\bs_\bt_\br_\bi_\bn_\bg_\b1, from the last
name by _\bs_\bt_\br_\bi_\bn_\bg_\b2, and from any-
thing else (such as a v\bvo\bon\bn or d\bde\be)
by _\bs_\bt_\br_\bi_\bn_\bg_\b3. These default to a
period followed by a space. In a
hyphenated first name, the ini-
tial of the first part of the
name will be separated from the
hyphen by _\bs_\bt_\br_\bi_\bn_\bg_\b4; this defaults
to a period. No attempt is made
to handle any ambiguities that
might result from abbreviation.
Names are abbreviated before
sorting and before label con-
struction.
a\bab\bbb\bbr\bre\bev\bvi\bia\bat\bte\be-\b-l\bla\bab\bbe\bel\bl-\b-r\bra\ban\bng\bge\bes\bs* _\bs_\bt_\br_\bi_\bn_\bg
Three or more adjacent labels
that refer to consecutive refer-
ences will be abbreviated to a
label consisting of the first
label, followed by _\bs_\bt_\br_\bi_\bn_\bg fol-
lowed by the last label. This is
mainly useful with numeric
labels. If _\bs_\bt_\br_\bi_\bn_\bg is omitted it
defaults to -\b-.
a\bac\bcc\bcu\bum\bmu\bul\bla\bat\bte\be* Accumulate references instead of
writing out each reference as it
is encountered. Accumulated ref-
erences will be written out when-
ever a reference of the form
.\b.[\b[
Groff Version 1.08 30 December 1993 7
REFER(1) BSD Reference Manual REFER(1)
$\b$L\bLI\bIS\bST\bT$\b$
.\b.]\b]
is encountered, after all input
files hve been processed, and
whenever .\b.R\bR1\b1 line is recognized.
a\ban\bnn\bno\bot\bta\bat\bte\be* _\bf_\bi_\be_\bl_\bd _\bs_\bt_\br_\bi_\bn_\bg _\bf_\bi_\be_\bl_\bd is an annotation; print it
at the end of the reference as a
paragraph preceded by the line
.\b._\bs_\bt_\br_\bi_\bn_\bg
If _\bm_\ba_\bc_\br_\bo is omitted it will
default to A\bAP\bP; if _\bf_\bi_\be_\bl_\bd is also
omitted it will default to X\bX.
Only one field can be an annota-
tion.
a\bar\brt\bti\bic\bcl\ble\bes\bs _\bs_\bt_\br_\bi_\bn_\bg... _\bs_\bt_\br_\bi_\bn_\bg... are definite or indef-
inite articles, and should be
ignored at the beginning of T\bT
fields when sorting. Initially,
t\bth\bhe\be, a\ba and a\ban\bn are recognized as
articles.
b\bbi\bib\bbl\bli\bio\bog\bgr\bra\bap\bph\bhy\by _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be... Write out all the references con-
tained in the bibliographic
databases _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be...
b\bbr\bra\bac\bck\bke\bet\bt-\b-l\bla\bab\bbe\bel\bl _\bs_\bt_\br_\bi_\bn_\bg_\b1 _\bs_\bt_\br_\bi_\bn_\bg_\b2 _\bs_\bt_\br_\bi_\bn_\bg_\b3
In the text, bracket each label
with _\bs_\bt_\br_\bi_\bn_\bg_\b1 and _\bs_\bt_\br_\bi_\bn_\bg_\b2. An
occurrence of _\bs_\bt_\br_\bi_\bn_\bg_\b2 immediately
followed by _\bs_\bt_\br_\bi_\bn_\bg_\b1 will be
turned into _\bs_\bt_\br_\bi_\bn_\bg_\b3. The default
behaviour is
b\bbr\bra\bac\bck\bke\bet\bt-\b-l\bla\bab\bbe\bel\bl \\b\*\b*(\b([\b[.\b. \\b\*\b*(\b(.\b.]\b]
"\b",\b, "\b"
c\bca\bap\bpi\bit\bta\bal\bli\biz\bze\be _\bf_\bi_\be_\bl_\bd_\bs Convert _\bf_\bi_\be_\bl_\bd_\bs to caps and small
caps.
c\bco\bom\bmp\bpa\bat\bti\bib\bbl\ble\be* Recognize .\b.R\bR1\b1 and .\b.R\bR2\b2 even when
followed by a character other
than space or newline.
d\bda\bat\bta\bab\bba\bas\bse\be _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be... Search the bibliographic
databases _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be... For each
_\bf_\bi_\bl_\be_\bn_\ba_\bm_\be if an index _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be.\b.i\bi
Groff Version 1.08 30 December 1993 8
REFER(1) BSD Reference Manual REFER(1)
created by i\bin\bnd\bdx\bxb\bbi\bib\bb(1) exists,
then it will be searched instead;
each index can cover multiple
databases.
d\bda\bat\bte\be-\b-a\bas\bs-\b-l\bla\bab\bbe\bel\bl* _\bs_\bt_\br_\bi_\bn_\bg _\bs_\bt_\br_\bi_\bn_\bg is a label expression that
specifies a string with which to
replace the D\bD field after con-
structing the label. See the
L\bLa\bab\bbe\bel\bl e\bex\bxp\bpr\bre\bes\bss\bsi\bio\bon\bns\bs subsection for
a description of label expres-
sions. This command is useful if
you do not want explicit labels
in the reference list, but
instead want to handle any neces-
sary disambiguation by qualifying
the date in some way. The label
used in the text would typically
be some combination of the author
and date. In most cases you
should also use the n\bno\bo-\b-l\bla\bab\bbe\bel\bl-\b-i\bin\bn-\b-
r\bre\bef\bfe\ber\bre\ben\bnc\bce\be command. For example,
d\bda\bat\bte\be-\b-a\bas\bs-\b-l\bla\bab\bbe\bel\bl
D\bD.\b.+\b+y\byD\bD.\b.y\by%\b%a\ba*\b*D\bD.\b.-\b-y\by
would attach a disambiguating
letter to the year part of the D\bD
field in the reference.
d\bde\bef\bfa\bau\bul\blt\bt-\b-d\bda\bat\bta\bab\bba\bas\bse\be* The default database should be
searched. This is the default
behaviour, so the negative ver-
sion of this command is more use-
ful. refer determines whether
the default database should be
searched on the first occasion
that it needs to do a search.
Thus a n\bno\bo-\b-d\bde\bef\bfa\bau\bul\blt\bt-\b-d\bda\bat\bta\bab\bba\bas\bse\be com-
mand must be given before then,
in order to be effective.
d\bdi\bis\bsc\bca\bar\brd\bd* _\bf_\bi_\be_\bl_\bd_\bs When the reference is read,
_\bf_\bi_\be_\bl_\bd_\bs should be discarded; no
string definitions for _\bf_\bi_\be_\bl_\bd_\bs
will be output. Initially,
_\bf_\bi_\be_\bl_\bd_\bs are X\bXY\bYZ\bZ.
e\bet\bt-\b-a\bal\bl* _\bs_\bt_\br_\bi_\bn_\bg _\bm _\bn Control use of e\bet\bt a\bal\bl in the eval-
uation of @\b@ expressions in label
expressions. If the number of
Groff Version 1.08 30 December 1993 9
REFER(1) BSD Reference Manual REFER(1)
authors needed to make the author
sequence unambiguous is _\bu and the
total number of authors is _\bt then
the last _\bt-_\bu authors will be
replaced by _\bs_\bt_\br_\bi_\bn_\bg provided that
_\bt-_\bu is not less than _\bm and _\bt is
not less than _\bn. The default
behaviour is
e\bet\bt-\b-a\bal\bl "\b" e\bet\bt a\bal\bl"\b" 2\b2 3\b3
i\bin\bnc\bcl\blu\bud\bde\be _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be Include _\bf_\bi_\bl_\be_\bn_\ba_\bm_\be and interpret
the contents as commands.
j\bjo\boi\bin\bn-\b-a\bau\but\bth\bho\bor\brs\bs _\bs_\bt_\br_\bi_\bn_\bg_\b1 _\bs_\bt_\br_\bi_\bn_\bg_\b2 _\bs_\bt_\br_\bi_\bn_\bg_\b3
This says how authors should be
joined together. When there are
exactly two authors, they will be
joined with _\bs_\bt_\br_\bi_\bn_\bg_\b1. When there
are more than two authors, all
but the last two will be joined
with _\bs_\bt_\br_\bi_\bn_\bg_\b2, and the last two
authors will be joined with
_\bs_\bt_\br_\bi_\bn_\bg_\b3. If _\bs_\bt_\br_\bi_\bn_\bg_\b3 is omitted,
it will default to _\bs_\bt_\br_\bi_\bn_\bg_\b1; if
_\bs_\bt_\br_\bi_\bn_\bg_\b2 is also omitted it will
also default to _\bs_\bt_\br_\bi_\bn_\bg_\b1. For
example,
j\bjo\boi\bin\bn-\b-a\bau\but\bth\bho\bor\brs\bs "\b" a\ban\bnd\bd "\b" "\b",\b, "\b"
"\b",\b, a\ban\bnd\bd "\b"
will restore the default method
for joining authors.
l\bla\bab\bbe\bel\bl-\b-i\bin\bn-\b-r\bre\bef\bfe\ber\bre\ben\bnc\bce\be* When outputting the reference,
define the string [\b[F\bF to be the
reference's label. This is the
default behaviour; so the nega-
tive version of this command is
more useful.
l\bla\bab\bbe\bel\bl-\b-i\bin\bn-\b-t\bte\bex\bxt\bt* For each reference output a label
in the text. The label will be
separated from the surrounding
text as described in the b\bbr\bra\bac\bck\bke\bet\bt-\b-
l\bla\bab\bbe\bel\bl command. This is the
default behaviour; so the nega-
tive version of this command is
more useful.
Groff Version 1.08 30 December 1993 10
REFER(1) BSD Reference Manual REFER(1)
l\bla\bab\bbe\bel\bl _\bs_\bt_\br_\bi_\bn_\bg _\bs_\bt_\br_\bi_\bn_\bg is a label expression
describing how to label each ref-
erence.
s\bse\bep\bpa\bar\bra\bat\bte\be-\b-l\bla\bab\bbe\bel\bl-\b-s\bse\bec\bco\bon\bnd\bd-\b-p\bpa\bar\brt\bts\bs _\bs_\bt_\br_\bi_\bn_\bg
When merging two-part labels,
separate the second part of the
second label from the first label
with _\bs_\bt_\br_\bi_\bn_\bg. See the description
of the <\b<>\b> label expression.
m\bmo\bov\bve\be-\b-p\bpu\bun\bnc\bct\btu\bua\bat\bti\bio\bon\bn* In the text, move any punctuation
at the end of line past the
label. It is usually a good idea
to give this command unless you
are using superscripted numbers
as labels.
r\bre\bev\bve\ber\brs\bse\be* _\bs_\bt_\br_\bi_\bn_\bg Reverse the fields whose names
are in _\bs_\bt_\br_\bi_\bn_\bg. Each field name
can be followed by a number which
says how many such fields should
be reversed. If no number is
given for a field, all such
fields will be reversed.
s\bse\bea\bar\brc\bch\bh-\b-i\big\bgn\bno\bor\bre\be* _\bf_\bi_\be_\bl_\bd_\bs While searching for keys in
databases for which no index
exists, ignore the contents of
_\bf_\bi_\be_\bl_\bd_\bs. Initially, fields X\bXY\bYZ\bZ
are ignored.
s\bse\bea\bar\brc\bch\bh-\b-t\btr\bru\bun\bnc\bca\bat\bte\be* _\bn Only require the first _\bn charac-
ters of keys to be given. In
effect when searching for a given
key, words in the database keys
are truncated to the maximum of _\bn
and the length of the key. Ini-
tially _\bn is 6.
s\bsh\bho\bor\brt\bt-\b-l\bla\bab\bbe\bel\bl* _\bs_\bt_\br_\bi_\bn_\bg _\bs_\bt_\br_\bi_\bn_\bg is a label expression that
specifies an alternative (usually
shorter) style of label. This is
used when the #\b# flag is given in
the citation. When using author-
date style labels, the identity
of the author or authors is some-
times clear from the context, and
so it may be desirable to omit
the author or authors from the
label. The s\bsh\bho\bor\brt\bt-\b-l\bla\bab\bbe\bel\bl command
Groff Version 1.08 30 December 1993 11
REFER(1) BSD Reference Manual REFER(1)
will typically be used to specify
a label containing just a date
and possibly a disambiguating
letter.
s\bso\bor\brt\bt* _\bs_\bt_\br_\bi_\bn_\bg Sort references according to
s\bst\btr\bri\bin\bng\bg. References will automat-
ically be accumulated. _\bs_\bt_\br_\bi_\bn_\bg
should be a list of field names,
each followed by a number, indi-
cating how many fields with the
name should be used for sorting.
+\b+ can be used to indicate that
all the fields with the name
should be used. Also .\b. can be
used to indicate the references
should be sorted using the (ten-
tative) label. (The L\bLa\bab\bbe\bel\bl
e\bex\bxp\bpr\bre\bes\bss\bsi\bio\bon\bns\bs subsection describes
the concept of a tentative
label.)
s\bso\bor\brt\bt-\b-a\bad\bdj\bja\bac\bce\ben\bnt\bt-\b-l\bla\bab\bbe\bel\bls\bs* Sort labels that are adjacent in
the text according to their posi-
tion in the reference list. This
command should usually be given
if the a\bab\bbb\bbr\bre\bev\bvi\bia\bat\bte\be-\b-l\bla\bab\bbe\bel\bl-\b-r\bra\ban\bng\bge\bes\bs
command has been given, or if the
label expression contains a <\b<>\b>
expression. This will have no
effect unless references are
being accumulated.
L\bLa\bab\bbe\bel\bl e\bex\bxp\bpr\bre\bes\bss\bsi\bio\bon\bns\bs
Label expressions can be evaluated both normally and ten-
tatively. The result of normal evaluation is used for
output. The result of tentative evaluation, called the
_\bt_\be_\bn_\bt_\ba_\bt_\bi_\bv_\be _\bl_\ba_\bb_\be_\bl_\b, is used to gather the information that
normal evaluation needs to disambiguate the label. Label
expressions specified by the d\bda\bat\bte\be-\b-a\bas\bs-\b-l\bla\bab\bbe\bel\bl and s\bsh\bho\bor\brt\bt-\b-l\bla\bab\bbe\bel\bl
commands are not evaluated tentatively. Normal and tenta-
tive evaluation are the same for all types of expression
other than @\b@, *\b*, and %\b% expressions. The description below
applies to normal evaluation, except where otherwise spec-
ified.
_\bf_\bi_\be_\bl_\bd
_\bf_\bi_\be_\bl_\bd _\bn
The _\bn-th part of _\bf_\bi_\be_\bl_\bd. If _\bn is omitted, it
defaults to 1.
Groff Version 1.08 30 December 1993 12
REFER(1) BSD Reference Manual REFER(1)
'\b'_\bs_\bt_\br_\bi_\bn_\bg'\b'
The characters in _\bs_\bt_\br_\bi_\bn_\bg literally.
@\b@ All the authors joined as specified by the j\bjo\boi\bin\bn-\b-
a\bau\but\bth\bho\bor\brs\bs command. The whole of each author's name
will be used. However, if the references are
sorted by author (that is the sort specification
starts with A\bA+\b+), then authors' last names will be
used instead, provided that this does not introduce
ambiguity, and also an initial subsequence of the
authors may be used instead of all the authors,
again provided that this does not introduce ambigu-
ity. The use of only the last name for the _\bi-th
author of some reference is considered to be
ambiguous if there is some other reference, such
that the first _\bi-1 authors of the references are
the same, the _\bi-th authors are not the same, but
the _\bi-th authors' last names are the same. A
proper initial subsequence of the sequence of
authors for some reference is considered to be
ambiguous if there is a reference with some other
sequence of authors which also has that subsequence
as a proper initial subsequence. When an initial
subsequence of authors is used, the remaining
authors are replaced by the string specified by the
e\bet\bt-\b-a\bal\bl command; this command may also specify addi-
tional requirements that must be met before an ini-
tial subsequence can be used. @\b@ tentatively evalu-
ates to a canonical representation of the authors,
such that authors that compare equally for sorting
purpose will have the same representation.
%\b%_\bn
%\b%a\ba
%\b%A\bA
%\b%i\bi
%\b%I\bI The serial number of the reference formatted
according to the character following the %\b%. The
serial number of a reference is 1 plus the number
of earlier references with same tentative label as
this reference. These expressions tentatively
evaluate to an empty string.
_\be_\bx_\bp_\br*\b* If there is another reference with the same tenta-
tive label as this reference, then _\be_\bx_\bp_\br, otherwise
an empty string. It tentatively evaluates to an
empty string.
_\be_\bx_\bp_\br+\b+_\bn
_\be_\bx_\bp_\br-\b-_\bn The first (+\b+) or last (-\b-) _\bn upper or lower case
letters or digits of _\be_\bx_\bp_\br. Troff special
Groff Version 1.08 30 December 1993 13
REFER(1) BSD Reference Manual REFER(1)
characters (such as \\b\(\b('\b'a\ba) count as a single letter.
Accent strings are retained but do not count
towards the total.
_\be_\bx_\bp_\br.\b.l\bl _\be_\bx_\bp_\br converted to lowercase.
_\be_\bx_\bp_\br.\b.u\bu _\be_\bx_\bp_\br converted to uppercase.
_\be_\bx_\bp_\br.\b.c\bc _\be_\bx_\bp_\br converted to caps and small caps.
_\be_\bx_\bp_\br.\b.r\br _\be_\bx_\bp_\br reversed so that the last name is first.
_\be_\bx_\bp_\br.\b.a\ba _\be_\bx_\bp_\br with first names abbreviated. Note that
fields specified in the a\bab\bbb\bbr\bre\bev\bvi\bia\bat\bte\be command are
abbreviated before any labels are evaluated. Thus
.\b.a\ba is useful only when you want a field to be
abbreviated in a label but not in a reference.
_\be_\bx_\bp_\br.\b.y\by The year part of _\be_\bx_\bp_\br.
_\be_\bx_\bp_\br.\b.+\b+y\by
The part of _\be_\bx_\bp_\br before the year, or the whole of
_\be_\bx_\bp_\br if it does not contain a year.
_\be_\bx_\bp_\br.\b.-\b-y\by
The part of _\be_\bx_\bp_\br after the year, or an empty string
if _\be_\bx_\bp_\br does not contain a year.
_\be_\bx_\bp_\br.\b.n\bn The last name part of _\be_\bx_\bp_\br.
_\be_\bx_\bp_\br_\b1~\b~_\be_\bx_\bp_\br_\b2
_\be_\bx_\bp_\br_\b1 except that if the last character of _\be_\bx_\bp_\br_\b1 is
-\b- then it will be replaced by _\be_\bx_\bp_\br_\b2.
_\be_\bx_\bp_\br_\b1 _\be_\bx_\bp_\br_\b2
The concatenation of _\be_\bx_\bp_\br_\b1 and _\be_\bx_\bp_\br_\b2.
_\be_\bx_\bp_\br_\b1|\b|_\be_\bx_\bp_\br_\b2
If _\be_\bx_\bp_\br_\b1 is non-empty then _\be_\bx_\bp_\br_\b1 otherwise _\be_\bx_\bp_\br_\b2.
_\be_\bx_\bp_\br_\b1&\b&_\be_\bx_\bp_\br_\b2
If _\be_\bx_\bp_\br_\b1 is non-empty then _\be_\bx_\bp_\br_\b2 otherwise an empty
string.
_\be_\bx_\bp_\br_\b1?\b?_\be_\bx_\bp_\br_\b2:\b:_\be_\bx_\bp_\br_\b3
If _\be_\bx_\bp_\br_\b1 is non-empty then _\be_\bx_\bp_\br_\b2 otherwise _\be_\bx_\bp_\br_\b3.
<\b<_\be_\bx_\bp_\br>\b> The label is in two parts, which are separated by
_\be_\bx_\bp_\br. Two adjacent two-part labels which have the
same first part will be merged by appending the
second part of the second label onto the first
Groff Version 1.08 30 December 1993 14
REFER(1) BSD Reference Manual REFER(1)
label separated by the string specified in the s\bse\bep\bp-\b-
a\bar\bra\bat\bte\be-\b-l\bla\bab\bbe\bel\bl-\b-s\bse\bec\bco\bon\bnd\bd-\b-p\bpa\bar\brt\bts\bs command (initially, a
comma followed by a space); the resulting label
will also be a two-part label with the same first
part as before merging, and so additional labels
can be merged into it. Note that it is permissible
for the first part to be empty; this maybe desir-
able for expressions used in the s\bsh\bho\bor\brt\bt-\b-l\bla\bab\bbe\bel\bl com-
mand.
(\b(_\be_\bx_\bp_\br)\b) The same as _\be_\bx_\bp_\br. Used for grouping.
The above expressions are listed in order of precedence
(highest first); &\b& and |\b| have the same precedence.
M\bMa\bac\bcr\bro\bo i\bin\bnt\bte\ber\brf\bfa\bac\bce\be
Each reference starts with a call to the macro ]\b]-\b-. The
string [\b[F\bF will be defined to be the label for this refer-
ence, unless the n\bno\bo-\b-l\bla\bab\bbe\bel\bl-\b-i\bin\bn-\b-r\bre\bef\bfe\ber\bre\ben\bnc\bce\be command has been
given. There then follows a series of string definitions,
one for each field: string [\b[_\bX corresponds to field _\bX. The
number register [\b[P\bP is set to 1 if the P\bP field contains a
range of pages. The [\b[T\bT, [\b[A\bA and [\b[O\bO number registers are
set to 1 according as the T\bT, A\bA and O\bO fields end with one
of the characters .\b.?\b?!\b!. The [\b[E\bE number register will be set
to 1 if the [\b[E\bE string contains more than one name. The
reference is followed by a call to the ]\b][\b[ macro. The
first argument to this macro gives a number representing
the type of the reference. If a reference contains a J\bJ
field, it will be classified as type 1, otherwise if it
contains a B\bB field, it will type 3, otherwise if it con-
tains a G\bG or R\bR field it will be type 4, otherwise if con-
tains a I\bI field it will be type 2, otherwise it will be
type 0. The second argument is a symbolic name for the
type: o\bot\bth\bhe\ber\br, j\bjo\bou\bur\brn\bna\bal\bl-\b-a\bar\brt\bti\bic\bcl\ble\be, b\bbo\boo\bok\bk, a\bar\brt\bti\bic\bcl\ble\be-\b-i\bin\bn-\b-b\bbo\boo\bok\bk or
t\bte\bec\bch\bh-\b-r\bre\bep\bpo\bor\brt\bt. Groups of references that have been accumu-
lated or are produced by the b\bbi\bib\bbl\bli\bio\bog\bgr\bra\bap\bph\bhy\by command are pre-
ceded by a call to the ]\b]<\b< macro and followed by a call to
the ]\b]>\b> macro.
F\bFI\bIL\bLE\bES\bS
/\b/u\bus\bsr\br/\b/s\bsh\bha\bar\bre\be/\b/d\bdi\bic\bct\bt/\b/p\bpa\bap\bpe\ber\brs\bs/\b/I\bIn\bnd\bd Default database.
_\bf_\bi_\bl_\be.\b.i\bi Index files.
S\bSE\bEE\bE A\bAL\bLS\bSO\bO
i\bin\bnd\bdx\bxb\bbi\bib\bb(1), l\blo\boo\bok\bkb\bbi\bib\bb(1), l\blk\bkb\bbi\bib\bb(1)
B\bBU\bUG\bGS\bS
In label expressions, <\b<>\b> expressions are ignored inside
.\b._\bc_\bh_\ba_\br expressions.
Groff Version 1.08 30 December 1993 15