Refer (software)

Last updated
refer
Original author(s) Mike Lesk
Operating system Unix-like
Type Reference management
License depends on implementation

refer is a program for managing bibliographic references, and citing them in troff, nroff, and groff documents. It is implemented as a preprocessor.

Contents

refer was written by Mike Lesk at Bell Laboratories [1] [2] in or before 1978, and is now available as part of most Unix-like operating systems. A free reimplementation exists as part of the groff package.

As of 2015, refer sees little use, primarily because troff itself is not used much for longer technical writing that might need software support for reference and citation management. As of 2016, some reference management software (for instance, RefWorks) will import refer data.

Example

refer works with a "reference file", a text file where the author lists works to which they might want to refer. One such reference, to an article in a journal in this case, might look like:

%A Brian W. Kernighan %A Lorinda L. Cherry %T A System for Typesetting Mathematics %J J. Comm. ACM %V 18 %N 3 %D March 1978 %P 151-157 %K eqn

The author then can refer to it in their troff, groff, or nroff document by listing keywords which uniquely match this reference:

.[ kernighan cherry eqn .]

Database fields

A refer bibliographic database is a text file consisting of a series of records, separated by one or more blank lines. Within each record, each field starts with a %-sign at the beginning of the line and one character immediately after. 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 shown in the table below. Compare this scheme with the newer EndNote scheme which uses a similar syntax.

Database fields [3]
FieldMeaning
%AThe name of an author. If the name contains a title such as Jr. at the end, it should be separated from the last name by a comma. There can be multiple occurrences of the %A field. The order is significant. It is a good idea always to supply an %A field or a %Q field.
%BFor an article that is part of a book, the title of the book.
%CThe place (city) of publication.
%DThe date of publication. The year should be specified 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 is a good idea always to supply a %D field; if the date is unknown, a value such as in press or unknown can be used.
%EFor 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 fields and , (ed) or , (eds) should be appended to the last author.
%GUS Government ordering number.
%IThe publisher (issuer).
%JFor an article in a journal, the name of the journal.
%KKeywords to be used for searching.
%LLabel.
%NJournal issue number.
%OOther information. This is usually printed at the end of the reference.
%PPage number. A range of pages can be specified as m-n.
%QThe name of the author, if the author is not a person. This will only be used if there are no %A fields. There can only be one %Q field.
%RTechnical report number.
%SSeries name.
%TTitle. For an article in a book or journal, this should be the title of the article.
%VVolume number of the journal or book.
%XAnnotation.
  • For all fields except %A and %E, if there is more than one occurrence of a particular field in a record, only the last such field will be used.
  • A field with no value given is simply ignored.

See also

Data schemes

Other

Related Research Articles

<span class="mw-page-title-main">Brian Kernighan</span> Canadian computer scientist, co-creator of the Unix operating system

Brian Wilson Kernighan is a Canadian computer scientist.

<span class="mw-page-title-main">Markup language</span> Modern system for annotating a document

A markuplanguage is a text-encoding system consisting of a set of symbols inserted in a text document to control its structure, formatting, or the relationship between its parts. Markup is often used to control the display of the document or to enrich its content to facilitate automated processing.

troff, short for "typesetter roff", is the major component of a document processing system developed by Bell Labs for the Unix operating system. troff and the related nroff were both developed from the original roff.

man page Unix software documentation

A man page is a form of software documentation usually found on a Unix or Unix-like operating system. Topics covered include computer programs, formal standards and conventions, and even abstract concepts. A user may invoke a man page by issuing the man command.

<span class="mw-page-title-main">Typesetting</span> Composition of text by means of arranging physical types or digital equivalents

Typesetting is the composition of text by means of arranging physical type in mechanical systems or glyphs in digital systems representing characters. Stored types are retrieved and ordered according to a language's orthography for visual display. Typesetting requires one or more fonts. One significant effect of typesetting was that authorship of works could be spotted more easily, making it difficult for copiers who have not gained permission.

nroff is a text-formatting program on Unix and Unix-like operating systems. It produces output suitable for simple fixed-width printers and terminal windows. It is an integral part of the Unix help system, being used to format man pages for display.

Joseph Frank Ossanna, Jr. was an electrical engineer and computer programmer who worked as a member of the technical staff at the Bell Telephone Laboratories in Murray Hill, New Jersey. He became actively engaged in the software design of Multics, a general-purpose operating system used at Bell.

roff is a typesetting markup language. As the first Unix text-formatting computer program, it is a predecessor of the nroff and troff document processing systems.

<span class="mw-page-title-main">BibTeX</span> Reference management software for formatting lists of references

BibTeX is reference management software for formatting lists of references. The BibTeX tool is typically used together with the LaTeX document preparation system. Within the typesetting system, its name is styled as . The name is a portmanteau of the word bibliography and the name of the TeX typesetting software.

The Programmer's Workbench (PWB/UNIX) is an early, now discontinued, version of the Unix operating system that had been created in the Bell Labs Computer Science Research Group of AT&T. Its stated goal was to provide a time-sharing working environment for large groups of programmers, writing software for larger batch processing computers.

Part of the troff suite of Unix document layout tools, eqn is a preprocessor that formats equations for printing. A similar program, neqn, accepted the same input as eqn, but produced output tuned to look better in nroff. The eqn program was created in 1974 by Brian Kernighan and Lorinda Cherry. It was implemented using yacc compiler-compiler.

Part of the troff suite of Unix document layout tools, tbl is a preprocessor that formats tables in preparation for processing with troff/nroff.

<i>The Unix Programming Environment</i>

The Unix Programming Environment, first published in 1984 by Prentice Hall, is a book written by Brian W. Kernighan and Rob Pike, both of Bell Labs and considered an important and early document of the Unix operating system.

groff (software) Unix typesetting software used for man pages

groff is a typesetting system that creates formatted output when given plain text mixed with formatting commands. It is the GNU replacement for the troff and nroff text formatters.

RIS is a standardized tag format developed by Research Information Systems, Incorporated to enable citation programs to exchange data. It is supported by a number of reference managers. Many digital libraries, like IEEE Xplore, Scopus, the ACM Portal, Scopemed, ScienceDirect, SpringerLink, Rayyan, Accordance Bible Software, and online library catalogs can export citations in this format. Citation management applications can export and import citations in this format.

In computing, Pic is a domain-specific programming language by Brian Kernighan for specifying line diagrams. The language contains predefined basic linear objects: line, move, arrow, and spline, the planar objects box, circle, ellipse, arc, and definable composite elements. Objects are placed with respect to other objects or absolute coordinates. A liberal interpretation of the input invokes default parameters when objects are incompletely specified. An interpreter translates this description into concrete drawing commands in a variety of possible output formats. Pic is a procedural programming language, with variable assignment, macros, conditionals, and looping. The language is an example of a little language originally intended for the comfort of non-programmers in the Unix environment.

<span class="mw-page-title-main">Unix</span> Family of computer operating systems

Unix is a family of multitasking, multi-user computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, and others.

Lorinda Cherry was an American computer scientist and programmer. Much of her career was spent at Bell Labs, where she was for many years a member of the original Unix Lab. Cherry developed several mathematical tools and utilities for text formatting and analysis, and influenced the creation of others.

The GSI C/A/T is a phototypesetter developed by Graphic Systems in 1972. This phototypesetter, along with troff software for UNIX, revolutionized the typesetting and document printing industry. Phototypesetting is most often used with offset printing technology.

mandoc is a utility used for formatting man pages in BSD Operating Systems, specifically those written in the mdoc and man macro languages. Unlike the groff and older troff and nroff tools that are predominantly used for this purpose by tools such as man, mandoc focuses specifically on manuals and is not suitable for general-purpose type-setting.

References

  1. Michael Lesk. Some applications of inverted indexes on the Unix system. In UNIX Programmer's manual: Supplementary Documents, volume 2. Holt, Rinehart and Winston, seventh edition, 1982. Also available online
  2. McIlroy, M. D. (1987). A Research Unix reader: annotated excerpts from the Programmer's Manual, 1971–1986 (PDF) (Technical report). CSTR. Bell Labs. 139.
  3. refer man page, version 1.22.3, dated 2 July 2016.