cattobib — convert Z39.50 library catalog server data to BibTeX markup

Original version: Thu Jun 2 05:48:04 2005
Last updates: Thu Jun 2 05:48:04 2005     Tue Jun 28 13:27:12 2005     Thu Dec 10 10:19:47 2015     Fri Dec 11 09:06:18 2015     Mon May 27 08:26:20 2019                Valid HTML 3.2! Valid CSS!

cattobib is a handy tool for quick conversion of library catalog data to BibTeX entries that allow reuse of the data as automatically retrieved and reformatted citations in documents.

Source-code download links for the current version can be found here.

Here is a taste of how cattobib can be used to lookup catalog data by title (or author, or ISBN, or ...), and to change the default library catalog:

% cattobib -ti 'Classic Shell Scripting'
%%% -*-BibTeX-*-
  author =       "Arnold Robbins and Nelson H. F. Beebe",
  title =        "Classic shell scripting",
  publisher =    "O'Reilly",
  address =      "Sebastopol, CA",
  pages =        "xxii + 534",
  year =         "2005",
  ISBN =         "0-596-00595-4",
  ISBN-13 =      "978-0-596-00595-5", 
  LCCN =         "QA76.76.O63 R563 2005",
  bibdate =      "Thu Dec 10 14:26:12 MST 2015",
  bibsource =    "",
  URL =          ";
  acknowledgement = ack-nhfb,
  subject =      "Operating systems (Computers); Programming languages
                 (Electronic computers)",

% cattobib -s nyu 1-57586-584-X
%%% -*-BibTeX-*-
  author =       "Donald Ervin Knuth",
  title =        "Selected papers on fun and games",
  volume =       "192",
  publisher =    "CSLI Publications",
  address =      "Stanford, CA, USA",
  pages =        "xvii + 741",
  year =         "2011",
  ISBN =         "1-57586-585-8 (hardcover), 1-57586-584-X (paperback)",
  ISBN-13 =      "978-1-57586-585-0 (hardcover), 978-1-57586-584-3
  LCCN =         "QA99 .K58 2011",
  bibdate =      "Thu Dec 10 14:36:06 MST 2015",
  bibsource =    "",
  series =       "CSLI lecture notes",
  acknowledgement = ack-nhfb,
  author-dates = "1938--",
  subject =      "Mathematics; Miscellanea; Computer science",

Prerequisite software

The conversion task that cattobib is a complex one, and in the Unix tradition of combining small tools to make bigger ones, cattobib builds on several other packages that must first be installed before it can be used: see the README file in the distribution for details.

For your convenience, here are links to source code for those packages:

Unix systems always have at least one awk implementation (only one is needed), and some also have tcl and expect, so you may already have some of those.

The author's bibliography tools are in frequent daily use, and have been successfully installed on more than 70 flavors of Unix and Unix-like systems, so you should have no difficulty in installing them on your system.

Most current Unix distributions have binary package managers that can install all but the bib* tools. Here are some examples (all run as the root (administrative) user, or via sudo):

### Apple Mac OS X with MacPorts packaging
# port install gawk mawk nawk expect libxml2 tcl yaz

### ArchLinux-style packaging (ArchLinux)
# pacman -S gawk mawk nawk expect libxml2 tcl yaz

### Debian (Debian, GNU Hurd, KFreeBSD, Knoppix, Mint, Ubuntu, etc.)
# apt-get install gawk mawk original-awk expect libxml2 tcl yaz

### DragonFlyBSD and FreeBSD
# pkg install gawk mawk nawk expect libxml2 tcl86 yaz

### Minix
# pkgin install gawk mawk nawk expect libxml2 tcl yaz

### NetBSD
# pkg_add gawk mawk nawk tcl-expect libxml2 tcl yaz

### OpenBSD
# pkg_add gawk mawk expect tcl-8.6.4 yaz

### Red-Hat (CentOS, older Fedora, Red Hat, Scientific Linux, etc.)
# yum install gawk mawk nawk expect libxml2 tcl yaz

### Recent Fedora systems
# dnf install gawk mawk nawk expect libxml2 tcl yaz

### Illumos, OpenIndiana, and Solaris CSW package manager
# pkgutil --install gawk mawk expect tcl yaz

### SuSE and openSuSE packaging:
# zypper install gawk mawk nawk expect libxml2 tcl yaz

Warning: Be aware that some distributions install a program named nawk that is really gawk, as revealed by running it with the --version option. In such a case, it is recommended that you install the true software from its master source distribution . Although gawk supports additional features, output from the two differs slightly, causing apparent (but harmless) test failures in the cattobib test suite.

Latest documentation

Digitally-signed checksums

Software downloads