aboutsummaryrefslogtreecommitdiff
path: root/test/command
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2020-09-06 16:25:16 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2020-09-21 10:15:50 -0700
commite0984a43a99231e72c02a0a716c8d0315de9abdf (patch)
tree8531ef58c2470d372ff2427a6ae09a6284461471 /test/command
parent89c577befb78b32a0884b6092e0415c0dcadab72 (diff)
downloadpandoc-e0984a43a99231e72c02a0a716c8d0315de9abdf.tar.gz
Add built-in citation support using new citeproc library.
This deprecates the use of the external pandoc-citeproc filter; citation processing is now built in to pandoc. * Add dependency on citeproc library. * Add Text.Pandoc.Citeproc module (and some associated unexported modules under Text.Pandoc.Citeproc). Exports `processCitations`. [API change] * Add data files needed for Text.Pandoc.Citeproc: default.csl in the data directory, and a citeproc directory that is just used at compile-time. Note that we've added file-embed as a mandatory rather than a conditional depedency, because of the biblatex localization files. We might eventually want to use readDataFile for this, but it would take some code reorganization. * Text.Pandoc.Loging: Add `CiteprocWarning` to `LogMessage` and use it in `processCitations`. [API change] * Add tests from the pandoc-citeproc package as command tests (including some tests pandoc-citeproc did not pass). * Remove instructions for building pandoc-citeproc from CI and release binary build instructions. We will no longer distribute pandoc-citeproc. * Markdown reader: tweak abbreviation support. Don't insert a nonbreaking space after a potential abbreviation if it comes right before a note or citation. This messes up several things, including citeproc's moving of note citations. * Add `csljson` as and input and output format. This allows pandoc to convert between `csljson` and other bibliography formats, and to generate formatted versions of CSL JSON bibliographies. * Add module Text.Pandoc.Writers.CslJson, exporting `writeCslJson`. [API change] * Add module Text.Pandoc.Readers.CslJson, exporting `readCslJson`. [API change] * Added `bibtex`, `biblatex` as input formats. This allows pandoc to convert between BibLaTeX and BibTeX and other bibliography formats, and to generated formatted versions of BibTeX/BibLaTeX bibliographies. * Add module Text.Pandoc.Readers.BibTeX, exporting `readBibTeX` and `readBibLaTeX`. [API change] * Make "standalone" implicit if output format is a bibliography format. This is needed because pandoc readers for bibliography formats put the bibliographic information in the `references` field of metadata; and unless standalone is specified, metadata gets ignored. (TODO: This needs improvement. We should trigger standalone for the reader when the input format is bibliographic, and for the writer when the output format is markdown.) * Carry over `citationNoteNum` to `citationNoteNumber`. This was just ignored in pandoc-citeproc. * Text.Pandoc.Filter: Add `CiteprocFilter` constructor to Filter. [API change] This runs the processCitations transformation. We need to treat it like a filter so it can be placed in the sequence of filter runs (after some, before others). In FromYAML, this is parsed from `citeproc` or `{type: citeproc}`, so this special filter may be specified either way in a defaults file (or by `citeproc: true`, though this gives no control of positioning relative to other filters). TODO: we need to add something to the manual section on defaults files for this. * Add deprecation warning if `upandoc-citeproc` filter is used. * Add `--citeproc/-C` option to trigger citation processing. This behaves like a filter and will be positioned relative to filters as they appear on the command line. * Rewrote the manual on citatations, adding a dedicated Citations section which also includes some information formerly found in the pandoc-citeproc man page. * Look for CSL styles in the `csl` subdirectory of the pandoc user data directory. This changes the old pandoc-citeproc behavior, which looked in `~/.csl`. Users can simply symlink `~/.csl` to the `csl` subdirectory of their pandoc user data directory if they want the old behavior. * Add support for CSL bibliography entry formatting to LaTeX, HTML, Ms writers. Added CSL-related CSS to styles.html.
Diffstat (limited to 'test/command')
-rw-r--r--test/command/5541-localLink.md2
-rw-r--r--test/command/5541-nesting.md2
-rw-r--r--test/command/5541-urlLink.md2
-rw-r--r--test/command/5849-prefix.md11
-rw-r--r--test/command/6675.md2
-rw-r--r--test/command/advanced-optical-materials.csl155
-rw-r--r--test/command/annales.csl334
-rw-r--r--test/command/apa.csl474
-rw-r--r--test/command/archeologie-medievale.csl291
-rw-r--r--test/command/biblatex-266.md34
-rw-r--r--test/command/biblatex-aksin.md78
-rw-r--r--test/command/biblatex-almendro.md71
-rw-r--r--test/command/biblatex-angenendt.md66
-rw-r--r--test/command/biblatex-aristotle-anima.md62
-rw-r--r--test/command/biblatex-aristotle-physics.md63
-rw-r--r--test/command/biblatex-aristotle-poetics.md65
-rw-r--r--test/command/biblatex-aristotle-rhetoric.md80
-rw-r--r--test/command/biblatex-article.md128
-rw-r--r--test/command/biblatex-augustine.md56
-rw-r--r--test/command/biblatex-averroes-bland.md85
-rw-r--r--test/command/biblatex-averroes-hannes.md84
-rw-r--r--test/command/biblatex-averroes-hercz.md85
-rw-r--r--test/command/biblatex-baez-article.md76
-rw-r--r--test/command/biblatex-baez-online.md69
-rw-r--r--test/command/biblatex-basic.md69
-rw-r--r--test/command/biblatex-bertram.md66
-rw-r--r--test/command/biblatex-bibstring-resolution.md20
-rw-r--r--test/command/biblatex-book-averroes.md128
-rw-r--r--test/command/biblatex-book-coleridge.md59
-rw-r--r--test/command/biblatex-book-title-maintitle-series.md39
-rw-r--r--test/command/biblatex-book-vazques-de-parga.md48
-rw-r--r--test/command/biblatex-brandt.md88
-rw-r--r--test/command/biblatex-britannica.md85
-rw-r--r--test/command/biblatex-chiu.md77
-rw-r--r--test/command/biblatex-cicero.md82
-rw-r--r--test/command/biblatex-cms.md81
-rw-r--r--test/command/biblatex-coleridge.md86
-rw-r--r--test/command/biblatex-companion.md70
-rw-r--r--test/command/biblatex-cotton.md69
-rw-r--r--test/command/biblatex-crossref-inbook-mvbook.md58
-rw-r--r--test/command/biblatex-crossref-nested.md100
-rw-r--r--test/command/biblatex-ctan.md73
-rw-r--r--test/command/biblatex-dates.md162
-rw-r--r--test/command/biblatex-doody.md101
-rw-r--r--test/command/biblatex-edtf-date.md73
-rw-r--r--test/command/biblatex-escapedquotes.md51
-rw-r--r--test/command/biblatex-examples.bib1674
-rw-r--r--test/command/biblatex-formatting.md23
-rw-r--r--test/command/biblatex-gaonkar-in.md62
-rw-r--r--test/command/biblatex-gaonkar.md59
-rw-r--r--test/command/biblatex-geer.md70
-rw-r--r--test/command/biblatex-gerhardt.md64
-rw-r--r--test/command/biblatex-gillies.md70
-rw-r--r--test/command/biblatex-glashow.md51
-rw-r--r--test/command/biblatex-gonzalez.md62
-rw-r--r--test/command/biblatex-hammond.md63
-rw-r--r--test/command/biblatex-herrmann.md70
-rw-r--r--test/command/biblatex-hyman.md79
-rw-r--r--test/command/biblatex-iliad.md68
-rw-r--r--test/command/biblatex-inbook-title-booktitle-maintitle-series-2.md48
-rw-r--r--test/command/biblatex-inbook-title-booktitle-maintitle-series.md44
-rw-r--r--test/command/biblatex-inbook.md147
-rw-r--r--test/command/biblatex-incollection-2.md98
-rw-r--r--test/command/biblatex-incollection.md130
-rw-r--r--test/command/biblatex-inproceedings.md88
-rw-r--r--test/command/biblatex-issue288.md35
-rw-r--r--test/command/biblatex-itzhaki.md83
-rw-r--r--test/command/biblatex-jaffe.md82
-rw-r--r--test/command/biblatex-jcg.md54
-rw-r--r--test/command/biblatex-kant-kpv.md90
-rw-r--r--test/command/biblatex-kant-ku.md82
-rw-r--r--test/command/biblatex-kastenholz.md126
-rw-r--r--test/command/biblatex-knuth-ct-a.md78
-rw-r--r--test/command/biblatex-knuth-ct-b.md70
-rw-r--r--test/command/biblatex-knuth-ct-c.md69
-rw-r--r--test/command/biblatex-knuth-ct-d.md71
-rw-r--r--test/command/biblatex-knuth-ct-e.md66
-rw-r--r--test/command/biblatex-knuth-ct-related.md72
-rw-r--r--test/command/biblatex-knuth-ct.md66
-rw-r--r--test/command/biblatex-kowalik.md68
-rw-r--r--test/command/biblatex-kullback-related.md62
-rw-r--r--test/command/biblatex-kullback-reprint.md71
-rw-r--r--test/command/biblatex-kullback.md52
-rw-r--r--test/command/biblatex-laufenberg.md109
-rw-r--r--test/command/biblatex-loh.md65
-rw-r--r--test/command/biblatex-malinowski.md67
-rw-r--r--test/command/biblatex-manual.md51
-rw-r--r--test/command/biblatex-markey.md65
-rw-r--r--test/command/biblatex-maron.md70
-rw-r--r--test/command/biblatex-massa.md56
-rw-r--r--test/command/biblatex-moore-related.md66
-rw-r--r--test/command/biblatex-moore.md56
-rw-r--r--test/command/biblatex-moraux.md94
-rw-r--r--test/command/biblatex-murray.md104
-rw-r--r--test/command/biblatex-nietzsche-historie.md100
-rw-r--r--test/command/biblatex-nietzsche-ksa.md89
-rw-r--r--test/command/biblatex-nietzsche-ksa1.md95
-rw-r--r--test/command/biblatex-nussbaum.md63
-rw-r--r--test/command/biblatex-online.md64
-rw-r--r--test/command/biblatex-options-url-false-doi-false.md57
-rw-r--r--test/command/biblatex-padhye.md117
-rw-r--r--test/command/biblatex-patent.md158
-rw-r--r--test/command/biblatex-periodical.md30
-rw-r--r--test/command/biblatex-piccato.md59
-rw-r--r--test/command/biblatex-pines.md77
-rw-r--r--test/command/biblatex-quotes.md44
-rw-r--r--test/command/biblatex-reese.md71
-rw-r--r--test/command/biblatex-report.md119
-rw-r--r--test/command/biblatex-salam.md69
-rw-r--r--test/command/biblatex-sarfraz.md65
-rw-r--r--test/command/biblatex-shore.md66
-rw-r--r--test/command/biblatex-sigfridsson.md106
-rw-r--r--test/command/biblatex-sorace.md65
-rw-r--r--test/command/biblatex-spiegelberg.md74
-rw-r--r--test/command/biblatex-springer.md58
-rw-r--r--test/command/biblatex-strings.md46
-rw-r--r--test/command/biblatex-test-case-conversion.md73
-rw-r--r--test/command/biblatex-textnormal.md17
-rw-r--r--test/command/biblatex-thesis.md68
-rw-r--r--test/command/biblatex-title-and-shorttitle.md76
-rw-r--r--test/command/biblatex-vangennep-related.md69
-rw-r--r--test/command/biblatex-vangennep-trans.md69
-rw-r--r--test/command/biblatex-vangennep.md61
-rw-r--r--test/command/biblatex-vazques-de-parga-mvbook.md75
-rw-r--r--test/command/biblatex-vazques-de-parga.md74
-rw-r--r--test/command/biblatex-video.md19
-rw-r--r--test/command/biblatex-vizedom-related.md68
-rw-r--r--test/command/biblatex-wassenberg.md83
-rw-r--r--test/command/biblatex-weinberg.md52
-rw-r--r--test/command/biblatex-westfahl-frontier.md60
-rw-r--r--test/command/biblatex-westfahl-space.md106
-rw-r--r--test/command/biblatex-wilde.md65
-rw-r--r--test/command/biblatex-worman.md60
-rw-r--r--test/command/biblatex-yoon.md67
-rw-r--r--test/command/biblio.bib26
-rw-r--r--test/command/bibtex-basic.md71
-rw-r--r--test/command/bioethics.csl226
-rw-r--r--test/command/chicago-annotated-bibliography.csl1207
-rw-r--r--test/command/chicago-author-date-with-original-date-and-status.csl575
-rw-r--r--test/command/chicago-fullnote-bibliography.csl1182
-rw-r--r--test/command/chicago-note-bibliography.csl1005
-rw-r--r--test/command/chinese-gb7714-2005-numeric.csl213
-rw-r--r--test/command/citeproc-7a.md42
-rw-r--r--test/command/citeproc-7b.md36
-rw-r--r--test/command/din-1505-2.csl406
-rw-r--r--test/command/harvard-university-of-kent.csl253
-rw-r--r--test/command/ieee.csl339
-rw-r--r--test/command/issue160.csl28
-rw-r--r--test/command/issue437.csl26
-rw-r--r--test/command/issue58.csl553
-rw-r--r--test/command/jats.csl208
-rw-r--r--test/command/le-tapuscrit-note.csl496
-rw-r--r--test/command/locators.csl68
-rw-r--r--test/command/modern-humanities-research-association.csl445
-rw-r--r--test/command/oscola.csl680
-rw-r--r--test/command/pandoc-citeproc-118.md28
-rw-r--r--test/command/pandoc-citeproc-119.md39
-rw-r--r--test/command/pandoc-citeproc-13.md29
-rw-r--r--test/command/pandoc-citeproc-136.md23
-rw-r--r--test/command/pandoc-citeproc-14.md78
-rw-r--r--test/command/pandoc-citeproc-152.md65
-rw-r--r--test/command/pandoc-citeproc-160.md46
-rw-r--r--test/command/pandoc-citeproc-175.md45
-rw-r--r--test/command/pandoc-citeproc-197.md31
-rw-r--r--test/command/pandoc-citeproc-213.md34
-rw-r--r--test/command/pandoc-citeproc-25.md31
-rw-r--r--test/command/pandoc-citeproc-250.md21
-rw-r--r--test/command/pandoc-citeproc-27.md39
-rw-r--r--test/command/pandoc-citeproc-292.md43
-rw-r--r--test/command/pandoc-citeproc-301.md25
-rw-r--r--test/command/pandoc-citeproc-307.md31
-rw-r--r--test/command/pandoc-citeproc-31.md48
-rw-r--r--test/command/pandoc-citeproc-312.md171
-rw-r--r--test/command/pandoc-citeproc-320.md254
-rw-r--r--test/command/pandoc-citeproc-320a.md87
-rw-r--r--test/command/pandoc-citeproc-322.md35
-rw-r--r--test/command/pandoc-citeproc-325.md30
-rw-r--r--test/command/pandoc-citeproc-327.md51
-rw-r--r--test/command/pandoc-citeproc-338.md35
-rw-r--r--test/command/pandoc-citeproc-351.md27
-rw-r--r--test/command/pandoc-citeproc-356.md25
-rw-r--r--test/command/pandoc-citeproc-360.md35
-rw-r--r--test/command/pandoc-citeproc-361.md80
-rw-r--r--test/command/pandoc-citeproc-365.md39
-rw-r--r--test/command/pandoc-citeproc-371.md41
-rw-r--r--test/command/pandoc-citeproc-38.md29
-rw-r--r--test/command/pandoc-citeproc-386.md35
-rw-r--r--test/command/pandoc-citeproc-392.md29
-rw-r--r--test/command/pandoc-citeproc-399.md45
-rw-r--r--test/command/pandoc-citeproc-401.md59
-rw-r--r--test/command/pandoc-citeproc-408.md39
-rw-r--r--test/command/pandoc-citeproc-416.md61
-rw-r--r--test/command/pandoc-citeproc-437.md23
-rw-r--r--test/command/pandoc-citeproc-47.md113
-rw-r--r--test/command/pandoc-citeproc-51.md45
-rw-r--r--test/command/pandoc-citeproc-53.md54
-rw-r--r--test/command/pandoc-citeproc-57.md38
-rw-r--r--test/command/pandoc-citeproc-58.md33
-rw-r--r--test/command/pandoc-citeproc-61.md79
-rw-r--r--test/command/pandoc-citeproc-64.md24
-rw-r--r--test/command/pandoc-citeproc-65.md38
-rw-r--r--test/command/pandoc-citeproc-68.md56
-rw-r--r--test/command/pandoc-citeproc-7.md31
-rw-r--r--test/command/pandoc-citeproc-70.md73
-rw-r--r--test/command/pandoc-citeproc-75.md67
-rw-r--r--test/command/pandoc-citeproc-76.md64
-rw-r--r--test/command/pandoc-citeproc-77.md67
-rw-r--r--test/command/pandoc-citeproc-82.md40
-rw-r--r--test/command/pandoc-citeproc-87.md157
-rw-r--r--test/command/pandoc-citeproc-chicago-author-date.md111
-rw-r--r--test/command/pandoc-citeproc-chicago-fullnote-bibliography.md134
-rw-r--r--test/command/pandoc-citeproc-ieee.md115
-rw-r--r--test/command/pandoc-citeproc-locators-delimited.md127
-rw-r--r--test/command/pandoc-citeproc-locators-integrated.md159
-rw-r--r--test/command/pandoc-citeproc-move-period-inside-quote.md53
-rw-r--r--test/command/pandoc-citeproc-no-author.md73
-rw-r--r--test/command/pandoc-citeproc-number-of-volumes.md29
-rw-r--r--test/command/pandoc-citeproc-page-range.md32
-rw-r--r--test/command/sage-harvard.csl202
-rw-r--r--test/command/science.csl245
-rw-r--r--test/command/style399.csl12
-rw-r--r--test/command/vancouver.csl351
-rw-r--r--test/command/zeitschrift-fur-kunstgeschichte.csl346
223 files changed, 24913 insertions, 10 deletions
diff --git a/test/command/5541-localLink.md b/test/command/5541-localLink.md
index 16430be34..077005160 100644
--- a/test/command/5541-localLink.md
+++ b/test/command/5541-localLink.md
@@ -146,4 +146,4 @@ if you can read this text, [and it's linked]{#spanner} - all good!
</Properties>
</Hyperlink>
</Document>
-``` \ No newline at end of file
+```
diff --git a/test/command/5541-nesting.md b/test/command/5541-nesting.md
index 616184f5c..194b79164 100644
--- a/test/command/5541-nesting.md
+++ b/test/command/5541-nesting.md
@@ -94,4 +94,4 @@
</Story>
</Document>
-``` \ No newline at end of file
+```
diff --git a/test/command/5541-urlLink.md b/test/command/5541-urlLink.md
index 2ba81ce29..453653ffc 100644
--- a/test/command/5541-urlLink.md
+++ b/test/command/5541-urlLink.md
@@ -109,4 +109,4 @@ some more text that [links to](https://www.pandoc.org) Pandoc.
</Properties>
</Hyperlink>
</Document>
-``` \ No newline at end of file
+```
diff --git a/test/command/5849-prefix.md b/test/command/5849-prefix.md
index 61af8f03a..f3217a187 100644
--- a/test/command/5849-prefix.md
+++ b/test/command/5849-prefix.md
@@ -2,31 +2,30 @@
% pandoc -t latex --biblatex
[e.g. @a1;@a2;@a3; but also @b1;@b2;@b3]
^D
-\autocites[e.g.~][]{a1,a2,a3}[but also][]{b1,b2,b3}
+\autocites[e.g.][]{a1,a2,a3}[but also][]{b1,b2,b3}
```
```
% pandoc -t latex --biblatex
[e.g. @a1; e.g. @a2;@a3; but also @b1;@b2;but also @b3]
^D
-\autocites[e.g.~][]{a1}[e.g.~][]{a2,a3}[but also][]{b1,b2}[but
-also][]{b3}
+\autocites[e.g.][]{a1}[e.g.][]{a2,a3}[but also][]{b1,b2}[but also][]{b3}
```
```
% pandoc -t latex --biblatex
[e.g. @a1, ch.3 and elsewhere;@a2;@a3; but also @a4;@a5]
^D
-\autocites[e.g.~][ch.3 and elsewhere]{a1}{a2,a3}[but also][]{a4,a5}
+\autocites[e.g.][ch.3 and elsewhere]{a1}{a2,a3}[but also][]{a4,a5}
```
```
% pandoc -t latex --biblatex
[e.g. @a1;@a2, ch.3 and elsewhere;@a3; but also @a4;@a5]
^D
-\autocites[e.g.~][ch.3 and elsewhere]{a1,a2}{a3}[but also][]{a4,a5}
+\autocites[e.g.][ch.3 and elsewhere]{a1,a2}{a3}[but also][]{a4,a5}
```
```
% pandoc -t latex --biblatex
[e.g. @a1, blah;@a2, ch.3 and elsewhere;@a3; but also @b4;@b5]
^D
-\autocites[e.g.~][blah]{a1}[ch.3 and elsewhere]{a2}{a3}[but
+\autocites[e.g.][blah]{a1}[ch.3 and elsewhere]{a2}{a3}[but
also][]{b4,b5}
```
diff --git a/test/command/6675.md b/test/command/6675.md
index eac4214d7..d2984571f 100644
--- a/test/command/6675.md
+++ b/test/command/6675.md
@@ -131,4 +131,4 @@ and some text that [links to](#header-1) the first header
</Properties>
</Hyperlink>
</Document>
-``` \ No newline at end of file
+```
diff --git a/test/command/advanced-optical-materials.csl b/test/command/advanced-optical-materials.csl
new file mode 100644
index 000000000..23e80cf1a
--- /dev/null
+++ b/test/command/advanced-optical-materials.csl
@@ -0,0 +1,155 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="sort-only" default-locale="en-US">
+ <info>
+ <title>Advanced Optical Materials</title>
+ <id>http://www.zotero.org/styles/advanced-optical-materials</id>
+ <link href="http://www.zotero.org/styles/advanced-optical-materials" rel="self"/>
+ <link href="http://www.zotero.org/styles/small" rel="template"/>
+ <link href="http://onlinelibrary.wiley.com/journal/10.1002/(ISSN)2195-1071/homepage/2298_forauthors.html" rel="documentation"/>
+ <author>
+ <name>Martin F. Schumann</name>
+ <email>mfs@mfs.name</email>
+ </author>
+ <category citation-format="numeric"/>
+ <category field="engineering"/>
+ <eissn>2195-1071</eissn>
+ <summary>A style for Wiley's Advanced Optical Materials</summary>
+ <updated>2017-02-16T15:37:41+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <macro name="author">
+ <names variable="author">
+ <name initialize-with=". " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", " text-case="capitalize-first" suffix=" "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <label form="short" text-case="capitalize-first" suffix=".: " strip-periods="true"/>
+ <name initialize-with="." delimiter=", " delimiter-precedes-last="always"/>
+ </names>
+ </macro>
+ <macro name="year-date">
+ <group font-weight="bold">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else>
+ <text term="no date" form="short"/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <macro name="access-date">
+ <group delimiter=", ">
+ <date variable="accessed">
+ <date-part name="month" prefix="accessed: " suffix=", " form="short"/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </macro>
+ <macro name="access">
+ <choose>
+ <if variable="page" match="none">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="DOI: "/>
+ </if>
+ </choose>
+ <choose>
+ <if type="webpage">
+ <text variable="URL"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <group delimiter=", ">
+ <text variable="publisher" text-case="capitalize-all"/>
+ <text variable="publisher-place" text-case="title"/>
+ </group>
+ </macro>
+ <macro name="pages">
+ <label variable="page" form="short" suffix=" "/>
+ <text variable="page"/>
+ </macro>
+ <citation collapse="citation-number">
+ <sort>
+ <key variable="citation-number"/>
+ </sort>
+ <layout prefix="[" suffix="]" delimiter="," vertical-align="sup">
+ <text variable="citation-number"/>
+ </layout>
+ </citation>
+ <bibliography entry-spacing="0" second-field-align="flush" line-spacing="2">
+ <layout suffix=".">
+ <text variable="citation-number" prefix="[" suffix="]"/>
+ <text macro="author" suffix=", "/>
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <group delimiter=", ">
+ <text variable="title" text-case="title" font-style="italic"/>
+ <text macro="publisher"/>
+ <text macro="year-date"/>
+ </group>
+ </if>
+ <else-if type="chapter paper-conference" match="any">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text term="in"/>
+ <text variable="container-title" form="short" text-case="title" font-style="italic"/>
+ <text macro="editor" prefix="(" suffix=")"/>
+ </group>
+ <text macro="publisher"/>
+ <text macro="year-date"/>
+ <group delimiter=" ">
+ <text macro="pages"/>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="patent">
+ <group delimiter=", ">
+ <text variable="number" font-style="italic"/>
+ <text macro="year-date"/>
+ </group>
+ </else-if>
+ <else-if type="thesis">
+ <group delimiter=", ">
+ <text variable="title" text-case="title"/>
+ <text variable="genre"/>
+ <text variable="publisher"/>
+ <text macro="year-date"/>
+ </group>
+ </else-if>
+ <else-if type="webpage">
+ <group delimiter=", ">
+ <text variable="title"/>
+ <text macro="access"/>
+ <text macro="access-date"/>
+ </group>
+ </else-if>
+ <else>
+ <group delimiter=" ">
+ <text variable="container-title" form="short" font-style="italic"/>
+ <group delimiter=", ">
+ <text macro="year-date"/>
+ <group>
+ <text variable="volume" font-style="italic"/>
+ </group>
+ <text variable="page-first"/>
+ </group>
+ </group>
+ <text macro="access" prefix=", "/>
+ </else>
+ </choose>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/annales.csl b/test/command/annales.csl
new file mode 100644
index 000000000..ee370da05
--- /dev/null
+++ b/test/command/annales.csl
@@ -0,0 +1,334 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" default-locale="fr-FR" version="1.0" page-range-format="expanded" demote-non-dropping-particle="sort-only">
+ <info>
+ <title>Annales. Histoire, Sciences sociales (French)</title>
+ <id>http://www.zotero.org/styles/annales</id>
+ <link href="http://www.zotero.org/styles/annales" rel="self"/>
+ <link href="http://annales.ehess.fr/?lang=en/" rel="documentation"/>
+ <author>
+ <name>Franziska Heimburger</name>
+ <email>zotero@franziska.fr</email>
+ </author>
+ <category citation-format="note"/>
+ <category field="social_science"/>
+ <issn>0395-2649</issn>
+ <updated>2013-08-29T04:18:55+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="fr">
+ <terms>
+ <term name="ordinal-01">ère</term>
+ <term name="ordinal-02">e</term>
+ <term name="ordinal-03">e</term>
+ <term name="ordinal-04">e</term>
+ <term name="cited">op.&#160;cit.</term>
+ <term name="page" form="short">
+ <single>p.</single>
+ <multiple>p.</multiple>
+ </term>
+ <term name="editor" form="short">
+ <single>dir.</single>
+ <multiple>dir.</multiple>
+ </term>
+ </terms>
+ </locale>
+ <macro name="author">
+ <names variable="author">
+ <name form="long" and="text" delimiter-precedes-last="never">
+ <name-part name="family" font-variant="small-caps"/>
+ </name>
+ <label form="short" prefix="&#160;(" suffix=")"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="author-short">
+ <names variable="author">
+ <name form="long" and="text" initialize-with=". " delimiter-precedes-last="never">
+ <name-part name="family" font-variant="small-caps"/>
+ </name>
+ <label form="short" prefix="&#160;(" suffix=")"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <name form="long" and="text" delimiter-precedes-last="never" sort-separator=" " font-style="normal">
+ </name>
+ <label form="short" prefix="&#160;(" suffix=".)"/>
+ </names>
+ </macro>
+ <macro name="translator">
+ <names variable="translator">
+ <name form="long" and="text" delimiter-precedes-last="never" sort-separator=" " font-style="normal" prefix=" trad. fr. ">
+ <name-part name="family" font-variant="small-caps"/>
+ </name>
+ </names>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="bill book graphic legal_case motion_picture report song" match="any">
+ <text variable="title" text-case="capitalize-first" font-style="italic"/>
+ </if>
+ <else-if type="article-journal article-newspaper article-magazine" match="any">
+ <group delimiter=", ">
+ <text variable="title" text-case="capitalize-first" quotes="true" font-style="normal"/>
+ <text variable="container-title" font-style="italic"/>
+ </group>
+ </else-if>
+ <else-if type="thesis" match="any">
+ <group>
+ <text variable="title" text-case="capitalize-first" quotes="true" font-style="normal"/>
+ <text variable="genre" suffix=", " prefix=" "/>
+ <text variable="publisher"/>
+ </group>
+ </else-if>
+ <else-if type="manuscript" match="any">
+ <group delimiter=",">
+ <text variable="title" text-case="capitalize-first" quotes="true" font-style="normal"/>
+ <text variable="genre" prefix=" "/>
+ </group>
+ </else-if>
+ <else-if type="chapter entry-dictionary entry-encyclopedia" match="any">
+ <group>
+ <text variable="title" text-case="capitalize-first" quotes="true" suffix=","/>
+ <text value="in" font-style="italic" suffix=" " prefix=" "/>
+ <text macro="editor" suffix=", "/>
+ <text variable="container-title" text-case="capitalize-first" font-style="italic"/>
+ </group>
+ </else-if>
+ <else-if type="webpage" match="any">
+ <group>
+ <text variable="title" text-case="capitalize-first" font-style="italic" suffix=", "/>
+ <text variable="URL" text-decoration="underline"/>
+ </group>
+ </else-if>
+ <else>
+ <text variable="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="pub-place">
+ <choose>
+ <if type="bill book chapter entry-dictionary entry-encyclopedia thesis graphic legal_case manuscript motion_picture paper-conference report song" match="any">
+ <text variable="publisher-place"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if type="bill book chapter entry-dictionary entry-encyclopedia graphic legal_case motion_picture paper-conference report song" match="any">
+ <text variable="publisher"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="yearpage">
+ <choose>
+ <if type="bill book graphic legal_case motion_picture paper-conference manuscript report song thesis" match="any">
+ <group delimiter=", " font-style="normal">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ <group delimiter=" ">
+ <text term="volume" form="short"/>
+ <text variable="volume"/>
+ </group>
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="chapter entry-dictionary entry-encyclopedia" match="any">
+ <group delimiter=" " font-style="normal">
+ <date variable="issued">
+ <date-part name="year" suffix=", "/>
+ </date>
+ <group>
+ <text term="volume" form="short" suffix="."/>
+ <text variable="number-of-volumes" prefix=". " suffix="/"/>
+ <text variable="volume" suffix=","/>
+ </group>
+ <label variable="page" form="short"/>
+ <group delimiter=", ">
+ <text variable="page"/>
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="article-journal" match="any">
+ <group delimiter=" " font-style="normal">
+ <label variable="page" form="short"/>
+ <group delimiter=", ">
+ <text variable="page"/>
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="article-newspaper article-magazine" match="any">
+ <group delimiter=" " font-style="normal">
+ <date variable="issued" form="numeric">
+ <date-part name="day"/>
+ <date-part name="month"/>
+ <date-part name="year"/>
+ </date>
+ <group delimiter=" " font-style="normal">
+ <choose>
+ <if variable="locator" match="any">
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else-if variable="locator" match="none">
+ <label variable="page" form="short"/>
+ </else-if>
+ </choose>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="webpage" match="any">
+ <group delimiter=" " font-style="normal">
+ <text value="consulté le" suffix=" " prefix=" "/>
+ <date variable="accessed" form="text">
+ <date-part name="day"/>
+ <date-part name="month"/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if type="bill book graphic legal_case motion_picture report song chapter paper-conference" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" text-case="capitalize-first" suffix="."/>
+ </else>
+ </choose>
+ </if>
+ <else-if type="article-journal article-magazine" match="any">
+ <group font-style="normal">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ <text macro="volume" prefix=", "/>
+ </if>
+ <else>
+ <text macro="volume" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </group>
+ </else-if>
+ </choose>
+ <text macro="issue" prefix=", "/>
+ </macro>
+ <macro name="volume">
+ <choose>
+ <if is-numeric="volume">
+ <text term="volume" form="short" suffix=".&#160;"/>
+ <text variable="volume"/>
+ </if>
+ <else>
+ <text variable="volume"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue">
+ <choose>
+ <if is-numeric="issue">
+ <text term="issue" form="short" suffix="&#160;"/>
+ <text variable="issue"/>
+ </if>
+ <else>
+ <text variable="issue"/>
+ </else>
+ </choose>
+ </macro>
+ <citation>
+ <layout suffix="." delimiter="&#160;; ">
+ <choose>
+ <if position="ibid-with-locator">
+ <group delimiter=", ">
+ <text term="ibid" text-case="capitalize-first" font-style="italic" suffix="."/>
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </group>
+ </if>
+ <else-if position="ibid">
+ <text term="ibid" text-case="capitalize-first" font-style="italic"/>
+ </else-if>
+ <else-if position="subsequent">
+ <group delimiter=", ">
+ <text macro="author-short"/>
+ <choose>
+ <if type="bill book graphic legal_case motion_picture report song thesis" match="any">
+ <text variable="title" form="short" font-style="italic"/>
+ </if>
+ <else>
+ <text variable="title" text-case="capitalize-first" form="short" quotes="true" font-style="normal"/>
+ </else>
+ </choose>
+ <text term="cited" font-style="italic" suffix="."/>
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </group>
+ </else-if>
+ <else>
+ <group delimiter=", ">
+ <text macro="author"/>
+ <text macro="title"/>
+ <text macro="translator"/>
+ <text macro="edition"/>
+ <text macro="pub-place"/>
+ <text macro="publisher"/>
+ <text macro="yearpage"/>
+ </group>
+ </else>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography>
+ <sort>
+ <key macro="author" names-min="3" names-use-first="3"/>
+ <key variable="issued" sort="descending"/>
+ </sort>
+ <layout suffix=".">
+ <group delimiter=", ">
+ <text macro="author"/>
+ <text macro="title"/>
+ <text macro="translator"/>
+ <text macro="edition"/>
+ <text macro="pub-place"/>
+ <text macro="publisher"/>
+ <text macro="yearpage"/>
+ </group>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/apa.csl b/test/command/apa.csl
new file mode 100644
index 000000000..999f8bf7f
--- /dev/null
+++ b/test/command/apa.csl
@@ -0,0 +1,474 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="never">
+ <!-- This style was edited with the Visual CSL Editor (http://steveridout.com/csl/visualEditor/) -->
+ <info>
+ <title>American Psychological Association 6th edition</title>
+ <title-short>APA</title-short>
+ <id>http://www.zotero.org/styles/apa</id>
+ <link href="http://www.zotero.org/styles/apa" rel="self"/>
+ <link href="http://owl.english.purdue.edu/owl/resource/560/01/" rel="documentation"/>
+ <author>
+ <name>Simon Kornblith</name>
+ <email>simon@simonster.com</email>
+ </author>
+ <contributor>
+ <name>Bruce D'Arcus</name>
+ </contributor>
+ <contributor>
+ <name>Curtis M. Humphrey</name>
+ </contributor>
+ <contributor>
+ <name>Richard Karnesky</name>
+ <email>karnesky+zotero@gmail.com</email>
+ <uri>http://arc.nucapt.northwestern.edu/Richard_Karnesky</uri>
+ </contributor>
+ <contributor>
+ <name>Sebastian Karcher</name>
+ </contributor>
+ <category citation-format="author-date"/>
+ <category field="psychology"/>
+ <category field="generic-base"/>
+ <updated>2014-04-12T01:20:52+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en">
+ <terms>
+ <term name="editortranslator" form="short">
+ <single>ed. &amp; trans.</single>
+ <multiple>eds. &amp; trans.</multiple>
+ </term>
+ <term name="translator" form="short">
+ <single>trans.</single>
+ <multiple>trans.</multiple>
+ </term>
+ </terms>
+ </locale>
+ <macro name="container-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <names variable="editor translator container-author" delimiter=", " suffix=", ">
+ <name and="symbol" initialize-with=". " delimiter=", "/>
+ <label form="short" prefix=" (" text-case="title" suffix=")"/>
+ </names>
+ </if>
+ </choose>
+ </macro>
+ <macro name="secondary-contributors">
+ <choose>
+ <if type="article-journal chapter paper-conference" match="none">
+ <names variable="translator editor container-author" delimiter=", " prefix=" (" suffix=")">
+ <name and="symbol" initialize-with=". " delimiter=", "/>
+ <label form="short" prefix=", " text-case="title"/>
+ </names>
+ </if>
+ </choose>
+ </macro>
+ <macro name="author">
+ <names variable="author">
+ <name name-as-sort-order="all" and="symbol" sort-separator=", " initialize-with=". " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=" (" suffix=")" text-case="capitalize-first"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <choose>
+ <if type="report">
+ <text variable="publisher"/>
+ <text macro="title"/>
+ </if>
+ <else>
+ <text macro="title"/>
+ </else>
+ </choose>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="author-short">
+ <names variable="author">
+ <name form="short" and="symbol" delimiter=", " initialize-with=". "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <choose>
+ <if type="report">
+ <text variable="publisher"/>
+ <text variable="title" form="short" font-style="italic"/>
+ </if>
+ <else-if type="legal_case">
+ <text variable="title" font-style="italic"/>
+ </else-if>
+ <else-if type="bill book graphic legislation motion_picture song" match="any">
+ <text variable="title" form="short" font-style="italic"/>
+ </else-if>
+ <else>
+ <text variable="title" form="short" quotes="true"/>
+ </else>
+ </choose>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="access">
+ <choose>
+ <if type="thesis">
+ <choose>
+ <if variable="archive" match="any">
+ <group>
+ <text term="retrieved" text-case="capitalize-first" suffix=" "/>
+ <text term="from" suffix=" "/>
+ <text variable="archive" suffix="."/>
+ <text variable="archive_location" prefix=" (" suffix=")"/>
+ </group>
+ </if>
+ <else>
+ <group>
+ <text term="retrieved" text-case="capitalize-first" suffix=" "/>
+ <text term="from" suffix=" "/>
+ <text variable="URL"/>
+ </group>
+ </else>
+ </choose>
+ </if>
+ <else>
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else>
+ <choose>
+ <if type="webpage">
+ <group delimiter=" ">
+ <text term="retrieved" text-case="capitalize-first" suffix=" "/>
+ <group>
+ <date variable="accessed" form="text" suffix=", "/>
+ </group>
+ <text term="from"/>
+ <text variable="URL"/>
+ </group>
+ </if>
+ <else>
+ <group>
+ <text term="retrieved" text-case="capitalize-first" suffix=" "/>
+ <text term="from" suffix=" "/>
+ <text variable="URL"/>
+ </group>
+ </else>
+ </choose>
+ </else>
+ </choose>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="report thesis" match="any">
+ <text variable="title" font-style="italic"/>
+ <group prefix=" (" suffix=")" delimiter=" ">
+ <text variable="genre"/>
+ <text variable="number" prefix="No. "/>
+ </group>
+ </if>
+ <else-if type="book graphic motion_picture report song manuscript speech" match="any">
+ <!---This is a hack until we have a computer program type -->
+ <choose>
+ <if variable="version">
+ <group delimiter=" ">
+ <text variable="title"/>
+ <group delimiter=" " prefix="(" suffix=")">
+ <text term="version" text-case="capitalize-first"/>
+ <text variable="version"/>
+ </group>
+ </group>
+ </if>
+ <else>
+ <text variable="title" font-style="italic"/>
+ </else>
+ </choose>
+ </else-if>
+ <else>
+ <text variable="title"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if type="report" match="any">
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </if>
+ <else-if type="thesis" match="any">
+ <group delimiter=", ">
+ <text variable="publisher"/>
+ <text variable="publisher-place"/>
+ </group>
+ </else-if>
+ <else>
+ <group delimiter=", ">
+ <choose>
+ <if variable="event" match="none">
+ <text variable="genre"/>
+ </if>
+ </choose>
+ <choose>
+ <if type="article-journal article-magazine" match="none">
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </if>
+ </choose>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="event">
+ <choose>
+ <if variable="container-title" match="none">
+ <choose>
+ <if variable="event">
+ <choose>
+ <if variable="genre" match="none">
+ <text term="presented at" text-case="capitalize-first" suffix=" "/>
+ <text variable="event"/>
+ </if>
+ <else>
+ <group delimiter=" ">
+ <text variable="genre" text-case="capitalize-first"/>
+ <text term="presented at"/>
+ <text variable="event"/>
+ </group>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issued">
+ <choose>
+ <if type="bill legal_case legislation" match="none">
+ <choose>
+ <if variable="issued">
+ <group prefix=" (" suffix=")">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ <text variable="year-suffix"/>
+ <choose>
+ <if type="article-journal bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="none">
+ <date variable="issued">
+ <date-part prefix=", " name="month"/>
+ <date-part prefix=" " name="day"/>
+ </date>
+ </if>
+ </choose>
+ </group>
+ </if>
+ <else>
+ <group prefix=" (" suffix=")">
+ <text term="no date" form="short"/>
+ <text variable="year-suffix" prefix="-"/>
+ </group>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issued-sort">
+ <choose>
+ <if type="article-journal bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="none">
+ <date variable="issued">
+ <date-part name="year"/>
+ <date-part name="month"/>
+ <date-part name="day"/>
+ </date>
+ </if>
+ <else>
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issued-year">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ <text variable="year-suffix"/>
+ </if>
+ <else>
+ <text term="no date" form="short"/>
+ <text variable="year-suffix" prefix="-"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" suffix="."/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="locators">
+ <choose>
+ <if type="article-journal article-magazine" match="any">
+ <group prefix=", " delimiter=", ">
+ <group>
+ <text variable="volume" font-style="italic"/>
+ <text variable="issue" prefix="(" suffix=")"/>
+ </group>
+ <text variable="page"/>
+ </group>
+ </if>
+ <else-if type="article-newspaper">
+ <group delimiter=" " prefix=", ">
+ <label variable="page" form="short"/>
+ <text variable="page"/>
+ </group>
+ </else-if>
+ <else-if type="book graphic motion_picture report song chapter paper-conference" match="any">
+ <group prefix=" (" suffix=")" delimiter=", ">
+ <text macro="edition"/>
+ <group>
+ <text term="volume" form="short" plural="true" text-case="capitalize-first" suffix=" "/>
+ <number variable="number-of-volumes" form="numeric" prefix="1-"/>
+ </group>
+ <group>
+ <text term="volume" form="short" text-case="capitalize-first" suffix=" "/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <group>
+ <label variable="page" form="short" suffix=" "/>
+ <text variable="page"/>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="legal_case">
+ <group prefix=" (" suffix=")" delimiter=" ">
+ <text variable="authority"/>
+ <date variable="issued" form="text"/>
+ </group>
+ </else-if>
+ <else-if type="bill legislation" match="any">
+ <date variable="issued" prefix=" (" suffix=")">
+ <date-part name="year"/>
+ </date>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="citation-locator">
+ <group>
+ <choose>
+ <if locator="chapter">
+ <label variable="locator" form="long" text-case="capitalize-first"/>
+ </if>
+ <else>
+ <label variable="locator" form="short"/>
+ </else>
+ </choose>
+ <text variable="locator" prefix=" "/>
+ </group>
+ </macro>
+ <macro name="container">
+ <group>
+ <choose>
+ <if type="chapter paper-conference entry-encyclopedia" match="any">
+ <text term="in" text-case="capitalize-first" suffix=" "/>
+ </if>
+ </choose>
+ <text macro="container-contributors"/>
+ <text macro="secondary-contributors"/>
+ <text macro="container-title"/>
+ </group>
+ </macro>
+ <macro name="container-title">
+ <choose>
+ <if type="article article-journal article-magazine article-newspaper" match="any">
+ <text variable="container-title" font-style="italic" text-case="title"/>
+ </if>
+ <else-if type="bill legal_case legislation" match="none">
+ <text variable="container-title" font-style="italic"/>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="legal-cites">
+ <choose>
+ <if type="bill legal_case legislation" match="any">
+ <group delimiter=" " prefix=", ">
+ <choose>
+ <if variable="container-title">
+ <text variable="volume"/>
+ <text variable="container-title"/>
+ <group delimiter=" ">
+ <!--change to label variable="section" as that becomes available -->
+ <text term="section" form="symbol"/>
+ <text variable="section"/>
+ </group>
+ <text variable="page"/>
+ </if>
+ <else>
+ <choose>
+ <if type="legal_case">
+ <text variable="number" prefix="No. "/>
+ </if>
+ <else>
+ <text variable="number" prefix="Pub. L. No. "/>
+ <group delimiter=" ">
+ <!--change to label variable="section" as that becomes available -->
+ <text term="section" form="symbol"/>
+ <text variable="section"/>
+ </group>
+ </else>
+ </choose>
+ </else>
+ </choose>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <citation et-al-min="6" et-al-use-first="1" et-al-subsequent-min="3" et-al-subsequent-use-first="1" disambiguate-add-year-suffix="true" disambiguate-add-names="true" disambiguate-add-givenname="true" collapse="year" givenname-disambiguation-rule="primary-name">
+ <sort>
+ <key macro="author"/>
+ <key macro="issued-sort"/>
+ </sort>
+ <layout prefix="(" suffix=")" delimiter="; ">
+ <group delimiter=", ">
+ <text macro="author-short"/>
+ <text macro="issued-year"/>
+ <text macro="citation-locator"/>
+ </group>
+ </layout>
+ </citation>
+ <bibliography hanging-indent="true" et-al-min="8" et-al-use-first="6" et-al-use-last="true" entry-spacing="0" line-spacing="2">
+ <sort>
+ <key macro="author"/>
+ <key macro="issued-sort" sort="ascending"/>
+ <key macro="title"/>
+ </sort>
+ <layout>
+ <group suffix=".">
+ <group delimiter=". ">
+ <text macro="author"/>
+ <text macro="issued"/>
+ <text macro="title" prefix=" "/>
+ <text macro="container"/>
+ </group>
+ <text macro="legal-cites"/>
+ <text macro="locators"/>
+ <group delimiter=", " prefix=". ">
+ <text macro="event"/>
+ <text macro="publisher"/>
+ </group>
+ </group>
+ <text macro="access" prefix=" "/>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/archeologie-medievale.csl b/test/command/archeologie-medievale.csl
new file mode 100644
index 000000000..1ac70696e
--- /dev/null
+++ b/test/command/archeologie-medievale.csl
@@ -0,0 +1,291 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" version="1.0" class="note" demote-non-dropping-particle="display-and-sort" default-locale="fr-FR" page-range-format="expanded">
+ <info>
+ <title>Archéologie médiévale (French)</title>
+ <id>http://www.zotero.org/styles/archeologie-medievale</id>
+ <link href="http://www.zotero.org/styles/archeologie-medievale" rel="self"/>
+ <link href="http://www.unicaen.fr/crahm/archeomed/spip.php?article80" rel="documentation"/>
+ <author>
+ <name>Nicolas Monteix</name>
+ <email>nicolas.monteix@univ-rouen.fr</email>
+ </author>
+ <category citation-format="note"/>
+ <category field="history"/>
+ <category field="anthropology"/>
+ <issn>0153-9337</issn>
+ <summary>Style auteur-date en note pour Archéologie médiévale. NB: les sources éditées doivent être considérées comme des livres ayant un auteur (médiéval) et un éditeur (contemporain). Pour les sources éditées ne disposant pas d'auteur (médiéval), il est nécessaire de transformer le (dir.) en (éd.). Pour les archives (type=manuscrit), le "lieu" correspond au dépôt d'archives, l' "archive" au fonds, la "loc. dans l'archive" à la cote.</summary>
+ <updated>2014-08-17T23:30:36+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="fr">
+ <terms>
+ <term name="editor" form="short">dir.</term>
+ <term name="in">dans</term>
+ <term name="anonymous">anonyme</term>
+ <term name="anonymous" form="short">anon.</term>
+ <term name="accessed">consulté le</term>
+ <term name="no date">sans date</term>
+ <term name="no date" form="short">s.&#160;d.</term>
+ </terms>
+ </locale>
+ <macro name="author">
+ <names variable="author" delimiter=" ">
+ <name name-as-sort-order="all" font-variant="small-caps" sort-separator=" " initialize-with="." delimiter-precedes-last="never" and="text" delimiter=", "/>
+ <substitute>
+ <text macro="editor"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <name name-as-sort-order="all" font-variant="small-caps" sort-separator=" " initialize-with="." delimiter-precedes-last="never" and="text" delimiter=", "/>
+ <label form="short" font-variant="normal" text-case="lowercase" prefix=" (" suffix=")"/>
+ </names>
+ </macro>
+ <macro name="pages">
+ <group>
+ <text variable="page" prefix="p.&#160;"/>
+ </group>
+ </macro>
+ <macro name="author-short">
+ <names variable="author">
+ <name form="short" delimiter-precedes-last="never" and="text" delimiter=", "/>
+ <et-al font-variant="normal" font-style="italic"/>
+ <substitute>
+ <text macro="editor-short"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="editor-short">
+ <names variable="editor">
+ <name form="short" delimiter-precedes-last="never" and="text" delimiter=", "/>
+ <et-al font-variant="normal" font-style="italic"/>
+ </names>
+ </macro>
+ <macro name="URLaccess">
+ <group prefix="(" suffix=")">
+ <text variable="URL"/>
+ <text macro="access"/>
+ </group>
+ </macro>
+ <macro name="access">
+ <group prefix=" [" suffix="]">
+ <text term="accessed" suffix=" "/>
+ <date variable="accessed">
+ <date-part name="day" suffix=" "/>
+ <date-part name="month" suffix=" "/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </macro>
+ <macro name="editor-text">
+ <group>
+ <names variable="editor" suffix=" (éd.), ">
+ <name name-as-sort-order="all" font-variant="small-caps" sort-separator=" " initialize-with="." delimiter-precedes-last="never" and="text" delimiter=", "/>
+ </names>
+ <text macro="publisher" suffix=", "/>
+ <text macro="year-date"/>
+ </group>
+ </macro>
+ <macro name="editor-text-short">
+ <group>
+ <names variable="editor" suffix=" (éd.), ">
+ <name name-as-sort-order="all" form="short" font-variant="small-caps" delimiter-precedes-last="never" and="text" delimiter=", "/>
+ </names>
+ <text macro="year-date"/>
+ </group>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="book" match="any">
+ <text variable="title" font-style="italic"/>
+ </if>
+ <else-if type="webpage" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else-if variable="container-title" match="none">
+ <text variable="title" font-style="italic"/>
+ </else-if>
+ <else>
+ <text variable="title"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <group delimiter=", ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </macro>
+ <macro name="year-date">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else>
+ <text term="no date" form="short"/>
+ </else>
+ </choose>
+ <choose>
+ <if is-numeric="edition">
+ <group vertical-align="sup">
+ <number variable="edition"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="type-sorting">
+ <choose>
+ <if type="book" variable="editor author" match="all">
+ <text value="1"/>
+ </if>
+ <else-if type="manuscript">
+ <text value="2"/>
+ </else-if>
+ <else>
+ <text value="3"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="locator">
+ <choose>
+ <if locator="paragraph">
+ <text variable="locator" prefix=", § "/>
+ </if>
+ <else-if locator="folio">
+ <text variable="locator" prefix=",&#160;fol.&#160;"/>
+ </else-if>
+ <else>
+ <group prefix=",&#160;">
+ <label variable="locator" form="short" suffix=".&#160;"/>
+ <text variable="locator"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="3" delimiter-precedes-et-al="never" disambiguate-add-year-suffix="true">
+ <sort>
+ <key variable="issued"/>
+ </sort>
+ <layout delimiter="&#160;; ">
+ <choose>
+ <if position="ibid-with-locator">
+ <group>
+ <text term="ibid" text-case="capitalize-first" font-style="italic"/>
+ <text macro="locator"/>
+ </group>
+ </if>
+ <else-if position="ibid">
+ <text term="ibid" text-case="capitalize-first" font-style="italic"/>
+ </else-if>
+ <else-if type="book" variable="editor author" match="all">
+ <group suffix=".">
+ <text macro="author-short" font-variant="small-caps" suffix=", "/>
+ <text macro="title" suffix=", "/>
+ <text macro="editor-text-short"/>
+ <text macro="locator"/>
+ </group>
+ </else-if>
+ <else-if type="manuscript">
+ <group delimiter=", ">
+ <text variable="publisher-place"/>
+ <text variable="archive_location"/>
+ <text macro="locator"/>
+ </group>
+ </else-if>
+ <else>
+ <text macro="author-short" suffix="&#160;" font-variant="small-caps"/>
+ <text macro="year-date"/>
+ <text macro="locator"/>
+ </else>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography subsequent-author-substitute="">
+ <sort>
+ <key macro="type-sorting"/>
+ <key macro="author"/>
+ <key variable="issued"/>
+ <key variable="title"/>
+ </sort>
+ <layout suffix=".">
+ <choose>
+ <if type="book" variable="editor author" match="all">
+ <group suffix=".">
+ <text macro="author" suffix=", "/>
+ <text macro="title" suffix=", "/>
+ <text macro="editor-text"/>
+ </group>
+ </if>
+ <else-if type="manuscript">
+ <group delimiter=", ">
+ <text variable="archive_location"/>
+ <text variable="archive"/>
+ <text variable="title" font-style="italic"/>
+ </group>
+ <group prefix=" (" suffix=")">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </group>
+ </else-if>
+ <else>
+ <group display="block">
+ <text macro="author" suffix="&#9;"/>
+ </group>
+ <group display="left-margin">
+ <text macro="year-date" suffix=", "/>
+ <choose>
+ <if type="thesis">
+ <group delimiter=", " suffix=".">
+ <text macro="title" font-style="italic"/>
+ <text variable="genre"/>
+ <text variable="publisher"/>
+ <text variable="publisher-place"/>
+ </group>
+ </if>
+ <else-if type="webpage">
+ <group delimiter=" ">
+ <text macro="title" font-style="italic"/>
+ <text macro="URLaccess"/>
+ </group>
+ </else-if>
+ <else-if type="article-journal article-magazine article-newspaper broadcast personal_communication thesis entry-dictionary entry-encyclopedia" match="any">
+ <group delimiter=", " suffix=".">
+ <text macro="title" quotes="true"/>
+ <text variable="container-title" font-style="italic"/>
+ <text variable="volume"/>
+ <text variable="issue"/>
+ <text macro="pages"/>
+ </group>
+ </else-if>
+ <else-if type="book graphic" match="any">
+ <group suffix=".">
+ <text macro="title" suffix=", "/>
+ <text macro="publisher"/>
+ </group>
+ </else-if>
+ <else-if type="chapter paper-conference" match="any">
+ <text macro="title" quotes="true" suffix=", "/>
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text term="in"/>
+ <text macro="editor"/>
+ </group>
+ <text variable="container-title" font-style="italic"/>
+ <text macro="publisher"/>
+ <text macro="pages"/>
+ </group>
+ </else-if>
+ </choose>
+ </group>
+ </else>
+ </choose>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/biblatex-266.md b/test/command/biblatex-266.md
new file mode 100644
index 000000000..24de45d95
--- /dev/null
+++ b/test/command/biblatex-266.md
@@ -0,0 +1,34 @@
+```
+% pandoc -f biblatex -t markdown -s
+@book{goethe2005,
+ langid = {german},
+ location = {{Frankfurt am Main}},
+ title = {Not A Real Book},
+ date = {2005},
+ author = {family=Goethe, given=Johann Wolfgang, prefix=von, useprefix=false and given=Antonie, prefix=van, family=Leeuwenhoek, useprefix=true}, editor = {Schöne, Albrecht}
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - dropping-particle: von
+ family: Goethe
+ given: Johann Wolfgang
+ - family: Leeuwenhoek
+ given: Antonie
+ non-dropping-particle: van
+ editor:
+ - family: Schöne
+ given: Albrecht
+ id: goethe2005
+ issued: 2005
+ language: 'de-DE'
+ publisher-place: Frankfurt am Main
+ title: Not A Real Book
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-aksin.md b/test/command/biblatex-aksin.md
new file mode 100644
index 000000000..48b757025
--- /dev/null
+++ b/test/command/biblatex-aksin.md
@@ -0,0 +1,78 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Aksin et al. 2006)
+
+Aksin, Özge, Hayati Türkmen, Levent Artok, Bekir Çetinkaya, Chaoying Ni,
+Orhan Büyükgüngör, and Erhan Özkal. 2006. “Effect of Immobilization on
+Catalytic Characteristics of Saturated Pd-N-heterocyclic Carbenes in
+Mizoroki-Heck Reactions.” *J. Organomet. Chem.* 691 (13): 3027–3036.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Aksin et al., 2006)
+
+Aksin, Ö., Türkmen, H., Artok, L., Çetinkaya, B., Ni, C., Büyükgüngör,
+O., & Özkal, E. (2006). Effect of immobilization on catalytic
+characteristics of saturated Pd-N-heterocyclic carbenes in Mizoroki-Heck
+reactions. *J. Organomet. Chem.*, *691*(13), 3027–3036.
+
+
+}
+
+@string{ jomch = {J.~Organomet. Chem.} }
+
+@Article{aksin,
+ author = {Aks{\i}n, {\"O}zge and T{\"u}rkmen, Hayati and Artok, Levent
+ and {\c{C}}etinkaya, Bekir and Ni, Chaoying and
+ B{\"u}y{\"u}kg{\"u}ng{\"o}r, Orhan and {\"O}zkal, Erhan},
+ title = {Effect of immobilization on catalytic characteristics of
+ saturated {Pd-N}-heterocyclic carbenes in {Mizoroki-Heck}
+ reactions},
+ journaltitle = jomch,
+ date = 2006,
+ volume = 691,
+ number = 13,
+ pages = {3027-3036},
+ indextitle = {Effect of immobilization on catalytic characteristics},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Aksın
+ given: Özge
+ - family: Türkmen
+ given: Hayati
+ - family: Artok
+ given: Levent
+ - family: Çetinkaya
+ given: Bekir
+ - family: Ni
+ given: Chaoying
+ - family: Büyükgüngör
+ given: Orhan
+ - family: Özkal
+ given: Erhan
+ container-title: J. Organomet. Chem.
+ id: aksin
+ issue: 13
+ issued: 2006
+ page: '3027-3036'
+ title: 'Effect of immobilization on catalytic characteristics of
+ saturated Pd-N-heterocyclic carbenes in Mizoroki-Heck reactions'
+ type: 'article-journal'
+ volume: 691
+---
+
+
+```
diff --git a/test/command/biblatex-almendro.md b/test/command/biblatex-almendro.md
new file mode 100644
index 000000000..9706a1baf
--- /dev/null
+++ b/test/command/biblatex-almendro.md
@@ -0,0 +1,71 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Almendro et al. 1998)
+
+Almendro, José L., Jacinto Martín, Alberto Sánchez, and Fernando Nozal.
+1998. “Elektromagnetisches Signalhorn.”
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Almendro, Martín, Sánchez, & Nozal, 1998)
+
+Almendro, J. L., Martín, J., Sánchez, A., & Nozal, F. (1998).
+Elektromagnetisches Signalhorn.
+
+
+NOTES:
+
+- CSL styles’ handling of patent items needs to be improved
+
+}
+
+@Patent{almendro,
+ author = {Almendro, Jos{\'e} L. and Mart{\'i}n, Jacinto and S{\'a}nchez,
+ Alberto and Nozal, Fernando},
+ title = {Elektromagnetisches Signalhorn},
+ number = {EU-29702195U},
+ date = 1998,
+ location = {countryfr and countryuk and countryde},
+ hyphenation = {german},
+ annotation = {This is a patent entry with a location
+ field. The number is given in the number field. Note
+ the format of the location field in the database
+ file. Compare laufenberg, sorace, and
+ kowalik},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'This is a patent entry with a location field. The number is
+ given in the number field. Note the format of the location field in
+ the database file. Compare laufenberg, sorace, and kowalik'
+ author:
+ - family: Almendro
+ given: José L.
+ - family: Martín
+ given: Jacinto
+ - family: Sánchez
+ given: Alberto
+ - family: Nozal
+ given: Fernando
+ id: almendro
+ issued: 1998
+ jurisdiction: France; United Kingdom; Germany
+ language: 'de-DE'
+ number: 'EU-29702195U'
+ title: Elektromagnetisches Signalhorn
+ type: patent
+---
+
+
+```
diff --git a/test/command/biblatex-angenendt.md b/test/command/biblatex-angenendt.md
new file mode 100644
index 000000000..c800ff3e6
--- /dev/null
+++ b/test/command/biblatex-angenendt.md
@@ -0,0 +1,66 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Angenendt 2002)
+
+Angenendt, Arnold. 2002. “In Honore Salvatoris – Vom Sinn und Unsinn der
+Patrozinienkunde.” *Revue d’Histoire Ecclésiastique* 97: 431–456,
+791–823.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Angenendt, 2002)
+
+Angenendt, A. (2002). In Honore Salvatoris – Vom Sinn und Unsinn der
+Patrozinienkunde. *Revue d’Histoire Ecclésiastique*, *97*, 431–456,
+791–823.
+
+
+}
+
+@Article{angenendt,
+ author = {Angenendt, Arnold},
+ title = {In Honore Salvatoris~-- Vom Sinn und Unsinn der
+ Patrozinienkunde},
+ journaltitle = {Revue d'Histoire Eccl{\'e}siastique},
+ date = 2002,
+ volume = 97,
+ pages = {431--456, 791--823},
+ hyphenation = {german},
+ indextitle = {In Honore Salvatoris},
+ shorttitle = {In Honore Salvatoris},
+ annotation = {A German article in a French journal. Apart from that, a
+ typical article entry. Note the indextitle
+ field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A German article in a French journal. Apart from that, a
+ typical article entry. Note the indextitle field'
+ author:
+ - family: Angenendt
+ given: Arnold
+ container-title: 'Revue d''Histoire Ecclésiastique'
+ id: angenendt
+ issued: 2002
+ language: 'de-DE'
+ page: '431-456, 791-823'
+ title: 'In Honore Salvatoris -- Vom Sinn und Unsinn der
+ Patrozinienkunde'
+ title-short: In Honore Salvatoris
+ type: 'article-journal'
+ volume: 97
+---
+
+
+```
diff --git a/test/command/biblatex-aristotle-anima.md b/test/command/biblatex-aristotle-anima.md
new file mode 100644
index 000000000..88b888149
--- /dev/null
+++ b/test/command/biblatex-aristotle-anima.md
@@ -0,0 +1,62 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Aristotle 1907)
+
+Aristotle. 1907. *De Anima*. Edited by Robert Drew Hicks. Cambridge:
+Cambridge University Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Aristotle, 1907)
+
+Aristotle. (1907). *De anima*. (R. D. Hicks, Ed.). Cambridge: Cambridge
+University Press.
+
+
+}
+
+@string{ cup = {Cambridge University Press} }
+
+@Book{aristotle:anima,
+ author = {Aristotle},
+ title = {De Anima},
+ date = 1907,
+ editor = {Hicks, Robert Drew},
+ publisher = cup,
+ location = {Cambridge},
+ keywords = {primary},
+ hyphenation = {british},
+ annotation = {A book entry with an author and an
+ editor},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry with an author and an editor
+ author:
+ - family: Aristotle
+ editor:
+ - family: Hicks
+ given: Robert Drew
+ id: 'aristotle:anima'
+ issued: 1907
+ keyword: primary
+ language: 'en-GB'
+ publisher: Cambridge University Press
+ publisher-place: Cambridge
+ title: De anima
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-aristotle-physics.md b/test/command/biblatex-aristotle-physics.md
new file mode 100644
index 000000000..5d0009b17
--- /dev/null
+++ b/test/command/biblatex-aristotle-physics.md
@@ -0,0 +1,63 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Aristotle 1929)
+
+Aristotle. 1929. *Physics*. Translated by P. H. Wicksteed and F. M.
+Cornford. New York: G. P. Putnam.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Aristotle, 1929)
+
+Aristotle. (1929). *Physics*. (P. H. Wicksteed & F. M. Cornford,
+Trans.). New York: G. P. Putnam.
+
+
+}
+
+@Book{aristotle:physics,
+ author = {Aristotle},
+ title = {Physics},
+ date = 1929,
+ translator = {Wicksteed, P. H. and Cornford, F. M.},
+ publisher = {G. P. Putnam},
+ location = {New York},
+ keywords = {primary},
+ hyphenation = {american},
+ shorttitle = {Physics},
+ annotation = {A book entry with a translator field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry with a translator field
+ author:
+ - family: Aristotle
+ id: 'aristotle:physics'
+ issued: 1929
+ keyword: primary
+ language: 'en-US'
+ publisher: G. P. Putnam
+ publisher-place: New York
+ title: Physics
+ title-short: Physics
+ translator:
+ - family: Wicksteed
+ given: P. H.
+ - family: Cornford
+ given: F. M.
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-aristotle-poetics.md b/test/command/biblatex-aristotle-poetics.md
new file mode 100644
index 000000000..ed8884a2b
--- /dev/null
+++ b/test/command/biblatex-aristotle-poetics.md
@@ -0,0 +1,65 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Aristotle 1968)
+
+Aristotle. 1968. *Poetics*. Edited by D. W. Lucas. Clarendon Aristotle.
+Oxford: Clarendon Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Aristotle, 1968)
+
+Aristotle. (1968). *Poetics*. (D. W. Lucas, Ed.). Oxford: Clarendon
+Press.
+
+
+}
+
+@Book{aristotle:poetics,
+ author = {Aristotle},
+ title = {Poetics},
+ date = 1968,
+ editor = {Lucas, D. W.},
+ series = {Clarendon {Aristotle}},
+ publisher = {Clarendon Press},
+ location = {Oxford},
+ keywords = {primary},
+ hyphenation = {british},
+ shorttitle = {Poetics},
+ annotation = {A book entry with an author and an
+ editor as well as a series field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry with an author and an editor as well as a series
+ field
+ author:
+ - family: Aristotle
+ collection-title: Clarendon Aristotle
+ editor:
+ - family: Lucas
+ given: D. W.
+ id: 'aristotle:poetics'
+ issued: 1968
+ keyword: primary
+ language: 'en-GB'
+ publisher: Clarendon Press
+ publisher-place: Oxford
+ title: Poetics
+ title-short: Poetics
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-aristotle-rhetoric.md b/test/command/biblatex-aristotle-rhetoric.md
new file mode 100644
index 000000000..34fe2c6a8
--- /dev/null
+++ b/test/command/biblatex-aristotle-rhetoric.md
@@ -0,0 +1,80 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Aristotle 1877)
+
+Aristotle. 1877. *The Rhetoric of Aristotle with a Commentary by the
+Late Edward Meredith Cope*. Edited by Edward Meredith Cope. 3. Cambridge
+University Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Aristotle, 1877)
+
+Aristotle. (1877). *The rhetoric of Aristotle with a commentary by the
+late Edward Meredith Cope*. (E. M. Cope, Ed.) (1-3). Cambridge
+University Press.
+
+
+NOTES:
+
+- biblio2yaml
+ - commentator has no counterpart in CSL
+
+}
+
+@string{ cup = {Cambridge University Press} }
+
+@Book{aristotle:rhetoric,
+ author = {Aristotle},
+ title = {The Rhetoric of {Aristotle} with a commentary by the late {Edward
+ Meredith Cope}},
+ date = 1877,
+ editor = {Cope, Edward Meredith},
+ commentator = {Cope, Edward Meredith},
+ volumes = 3,
+ publisher = cup,
+ keywords = {primary},
+ hyphenation = {british},
+ sorttitle = {Rhetoric of Aristotle},
+ indextitle = {Rhetoric of {Aristotle}, The},
+ shorttitle = {Rhetoric},
+ annotation = {A commented edition. Note the concatenation of the
+ editor and commentator fields as well as the
+ volumes, sorttitle, and indextitle
+ fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A commented edition. Note the concatenation of the editor and
+ commentator fields as well as the volumes, sorttitle, and indextitle
+ fields'
+ author:
+ - family: Aristotle
+ editor:
+ - family: Cope
+ given: Edward Meredith
+ id: 'aristotle:rhetoric'
+ issued: 1877
+ keyword: primary
+ language: 'en-GB'
+ number-of-volumes: 3
+ publisher: Cambridge University Press
+ title: The rhetoric of Aristotle with a commentary by the late Edward
+ Meredith Cope
+ title-short: Rhetoric
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-article.md b/test/command/biblatex-article.md
new file mode 100644
index 000000000..b54c45f5e
--- /dev/null
+++ b/test/command/biblatex-article.md
@@ -0,0 +1,128 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+ - contains:
+ - an article entry with just the required fields
+ - an article entry with required and all optional fields
+ - notes:
+ - year, month to be ignored if date is present
+ - journal to be ignored if journaltitle is present
+ - editortype, editoratype, editorbtype, editorctype, pubstate,
+series contain keys which, unless corresponding CSL terms exist, require
+locale-specific expansion
+ - limitations:
+ - annotator, commentator, eid, eprint, eprintclass, eprinttype,
+issuetitle, issuesubtitle, language, origlanguage have no matching
+counterparts in CSL
+ - for editor, editora, editorb, editorc (plus editortype,
+editoratype, editorbtype, editorctype) only a subset, editor and director,
+has matching counterparts in CSL
+ - kludges:
+ - note + addendum -> CSL note
+ - number + issue -> CSL issue
+ - handling of titleaddon
+ - handling of (journal) series
+ - done properly, this should be mapped to some CSL variable
+(version? edition? collection-number?), CSL styles would have to be adapted
+ - slightly better kludge would map integer to ordinal + "ser."
+("3" -> "3rd ser."); localization keys "newseries" -> "new ser.",
+"oldseries" -> "old ser."; and print all other values as is -- but still
+wouldn't fit all styles or locales.
+ }
+
+@article{article-req,
+ Author = {Author, Ann},
+ Date = {2013-07-29},
+ Hyphenation = {english},
+ Journaltitle = {The Journaltitle},
+ Title = {An Article Entry with Just the Required Fields}}
+
+@article{article-opt,
+ Addendum = {The Addendum},
+ Annotator = {Annotator, A.},
+ Author = {Author, Jr., Ann A.},
+ Commentator = {Commentator, C.},
+ Date = {2008-12-31},
+ Doi = {10.1086/520976},
+ Editor = {Editor, Edward},
+ Editora = {Editor, A.},
+ Editorb = {Editor, B.},
+ Editorc = {Editor, C.},
+ Eid = {eid},
+ Eprint = {eprint},
+ Eprintclass = {eprintclass},
+ Eprinttype = {eprinttype},
+ Hyphenation = {english},
+ Issn = {issn},
+ Issue = {issue},
+ Issuesubtitle = {The Issuesubtitle},
+ Issuetitle = {The Issuetitle},
+ Journalsubtitle = {The Journalsubtitle},
+ Journaltitle = {The Journaltitle},
+ Journal = {The Journal},
+ Language = {language},
+ Month = {08},
+ Year = {2007},
+ Note = {The Note},
+ Number = {number},
+ Origlanguage = {origlanguage},
+ Pages = {pages},
+ Pubstate = {inpress},
+ Series = {newseries},
+ Subtitle = {The Subtitle},
+ Title = {An Article Entry with the Required and All Optional Fields},
+ Titleaddon = {The Titleaddon},
+ Translator = {Translator, Ted},
+ Url = {http://foo.bar.baz/},
+ Urldate = {2013-07-29},
+ Version = {version},
+ Volume = {volume},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Author
+ given: Ann
+ container-title: The Journaltitle
+ id: 'article-req'
+ issued: '2013-07-29'
+ language: 'en-US'
+ title: An article entry with just the required fields
+ type: 'article-journal'
+- accessed: '2013-07-29'
+ author:
+ - family: Author
+ given: Ann A.
+ suffix: Jr.
+ collection-title: new series
+ container-title: 'The Journaltitle: The Journalsubtitle'
+ doi: 10.1086/520976
+ editor:
+ - family: Editor
+ given: Edward
+ id: 'article-opt'
+ issn: issn
+ issue: 'number, issue'
+ issued: '2008-12-31'
+ language: 'en-US'
+ note: The Note. The Addendum
+ page: pages
+ status: in press
+ title: 'An article entry with the required and all optional fields:
+ The subtitle. The titleaddon'
+ title-short: An article entry with the required and all optional
+ fields
+ translator:
+ - family: Translator
+ given: Ted
+ type: 'article-journal'
+ url: 'http://foo.bar.baz/'
+ version: version
+ volume: volume
+---
+
+
+```
diff --git a/test/command/biblatex-augustine.md b/test/command/biblatex-augustine.md
new file mode 100644
index 000000000..9bb48dd4b
--- /dev/null
+++ b/test/command/biblatex-augustine.md
@@ -0,0 +1,56 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Augustine 1995)
+
+Augustine, Robert L. 1995. *Heterogeneous Catalysis for the Synthetic
+Chemist*. New York: Marcel Dekker.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Augustine, 1995)
+
+Augustine, R. L. (1995). *Heterogeneous catalysis for the synthetic
+chemist*. New York: Marcel Dekker.
+
+
+}
+
+@Book{augustine,
+ author = {Augustine, Robert L.},
+ title = {Heterogeneous catalysis for the synthetic chemist},
+ date = 1995,
+ publisher = {Marcel Dekker},
+ location = {New York},
+ hyphenation = {american},
+ shorttitle = {Heterogeneous catalysis},
+ annotation = {A plain book entry},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A plain book entry
+ author:
+ - family: Augustine
+ given: Robert L.
+ id: augustine
+ issued: 1995
+ language: 'en-US'
+ publisher: Marcel Dekker
+ publisher-place: New York
+ title: Heterogeneous catalysis for the synthetic chemist
+ title-short: Heterogeneous catalysis
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-averroes-bland.md b/test/command/biblatex-averroes-bland.md
new file mode 100644
index 000000000..6c630a93f
--- /dev/null
+++ b/test/command/biblatex-averroes-bland.md
@@ -0,0 +1,85 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Averroes 1982)
+
+Averroes. 1982. *The Epistle on the Possibility of Conjunction with the
+Active Intellect by Ibn Rushd with the Commentary of Moses Narboni*.
+Kalman P. Bland. Moreshet: Studies in Jewish History, Literature and
+Thought 7. New York: Jewish Theological Seminary of America.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Averroes, 1982)
+
+Averroes. (1982). *The epistle on the possibility of conjunction with
+the active intellect by Ibn Rushd with the commentary of Moses Narboni*.
+(K. P. Bland). New York: Jewish Theological Seminary of America.
+
+
+NOTES:
+
+- citeproc
+ - term "edited and translated by" missing
+
+}
+
+@Book{averroes-bland,
+ author = {Averroes},
+ title = {The Epistle on the Possibility of Conjunction with the Active
+ Intellect by {Ibn Rushd} with the Commentary of {Moses Narboni}},
+ date = 1982,
+ editor = {Bland, Kalman P.},
+ translator = {Bland, Kalman P.},
+ series = {Moreshet: {Studies} in {Jewish} History, Literature and Thought},
+ number = 7,
+ publisher = {Jewish Theological Seminary of America},
+ location = {New York},
+ keywords = {primary},
+ hyphenation = {american},
+ indextitle = {Epistle on the Possibility of Conjunction, The},
+ shorttitle = {Possibility of Conjunction},
+ annotation = {A book entry with a series and a
+ number. Note the concatenation of the editor
+ and translator fields as well as the
+ indextitle field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry with a series and a number. Note the
+ concatenation of the editor and translator fields as well as the
+ indextitle field
+ author:
+ - family: Averroes
+ collection-number: 7
+ collection-title: 'Moreshet: Studies in Jewish history, literature and
+ thought'
+ editor:
+ - family: Bland
+ given: Kalman P.
+ id: 'averroes-bland'
+ issued: 1982
+ keyword: primary
+ language: 'en-US'
+ publisher: Jewish Theological Seminary of America
+ publisher-place: New York
+ title: The epistle on the possibility of conjunction with the active
+ intellect by Ibn Rushd with the commentary of Moses Narboni
+ title-short: Possibility of conjunction
+ translator:
+ - family: Bland
+ given: Kalman P.
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-averroes-hannes.md b/test/command/biblatex-averroes-hannes.md
new file mode 100644
index 000000000..d144dcc91
--- /dev/null
+++ b/test/command/biblatex-averroes-hannes.md
@@ -0,0 +1,84 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Averroes 1892)
+
+Averroes. 1892. *Des Averroës Abhandlung: “Über die Möglichkeit der
+Conjunktion” oder “Über den materiellen Intellekt”*. Ludwig Hannes.
+Halle an der Saale: C. A. Kaemmerer.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Averroes, 1892)
+
+Averroes. (1892). *Des Averroës Abhandlung: “Über die Möglichkeit der
+Conjunktion” oder “Über den materiellen Intellekt”*. (L. Hannes). Halle
+an der Saale: C. A. Kaemmerer.
+
+
+NOTES:
+
+- citeproc
+ - term "edited and translated by" missing
+
+}
+
+@Book{averroes-hannes,
+ author = {Averroes},
+ title = {Des Averro{\"e}s Abhandlung: \mkbibquote{{\"U}ber die
+ M{\"o}glichkeit der Conjunktion} oder \mkbibquote{{\"U}ber den
+ materiellen Intellekt}},
+ date = 1892,
+ editor = {Hannes, Ludwig},
+ translator = {Hannes, Ludwig},
+ annotator = {Hannes, Ludwig},
+ publisher = {C.~A. Kaemmerer},
+ location = {Halle an der Saale},
+ keywords = {primary},
+ hyphenation = {german},
+ sorttitle = {Uber die Moglichkeit der Conjunktion},
+ indexsorttitle= {Uber die Moglichkeit der Conjunktion},
+ indextitle = {{\"U}ber die M{\"o}glichkeit der Conjunktion},
+ shorttitle = {{\"U}ber die M{\"o}glichkeit der Conjunktion},
+ annotation = {An annotated edition. Note the concatenation of the
+ editor, translator, and annotator
+ fields. Also note the shorttitle,
+ indextitle, sorttitle, and
+ indexsorttitle fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An annotated edition. Note the concatenation of the editor,
+ translator, and annotator fields. Also note the shorttitle,
+ indextitle, sorttitle, and indexsorttitle fields'
+ author:
+ - family: Averroes
+ editor:
+ - family: Hannes
+ given: Ludwig
+ id: 'averroes-hannes'
+ issued: 1892
+ keyword: primary
+ language: 'de-DE'
+ publisher: C. A. Kaemmerer
+ publisher-place: Halle an der Saale
+ title: 'Des Averroës Abhandlung: "Über die Möglichkeit der
+ Conjunktion" oder "Über den materiellen Intellekt"'
+ title-short: Über die Möglichkeit der Conjunktion
+ translator:
+ - family: Hannes
+ given: Ludwig
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-averroes-hercz.md b/test/command/biblatex-averroes-hercz.md
new file mode 100644
index 000000000..bf9dbf3a4
--- /dev/null
+++ b/test/command/biblatex-averroes-hercz.md
@@ -0,0 +1,85 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Averroes 1869)
+
+Averroes. 1869. *Drei Abhandlungen über die Conjunction des separaten
+Intellects mit dem Menschen: Von Averroes (Vater und Sohn), aus dem
+Arabischen übersetzt von Samuel Ibn Tibbon*. J. Hercz. Berlin:
+S. Hermann.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Averroes, 1869)
+
+Averroes. (1869). *Drei Abhandlungen über die Conjunction des separaten
+Intellects mit dem Menschen: Von Averroes (Vater und Sohn), aus dem
+Arabischen übersetzt von Samuel Ibn Tibbon*. (J. Hercz). Berlin:
+S. Hermann.
+
+
+NOTES:
+
+- citeproc
+ - term "edited and translated by" missing
+
+}
+
+@Book{averroes-hercz,
+ author = {Averroes},
+ title = {Drei Abhandlungen {\"u}ber die Conjunction des separaten
+ Intellects mit dem Menschen},
+ date = 1869,
+ editor = {Hercz, J.},
+ translator = {Hercz, J.},
+ publisher = {S.~Hermann},
+ location = {Berlin},
+ keywords = {primary},
+ hyphenation = {german},
+ indexsorttitle= {Drei Abhandlungen uber die Conjunction},
+ indextitle = {Drei Abhandlungen {\"u}ber die Conjunction},
+ subtitle = {Von Averroes (Vater und Sohn), aus dem Arabischen
+ {\"u}bersetzt von Samuel Ibn Tibbon},
+ shorttitle = {Drei Abhandlungen},
+ annotation = {A book entry. Note the concatenation of the
+ editor and translator fields as well as the
+ indextitle and indexsorttitle fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry. Note the concatenation of the editor and
+ translator fields as well as the indextitle and indexsorttitle
+ fields
+ author:
+ - family: Averroes
+ editor:
+ - family: Hercz
+ given: J.
+ id: 'averroes-hercz'
+ issued: 1869
+ keyword: primary
+ language: 'de-DE'
+ publisher: S. Hermann
+ publisher-place: Berlin
+ title: 'Drei Abhandlungen über die Conjunction des separaten
+ Intellects mit dem Menschen: Von Averroes (Vater und Sohn), aus dem
+ Arabischen übersetzt von Samuel Ibn Tibbon'
+ title-short: Drei Abhandlungen
+ translator:
+ - family: Hercz
+ given: J.
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-baez-article.md b/test/command/biblatex-baez-article.md
new file mode 100644
index 000000000..bd7561dba
--- /dev/null
+++ b/test/command/biblatex-baez-article.md
@@ -0,0 +1,76 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Baez and Lauda 2004)
+
+Baez, John C., and Aaron D. Lauda. 2004. “Higher-dimensional Algebra V:
+2-groups” (version 3). *Theory and Applications of Categories* 12:
+423–491.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Baez & Lauda, 2004)
+
+Baez, J. C., & Lauda, A. D. (2004). Higher-dimensional algebra V:
+2-groups. *Theory and Applications of Categories*, *12*, 423–491.
+
+
+NOTES:
+
+- biblio2yaml
+ - eprint: see baez-online
+
+}
+
+@Article{baez-article,
+ author = {Baez, John C. and Lauda, Aaron D.},
+ title = {Higher-Dimensional Algebra {V}: 2-Groups},
+ journaltitle = {Theory and Applications of Categories},
+ date = 2004,
+ volume = 12,
+ pages = {423-491},
+ version = 3,
+ eprint = {math/0307200v3},
+ eprinttype = {arxiv},
+ hyphenation = {american},
+ annotation = {An article with eprint and
+ eprinttype fields. Note that the arXiv reference is
+ transformed into a clickable link if hyperref support
+ has been enabled. Compare baez\slash online, which
+ is the same item given as an online entry},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An article with eprint and eprinttype fields. Note that the
+ arXiv reference is transformed into a clickable link if hyperref
+ support has been enabled. Compare baez/online, which is the same
+ item given as an online entry'
+ author:
+ - family: Baez
+ given: John C.
+ - family: Lauda
+ given: Aaron D.
+ container-title: Theory and Applications of Categories
+ id: 'baez-article'
+ issued: 2004
+ language: 'en-US'
+ page: '423-491'
+ title: 'Higher-dimensional algebra V: 2-groups'
+ title-short: 'Higher-dimensional algebra V'
+ type: 'article-journal'
+ url: 'http://arxiv.org/abs/math/0307200v3'
+ version: 3
+ volume: 12
+---
+
+
+```
diff --git a/test/command/biblatex-baez-online.md b/test/command/biblatex-baez-online.md
new file mode 100644
index 000000000..b1cbf3e06
--- /dev/null
+++ b/test/command/biblatex-baez-online.md
@@ -0,0 +1,69 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Baez and Lauda 2004)
+
+Baez, John C., and Aaron D. Lauda. 2004. “Higher-dimensional Algebra V:
+2-groups” (version 3). October 27.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Baez & Lauda, 2004)
+
+Baez, J. C., & Lauda, A. D. (2004, October 27). Higher-dimensional
+algebra V: 2-groups.
+
+
+NOTES:
+
+- biblio2yaml:
+ - eprinttype = {arxiv}, eprint = {math/0307200v3},
+ should be converted to a url: http://arxiv.org/abs/math/0307200v3
+ (prefix http://arxiv.org/abs/ seems to work for all arxiv material)
+
+}
+
+@Online{baez-online,
+ author = {Baez, John C. and Lauda, Aaron D.},
+ title = {Higher-Dimensional Algebra {V}: 2-Groups},
+ date = {2004-10-27},
+ version = 3,
+ hyphenation = {american},
+ eprinttype = {arxiv},
+ eprint = {math/0307200v3},
+ annotation = {An online reference from arXiv. Note the
+ eprint and eprinttype fields. Compare
+ baez\slash article which is the same item given as an
+ article entry with eprint information},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: An online reference from arXiv. Note the eprint and eprinttype
+ fields. Compare baez/article which is the same item given as an
+ article entry with eprint information
+ author:
+ - family: Baez
+ given: John C.
+ - family: Lauda
+ given: Aaron D.
+ id: 'baez-online'
+ issued: '2004-10-27'
+ language: 'en-US'
+ title: 'Higher-dimensional algebra V: 2-groups'
+ title-short: 'Higher-dimensional algebra V'
+ type: webpage
+ url: 'http://arxiv.org/abs/math/0307200v3'
+ version: 3
+---
+
+
+```
diff --git a/test/command/biblatex-basic.md b/test/command/biblatex-basic.md
new file mode 100644
index 000000000..1110b0fb4
--- /dev/null
+++ b/test/command/biblatex-basic.md
@@ -0,0 +1,69 @@
+@Book{item1,
+author="John Doe",
+title="First Book",
+year="2005",
+address="Cambridge",
+publisher="Cambridge University Press"
+}
+
+@Article{item2,
+author="John Doe",
+title="Article",
+year="2006",
+journal="Journal of Generic Studies",
+volume="6",
+pages="33-34"
+}
+
+@InCollection{пункт3,
+author="John Doe and Jenny Roe",
+title="Why Water Is Wet",
+booktitle="Third Book",
+editor="Sam Smith",
+publisher="Oxford University Press",
+address="Oxford",
+year="2007"
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Doe
+ given: John
+ id: item1
+ issued: 2005
+ publisher: Cambridge University Press
+ publisher-place: Cambridge
+ title: First book
+ type: book
+- author:
+ - family: Doe
+ given: John
+ container-title: Journal of Generic Studies
+ id: item2
+ issued: 2006
+ page: '33-34'
+ title: Article
+ type: 'article-journal'
+ volume: 6
+- author:
+ - family: Doe
+ given: John
+ - family: Roe
+ given: Jenny
+ container-title: Third book
+ editor:
+ - family: Smith
+ given: Sam
+ id: пункт3
+ issued: 2007
+ publisher: Oxford University Press
+ publisher-place: Oxford
+ title: Why water is wet
+ type: chapter
+---
+
+
+```
diff --git a/test/command/biblatex-bertram.md b/test/command/biblatex-bertram.md
new file mode 100644
index 000000000..d29a3232d
--- /dev/null
+++ b/test/command/biblatex-bertram.md
@@ -0,0 +1,66 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Bertram and Wentworth 1996)
+
+Bertram, Aaron, and Richard Wentworth. 1996. “Gromov Invariants for
+Holomorphic Maps on Riemann Surfaces.” *J. Amer. Math. Soc.* 9 (2):
+529–571.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Bertram & Wentworth, 1996)
+
+Bertram, A., & Wentworth, R. (1996). Gromov invariants for holomorphic
+maps on Riemann surfaces. *J. Amer. Math. Soc.*, *9*(2), 529–571.
+
+
+}
+
+@string{ jams = {J.~Amer. Math. Soc.} }
+
+@Article{bertram,
+ author = {Bertram, Aaron and Wentworth, Richard},
+ title = {Gromov invariants for holomorphic maps on {Riemann} surfaces},
+ journaltitle = jams,
+ date = 1996,
+ volume = 9,
+ number = 2,
+ pages = {529-571},
+ hyphenation = {american},
+ shorttitle = {Gromov invariants},
+ annotation = {An article entry with a volume and a
+ number field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: An article entry with a volume and a number field
+ author:
+ - family: Bertram
+ given: Aaron
+ - family: Wentworth
+ given: Richard
+ container-title: J. Amer. Math. Soc.
+ id: bertram
+ issue: 2
+ issued: 1996
+ language: 'en-US'
+ page: '529-571'
+ title: Gromov invariants for holomorphic maps on Riemann surfaces
+ title-short: Gromov invariants
+ type: 'article-journal'
+ volume: 9
+---
+
+
+```
diff --git a/test/command/biblatex-bibstring-resolution.md b/test/command/biblatex-bibstring-resolution.md
new file mode 100644
index 000000000..f1dc6f4de
--- /dev/null
+++ b/test/command/biblatex-bibstring-resolution.md
@@ -0,0 +1,20 @@
+```
+% pandoc -f biblatex -t markdown -s
+@book{item1,
+ Title = {The Title: \bibstring{newseries}},
+ Hyphenation = {english}
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- id: item1
+ language: 'en-US'
+ title: 'The title: New series'
+ title-short: The title
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-book-averroes.md b/test/command/biblatex-book-averroes.md
new file mode 100644
index 000000000..600516816
--- /dev/null
+++ b/test/command/biblatex-book-averroes.md
@@ -0,0 +1,128 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+adapted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib
+
+@book{averroes/bland,
+ Annotation = {A book entry with a series and a number. Note the concatenation of the editor and translator fields as well as the indextitle field},
+ Author = {Averroes},
+ Date = 1982,
+ Editor = {Bland, Kalman P.},
+ Hyphenation = {american},
+ Indextitle = {Epistle on the Possibility of Conjunction, The},
+ Keywords = {primary},
+ Location = {New York},
+ Number = 7,
+ Publisher = {Jewish Theological Seminary of America},
+ Series = {{Moreshet: Studies in Jewish History, Literature and Thought}},
+ Shorttitle = {Possibility of Conjunction},
+ Title = {The Epistle on the Possibility of Conjunction with the Active Intellect by {Ibn Rushd} with the Commentary of {Moses Narboni}},
+ Translator = {Bland, Kalman P.}}
+
+@book{averroes/hannes,
+ Annotation = {An annotated edition. Note the concatenation of the editor, translator, and annotator fields. Also note the shorttitle, indextitle, sorttitle, and indexsorttitle fields},
+ Annotator = {Hannes, Ludwig},
+ Author = {Averroes},
+ Date = 1892,
+ Editor = {Hannes, Ludwig},
+ Hyphenation = {german},
+ Indexsorttitle = {Uber die Moglichkeit der Conjunktion},
+ Indextitle = {Über die Möglichkeit der Conjunktion},
+ Keywords = {primary},
+ Location = {Halle an der Saale},
+ Publisher = {C.~A. Kaemmerer},
+ Shorttitle = {Über die Möglichkeit der Conjunktion},
+ Sorttitle = {Uber die Moglichkeit der Conjunktion},
+ Title = {Des Averroës Abhandlung: \mkbibquote{Über die Möglichkeit der Conjunktion} oder \mkbibquote{Über den materiellen Intellekt}},
+ Translator = {Hannes, Ludwig}}
+
+@book{averroes/hercz,
+ Annotation = {A book entry. Note the concatenation of the editor and translator fields as well as the indextitle and indexsorttitle fields},
+ Author = {Averroes},
+ Date = 1869,
+ Editor = {Hercz, J.},
+ Hyphenation = {german},
+ Indexsorttitle = {Drei Abhandlungen uber die Conjunction},
+ Indextitle = {Drei Abhandlungen über die Conjunction},
+ Keywords = {primary},
+ Location = {Berlin},
+ Publisher = {S.~Hermann},
+ Shorttitle = {Drei Abhandlungen},
+ Subtitle = {Von Averroes (Vater und Sohn), aus dem Arabischen übersetzt von Samuel Ibn Tibbon},
+ Title = {Drei Abhandlungen über die Conjunction des separaten Intellects mit dem Menschen},
+ Translator = {Hercz, J.}}
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry with a series and a number. Note the
+ concatenation of the editor and translator fields as well as the
+ indextitle field
+ author:
+ - family: Averroes
+ collection-number: 7
+ collection-title: '[Moreshet: Studies in Jewish History, Literature
+ and Thought]{.nocase}'
+ editor:
+ - family: Bland
+ given: Kalman P.
+ id: averroes/bland
+ issued: 1982
+ keyword: primary
+ language: 'en-US'
+ publisher: Jewish Theological Seminary of America
+ publisher-place: New York
+ title: The epistle on the possibility of conjunction with the active
+ intellect by Ibn Rushd with the commentary of Moses Narboni
+ title-short: Possibility of conjunction
+ translator:
+ - family: Bland
+ given: Kalman P.
+ type: book
+- annote: 'An annotated edition. Note the concatenation of the editor,
+ translator, and annotator fields. Also note the shorttitle,
+ indextitle, sorttitle, and indexsorttitle fields'
+ author:
+ - family: Averroes
+ editor:
+ - family: Hannes
+ given: Ludwig
+ id: averroes/hannes
+ issued: 1892
+ keyword: primary
+ language: 'de-DE'
+ publisher: C. A. Kaemmerer
+ publisher-place: Halle an der Saale
+ title: 'Des Averroës Abhandlung: "Über die Möglichkeit der
+ Conjunktion" oder "Über den materiellen Intellekt"'
+ title-short: Über die Möglichkeit der Conjunktion
+ translator:
+ - family: Hannes
+ given: Ludwig
+ type: book
+- annote: A book entry. Note the concatenation of the editor and
+ translator fields as well as the indextitle and indexsorttitle
+ fields
+ author:
+ - family: Averroes
+ editor:
+ - family: Hercz
+ given: J.
+ id: averroes/hercz
+ issued: 1869
+ keyword: primary
+ language: 'de-DE'
+ publisher: S. Hermann
+ publisher-place: Berlin
+ title: 'Drei Abhandlungen über die Conjunction des separaten
+ Intellects mit dem Menschen: Von Averroes (Vater und Sohn), aus dem
+ Arabischen übersetzt von Samuel Ibn Tibbon'
+ title-short: Drei Abhandlungen
+ translator:
+ - family: Hercz
+ given: J.
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-book-coleridge.md b/test/command/biblatex-book-coleridge.md
new file mode 100644
index 000000000..f2e05feaa
--- /dev/null
+++ b/test/command/biblatex-book-coleridge.md
@@ -0,0 +1,59 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{adapted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib
+
+TODO (as a stopgap):
+Combine biblatex “volume = 7” and “part = 2” to CSL “volume: 7.2”
+
+}
+
+@book{coleridge,
+ Annotation = {One (partial) volume of a multivolume book. This is a book entry with a volume and a part field which explicitly refers to the second (physical) part of the seventh (logical) volume. Also note the series and number fields},
+ Author = {Coleridge, Samuel Taylor},
+ Date = 1983,
+ Editor = {Coburn, Kathleen and Engell, James and Bate, W. Jackson},
+ Hyphenation = {british},
+ Indextitle = {Biographia literaria},
+ Location = {London},
+ Maintitle = {The collected works of {Samuel Taylor Coleridge}},
+ Number = 75,
+ Part = 2,
+ Publisher = {Routledge {and} Kegan Paul},
+ Series = {Bollingen Series},
+ Shorttitle = {Biographia literaria},
+ Title = {Biographia literaria, or {Biographical} sketches of my literary life and opinions},
+ Volume = 7}
+^D
+---
+nocite: '[@*]'
+references:
+- annote: One (partial) volume of a multivolume book. This is a book
+ entry with a volume and a part field which explicitly refers to the
+ second (physical) part of the seventh (logical) volume. Also note
+ the series and number fields
+ author:
+ - family: Coleridge
+ given: Samuel Taylor
+ collection-number: 75
+ collection-title: Bollingen series
+ editor:
+ - family: Coburn
+ given: Kathleen
+ - family: Engell
+ given: James
+ - family: Bate
+ given: W. Jackson
+ id: coleridge
+ issued: 1983
+ language: 'en-GB'
+ publisher: Routledge and Kegan Paul
+ publisher-place: London
+ title: The collected works of Samuel Taylor Coleridge
+ type: book
+ volume: 7.2
+ volume-title: 'Biographia literaria, or Biographical sketches of my
+ literary life and opinions'
+---
+
+
+```
diff --git a/test/command/biblatex-book-title-maintitle-series.md b/test/command/biblatex-book-title-maintitle-series.md
new file mode 100644
index 000000000..c58932aa8
--- /dev/null
+++ b/test/command/biblatex-book-title-maintitle-series.md
@@ -0,0 +1,39 @@
+```
+% pandoc -f biblatex -t markdown -s
+@book{item1,
+ Author = {Author, Al},
+ Date = {2013},
+ Hyphenation = {french},
+ Location = {Location},
+ Mainsubtitle = {Mainsubtitle},
+ Maintitle = {Maintitle},
+ Maintitleaddon = {Maintitleaddon},
+ Number = {3},
+ Publisher = {Publisher},
+ Series = {Series},
+ Subtitle = {Subtitle},
+ Title = {Title of the Book},
+ Titleaddon = {Titleaddon},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Author
+ given: Al
+ collection-number: 3
+ collection-title: Series
+ id: item1
+ issued: 2013
+ language: 'fr-FR'
+ publisher: Publisher
+ publisher-place: Location
+ title: 'Maintitle: Mainsubtitle. Maintitleaddon'
+ type: book
+ volume-title: 'Title of the Book: Subtitle. Titleaddon'
+---
+
+
+```
diff --git a/test/command/biblatex-book-vazques-de-parga.md b/test/command/biblatex-book-vazques-de-parga.md
new file mode 100644
index 000000000..12e0a83f9
--- /dev/null
+++ b/test/command/biblatex-book-vazques-de-parga.md
@@ -0,0 +1,48 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{excerpted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib
+
+Note handling of Author = {Vázques{ de }Parga, Luis}
+
+}
+
+@book{vazques-de-parga,
+ Annotation = {A multivolume book cited as a whole. This is a book entry with volumes, note, sorttitle, and indextitle fields},
+ Author = {Vázques{ de }Parga, Luis and Lacarra, José María and Uría Ríu, Juan},
+ Date = 1993,
+ Hyphenation = {spanish},
+ Indextitle = {Peregrinaciones a Santiago de Compostela, Las},
+ Location = {Pamplona},
+ Note = {Ed. facs. de la realizada en 1948--49},
+ Publisher = {Iberdrola},
+ Shorttitle = {Peregrinaciones},
+ Sorttitle = {Peregrinaciones a Santiago de Compostela},
+ Title = {Las Peregrinaciones a Santiago de Compostela},
+ Volumes = 3}
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A multivolume book cited as a whole. This is a book entry
+ with volumes, note, sorttitle, and indextitle fields'
+ author:
+ - family: Vázques de Parga
+ given: Luis
+ - family: Lacarra
+ given: José María
+ - family: Uría Ríu
+ given: Juan
+ id: 'vazques-de-parga'
+ issued: 1993
+ language: 'es-ES'
+ note: 'Ed. facs. de la realizada en 1948--49'
+ number-of-volumes: 3
+ publisher: Iberdrola
+ publisher-place: Pamplona
+ title: Las Peregrinaciones a Santiago de Compostela
+ title-short: Peregrinaciones
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-brandt.md b/test/command/biblatex-brandt.md
new file mode 100644
index 000000000..66a1f2ac3
--- /dev/null
+++ b/test/command/biblatex-brandt.md
@@ -0,0 +1,88 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Brandt and Hoffmann 1987)
+
+Brandt, Ahasver von, and Erich Hoffmann. 1987. “Die nordischen Länder
+von der Mitte des 11. Jahrhunderts bis 1448.” In *Europa im Hoch- und
+Spätmittelalter*, edited by Ferdinand Seibt, 884–917. Handbuch der
+europäischen Geschichte 2. Stuttgart: Klett-Cotta.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Brandt & Hoffmann, 1987)
+
+Brandt, A. von, & Hoffmann, E. (1987). Die nordischen Länder von der
+Mitte des 11. Jahrhunderts bis 1448. In F. Seibt (ed.), *Europa im Hoch-
+und Spätmittelalter* (pp. 884–917). Stuttgart: Klett-Cotta.
+
+
+}
+
+@InCollection{brandt,
+ author = {von Brandt, Ahasver and Erich Hoffmann},
+ editor = {Ferdinand Seibt},
+ title = {Die nordischen L{\"a}nder von der Mitte des 11.~Jahrhunderts
+ bis 1448},
+ date = 1987,
+ booktitle = {Europa im Hoch- und Sp{\"a}tmittelalter},
+ series = {Handbuch der europ{\"a}ischen Geschichte},
+ number = 2,
+ publisher = {Klett-Cotta},
+ location = {Stuttgart},
+ pages = {884-917},
+ options = {useprefix=false},
+ hyphenation = {german},
+ indexsorttitle= {Nordischen Lander von der Mitte des 11. Jahrhunderts bis
+ 1448},
+ indextitle = {Nordischen L{\"a}nder von der Mitte des 11.~Jahrhunderts bis
+ 1448, Die},
+ shorttitle = {Die nordischen L{\"a}nder},
+ annotation = {An incollection entry with a series and a
+ number. Note the format of the printed name and
+ compare the useprefix option in the options
+ field as well as vangennep. Also note the
+ indextitle, and indexsorttitle fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An incollection entry with a series and a number. Note the
+ format of the printed name and compare the useprefix option in the
+ options field as well as vangennep. Also note the indextitle, and
+ indexsorttitle fields'
+ author:
+ - dropping-particle: von
+ family: Brandt
+ given: Ahasver
+ - family: Hoffmann
+ given: Erich
+ collection-number: 2
+ collection-title: Handbuch der europäischen Geschichte
+ container-title: 'Europa im Hoch- und Spätmittelalter'
+ editor:
+ - family: Seibt
+ given: Ferdinand
+ id: brandt
+ issued: 1987
+ language: 'de-DE'
+ page: '884-917'
+ publisher: 'Klett-Cotta'
+ publisher-place: Stuttgart
+ title: Die nordischen Länder von der Mitte des 11. Jahrhunderts bis
+ 1448
+ title-short: Die nordischen Länder
+ type: chapter
+---
+
+
+```
diff --git a/test/command/biblatex-britannica.md b/test/command/biblatex-britannica.md
new file mode 100644
index 000000000..95e09d00f
--- /dev/null
+++ b/test/command/biblatex-britannica.md
@@ -0,0 +1,85 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Preece 2003)
+
+Preece, Warren E., ed. 2003. *The New EncyclopæDia Britannica*. 15th ed.
+32. Chicago, Ill.: Encyclopædia Britannica.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Preece, 2003)
+
+Preece, W. E. (Ed.). (2003). *The new encyclopædia Britannica* (15th
+ed., 1-32). Chicago, Ill.: Encyclopædia Britannica.
+
+
+NOTES:
+
+- biblio2yaml
+ - spurious <span> in Encyclopædia
+ - options = {useeditor=false} has no equivalent in CSL, so citing and alphabetizing by title even though there is an editor does not seem to be possible
+
+- citeproc
+ - incorrect camel case: "EncyclopæDia"
+ - term "vols." missing
+
+}
+
+@Collection{britannica,
+ editor = {Preece, Warren E.},
+ title = {The New Encyclop{\ae}dia {Britannica}},
+ date = 2003,
+ edition = 15,
+ volumes = 32,
+ publisher = {Encyclop{\ae}dia Britannica},
+ location = {Chicago, Ill.},
+ options = {useeditor=false},
+ label = {EB},
+ hyphenation = {british},
+ sorttitle = {Encyclop{\ae}dia Britannica},
+ indextitle = {Encyclop{\ae}dia Britannica, The New},
+ shorttitle = {Encyclop{\ae}dia {Britannica}},
+ annotation = {This is a collection entry for an encyclopedia. Note
+ the useeditor option in the options field as
+ well as the sorttitle field. We want this entry to be
+ cited and alphabetized by title even though there is an
+ editor. In addition to that, we want the title to be
+ alphabetized under \enquote*{E} rather than \enquote*{T}. Also
+ note the label field which is provided for
+ author-year citation styles},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'This is a collection entry for an encyclopedia. Note the
+ useeditor option in the options field as well as the sorttitle
+ field. We want this entry to be cited and alphabetized by title even
+ though there is an editor. In addition to that, we want the title to
+ be alphabetized under ''E'' rather than ''T''. Also note the label field
+ which is provided for author-year citation styles'
+ edition: 15
+ editor:
+ - family: Preece
+ given: Warren E.
+ id: britannica
+ issued: 2003
+ language: 'en-GB'
+ number-of-volumes: 32
+ publisher: Encyclopædia Britannica
+ publisher-place: 'Chicago, Ill.'
+ title: The new encyclopædia Britannica
+ title-short: Encyclopædia Britannica
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-chiu.md b/test/command/biblatex-chiu.md
new file mode 100644
index 000000000..73dcc29bf
--- /dev/null
+++ b/test/command/biblatex-chiu.md
@@ -0,0 +1,77 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Chiu and Chow 1978)
+
+Chiu, Willy W., and We Min Chow. 1978. “A Hybrid Hierarchical Model of a
+Multiple Virtual Storage (MVS) Operating System.” Research report
+RC-6947. IBM.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Chiu & Chow, 1978)
+
+Chiu, W. W., & Chow, W. M. (1978). *A hybrid hierarchical model of a
+multiple virtual storage (MVS) operating system* (research report No.
+RC-6947). IBM.
+
+
+NOTES:
+
+- biblio2yaml
+ - "MVS", when not wrapped in {}, gives "mVS", which is probably never intended, or useful (latex converts the whole word to lowercase if unprotected ("MVS" -> "mvs"))
+
+}
+
+@Report{chiu,
+ author = {Chiu, Willy W. and Chow, We Min},
+ title = {A Hybrid Hierarchical Model of a Multiple Virtual Storage
+ ({MVS}) Operating System},
+ type = {resreport},
+ institution = {IBM},
+ date = 1978,
+ number = {RC-6947},
+ hyphenation = {american},
+ sorttitle = {Hybrid Hierarchical Model of a Multiple Virtual Storage (MVS)
+ Operating System},
+ indextitle = {Hybrid Hierarchical Model, A},
+ annotation = {This is a report entry for a research report. Note
+ the format of the type field in the database file
+ which uses a localization key. The number of the report is
+ given in the number field. Also note the
+ sorttitle and indextitle fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a report entry for a research report. Note the format
+ of the type field in the database file which uses a localization
+ key. The number of the report is given in the number field. Also
+ note the sorttitle and indextitle fields
+ author:
+ - family: Chiu
+ given: Willy W.
+ - family: Chow
+ given: We Min
+ genre: research report
+ id: chiu
+ issued: 1978
+ language: 'en-US'
+ number: 'RC-6947'
+ publisher: IBM
+ title: A hybrid hierarchical model of a multiple virtual storage (MVS)
+ operating system
+ type: report
+---
+
+
+```
diff --git a/test/command/biblatex-cicero.md b/test/command/biblatex-cicero.md
new file mode 100644
index 000000000..05b21755e
--- /dev/null
+++ b/test/command/biblatex-cicero.md
@@ -0,0 +1,82 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Cicero 1995)
+
+Cicero, Marcus Tullius. 1995. *De natura deorum. Über das Wesen der
+Götter*. Ursula Blank-Sangmeister. Stuttgart: Reclam.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Cicero, 1995)
+
+Cicero, M. T. (1995). *De natura deorum. Über das Wesen der Götter*. (U.
+Blank-Sangmeister). Stuttgart: Reclam.
+
+
+NOTES:
+
+- biblio2yaml
+ - afterword, language: no CSL variables available
+
+- citeproc:
+ - term such as "edited and translated by" should appear
+
+}
+
+@Book{cicero,
+ author = {Cicero, Marcus Tullius},
+ title = {De natura deorum. {\"U}ber das Wesen der G{\"o}tter},
+ date = 1995,
+ editor = {Blank-Sangmeister, Ursula},
+ translator = {Blank-Sangmeister, Ursula},
+ afterword = {Thraede, Klaus},
+ language = {langlatin and langgerman},
+ publisher = {Reclam},
+ location = {Stuttgart},
+ hyphenation = {german},
+ indextitle = {De natura deorum},
+ shorttitle = {De natura deorum},
+ annotation = {A bilingual edition of Cicero's \emph{De natura deorum}, with
+ a German translation. Note the format of the language
+ field in the database file, the concatenation of the
+ editor and translator fields, and the
+ afterword field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A bilingual edition of Cicero''s *De natura deorum*, with a
+ German translation. Note the format of the language field in the
+ database file, the concatenation of the editor and translator
+ fields, and the afterword field'
+ author:
+ - family: Cicero
+ given: Marcus Tullius
+ editor:
+ - family: 'Blank-Sangmeister'
+ given: Ursula
+ id: cicero
+ issued: 1995
+ language: 'de-DE'
+ publisher: Reclam
+ publisher-place: Stuttgart
+ title: De natura deorum. Über das Wesen der Götter
+ title-short: De natura deorum
+ translator:
+ - family: 'Blank-Sangmeister'
+ given: Ursula
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-cms.md b/test/command/biblatex-cms.md
new file mode 100644
index 000000000..3d6534073
--- /dev/null
+++ b/test/command/biblatex-cms.md
@@ -0,0 +1,81 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(*The Chicago Manual of Style: The Essential Guide for Writers, Editors,
+and Publishers* 2003)
+
+*The Chicago Manual of Style: The Essential Guide for Writers, Editors,
+and Publishers*. 2003. 15th ed. Chicago, Ill.: University of Chicago
+Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(*Chicago manual of style*, 2003)
+
+*The Chicago manual of style: The essential guide for writers, editors,
+and publishers*. (2003) (15th ed.). Chicago, Ill.: University of Chicago
+Press.
+
+
+NOTES:
+
+- chicago-author-date.csl should have as in-text citation:
+ (*Chicago Manual of Style* 2003)
+ Same behaviour in Zotero; most probably a style file issue.
+
+}
+
+@Manual{cms,
+ title = {The {Chicago} Manual of Style},
+ date = 2003,
+ subtitle = {The Essential Guide for Writers, Editors, and Publishers},
+ edition = 15,
+ publisher = {University of Chicago Press},
+ location = {Chicago, Ill.},
+ isbn = {0-226-10403-6},
+ label = {CMS},
+ hyphenation = {american},
+ sorttitle = {Chicago Manual of Style},
+ indextitle = {Chicago Manual of Style, The},
+ shorttitle = {Chicago Manual of Style},
+ annotation = {This is a manual entry without an author or
+ editor. Note the label field in the database
+ file which is provided for author-year citation styles. Also
+ note the sorttitle and indextitle fields. By
+ default, all entries without an author or
+ editor are alphabetized by title but we want
+ this entry to be alphabetized under \enquote*{C} rather than
+ \enquote*{T}. There's also an isbn field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'This is a manual entry without an author or editor. Note the
+ label field in the database file which is provided for author-year
+ citation styles. Also note the sorttitle and indextitle fields. By
+ default, all entries without an author or editor are alphabetized by
+ title but we want this entry to be alphabetized under ''C'' rather
+ than ''T''. There''s also an isbn field'
+ edition: 15
+ id: cms
+ isbn: '0-226-10403-6'
+ issued: 2003
+ language: 'en-US'
+ publisher: University of Chicago Press
+ publisher-place: 'Chicago, Ill.'
+ title: 'The Chicago manual of style: The essential guide for writers,
+ editors, and publishers'
+ title-short: Chicago manual of style
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-coleridge.md b/test/command/biblatex-coleridge.md
new file mode 100644
index 000000000..e2a9f7bfd
--- /dev/null
+++ b/test/command/biblatex-coleridge.md
@@ -0,0 +1,86 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2015-03-08:
+
+(Coleridge 1983)
+
+Coleridge, Samuel Taylor. 1983. *The Collected Works of Samuel Taylor
+Coleridge*. Edited by Kathleen Coburn, James Engell, and W. Jackson
+Bate. Vol. 7.2. Bollingen Series 75. London: Routledge and Kegan Paul.
+
+Formatted with pandoc and apa.csl, 2015-03-08:
+
+(Coleridge, 1983)
+
+Coleridge, S. T. (1983). *The collected works of Samuel Taylor
+Coleridge*. (K. Coburn, J. Engell, & W. J. Bate, Eds.) (Vol. 7.2).
+London: Routledge and Kegan Paul.
+
+NOTES:
+
+- volume-title currently not implemented by chicago-author-date.csl and apa.csl.
+
+}
+
+@Book{coleridge,
+ author = {Coleridge, Samuel Taylor},
+ title = {Biographia literaria, or {Biographical} sketches of my literary
+ life and opinions},
+ date = 1983,
+ editor = {Coburn, Kathleen and Engell, James and Bate, W. Jackson},
+ maintitle = {The collected works of {Samuel Taylor Coleridge}},
+ volume = 7,
+ part = 2,
+ series = {Bollingen Series},
+ number = 75,
+ publisher = {Routledge {and} Kegan Paul},
+ location = {London},
+ hyphenation = {british},
+ indextitle = {Biographia literaria},
+ shorttitle = {Biographia literaria},
+ annotation = {One (partial) volume of a multivolume book. This is a
+ book entry with a volume and a part
+ field which explicitly refers to the second (physical) part of
+ the seventh (logical) volume. Also note the series
+ and number fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: One (partial) volume of a multivolume book. This is a book
+ entry with a volume and a part field which explicitly refers to the
+ second (physical) part of the seventh (logical) volume. Also note
+ the series and number fields
+ author:
+ - family: Coleridge
+ given: Samuel Taylor
+ collection-number: 75
+ collection-title: Bollingen series
+ editor:
+ - family: Coburn
+ given: Kathleen
+ - family: Engell
+ given: James
+ - family: Bate
+ given: W. Jackson
+ id: coleridge
+ issued: 1983
+ language: 'en-GB'
+ publisher: Routledge and Kegan Paul
+ publisher-place: London
+ title: The collected works of Samuel Taylor Coleridge
+ type: book
+ volume: 7.2
+ volume-title: 'Biographia literaria, or Biographical sketches of my
+ literary life and opinions'
+---
+
+
+```
diff --git a/test/command/biblatex-companion.md b/test/command/biblatex-companion.md
new file mode 100644
index 000000000..08249e2c0
--- /dev/null
+++ b/test/command/biblatex-companion.md
@@ -0,0 +1,70 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Goossens, Mittelbach, and Samarin 1994)
+
+Goossens, Michel, Frank Mittelbach, and Alexander Samarin. 1994. *The
+LaTeX Companion*. 1st ed. Reading, Mass.: Addison-Wesley.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Goossens, Mittelbach, & Samarin, 1994)
+
+Goossens, M., Mittelbach, F., & Samarin, A. (1994). *The LaTeX
+companion* (1st ed.). Reading, Mass.: Addison-Wesley.
+
+
+}
+
+@Book{companion,
+ author = {Goossens, Michel and Mittelbach, Frank and Samarin, Alexander},
+ title = {The {LaTeX} Companion},
+ date = 1994,
+ edition = 1,
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ pagetotal = 528,
+ hyphenation = {american},
+ sorttitle = {LaTeX Companion},
+ indextitle = {LaTeX Companion, The},
+ shorttitle = {LaTeX Companion},
+ annotation = {A book with three authors. Note the formatting of the author
+ list. By default, only the first name is reversed in the
+ bibliography},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A book with three authors. Note the formatting of the author
+ list. By default, only the first name is reversed in the
+ bibliography'
+ author:
+ - family: Goossens
+ given: Michel
+ - family: Mittelbach
+ given: Frank
+ - family: Samarin
+ given: Alexander
+ edition: 1
+ id: companion
+ issued: 1994
+ language: 'en-US'
+ number-of-pages: 528
+ publisher: 'Addison-Wesley'
+ publisher-place: 'Reading, Mass.'
+ title: The LaTeX companion
+ title-short: LaTeX companion
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-cotton.md b/test/command/biblatex-cotton.md
new file mode 100644
index 000000000..cca41be7e
--- /dev/null
+++ b/test/command/biblatex-cotton.md
@@ -0,0 +1,69 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Cotton et al. 1999)
+
+Cotton, Frank Albert, Geoffrey Wilkinson, Carlos A. Murillio, and
+Manfred Bochmann. 1999. *Advanced Inorganic Chemistry*. 6th ed.
+Chichester: Wiley.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Cotton, Wilkinson, Murillio, & Bochmann, 1999)
+
+Cotton, F. A., Wilkinson, G., Murillio, C. A., & Bochmann, M. (1999).
+*Advanced inorganic chemistry* (6th ed.). Chichester: Wiley.
+
+
+}
+
+@Book{cotton,
+ author = {Cotton, Frank Albert and Wilkinson, Geoffrey and Murillio,
+ Carlos A. and Bochmann, Manfred},
+ title = {Advanced inorganic chemistry},
+ date = 1999,
+ edition = 6,
+ publisher = {Wiley},
+ location = {Chichester},
+ hyphenation = {british},
+ annotation = {A book entry with \arabic{author} authors and an
+ edition field. By default, long author and
+ editor lists are automatically truncated. This is
+ configurable},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A book entry with author authors and an edition field. By
+ default, long author and editor lists are automatically truncated.
+ This is configurable'
+ author:
+ - family: Cotton
+ given: Frank Albert
+ - family: Wilkinson
+ given: Geoffrey
+ - family: Murillio
+ given: Carlos A.
+ - family: Bochmann
+ given: Manfred
+ edition: 6
+ id: cotton
+ issued: 1999
+ language: 'en-GB'
+ publisher: Wiley
+ publisher-place: Chichester
+ title: Advanced inorganic chemistry
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-crossref-inbook-mvbook.md b/test/command/biblatex-crossref-inbook-mvbook.md
new file mode 100644
index 000000000..834752609
--- /dev/null
+++ b/test/command/biblatex-crossref-inbook-mvbook.md
@@ -0,0 +1,58 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+crossref, directly from inbook to mvbook
+
+}
+
+@inbook{inbook-1,
+ Crossref = {mvbook-1},
+ Title = {Macbeth [title field of inbook-1]},
+ Date = {1975},
+ Volume = {3},
+ Chapter = {7},
+ Pages = {100-200},
+}
+
+@mvbook{mvbook-1,
+ Author = {Shakespeare},
+ Date = {1970/1980},
+ Title = {Collected Works [title field of mvbook-1]},
+ Location = {Location},
+ Publisher = {Publisher},
+ Volumes = {4},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Shakespeare
+ chapter-number: 7
+ container-author:
+ - family: Shakespeare
+ container-title: 'Collected works \[title field of mvbook-1\]'
+ id: 'inbook-1'
+ issued: 1975
+ number-of-volumes: 4
+ page: '100-200'
+ publisher: Publisher
+ publisher-place: Location
+ title: 'Macbeth \[title field of inbook-1\]'
+ type: chapter
+ volume: 3
+- author:
+ - family: Shakespeare
+ id: 'mvbook-1'
+ issued: 1970/1980
+ number-of-volumes: 4
+ publisher: Publisher
+ publisher-place: Location
+ title: 'Collected works \[title field of mvbook-1\]'
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-crossref-nested.md b/test/command/biblatex-crossref-nested.md
new file mode 100644
index 000000000..520e464e9
--- /dev/null
+++ b/test/command/biblatex-crossref-nested.md
@@ -0,0 +1,100 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Nested crossreferences (see biber manual v 1.7)
+
+}
+
+@bookinbook{bookinbook-1,
+ Crossref = {book-1},
+ Title = {Macbeth [title field of bookinbook-1]},
+ Chapter = {7},
+ Pages = {100-200},
+}
+
+@inbook{inbook-1,
+ Crossref = {book-1},
+ Title = {Macbeth [title field of inbook-1]},
+ Chapter = {7},
+ Pages = {100-200},
+}
+
+@book{book-1,
+ Crossref = {mvbook-1},
+ Date = {1975},
+ Title = {Tragedies [title field of book-1]},
+ Volume = {3}
+}
+
+@mvbook{mvbook-1,
+ Author = {Shakespeare},
+ Date = {1970/1980},
+ Title = {Collected Works [title field of mvbook-1]},
+ Location = {Location},
+ Publisher = {Publisher},
+ Volumes = {4}
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Shakespeare
+ chapter-number: 7
+ container-author:
+ - family: Shakespeare
+ container-title: 'Collected works \[title field of mvbook-1\]'
+ id: 'bookinbook-1'
+ issued: 1975
+ number-of-volumes: 4
+ page: '100-200'
+ publisher: Publisher
+ publisher-place: Location
+ title: 'Macbeth \[title field of bookinbook-1\]'
+ type: chapter
+ volume: 3
+ volume-title: 'Tragedies \[title field of book-1\]'
+- author:
+ - family: Shakespeare
+ chapter-number: 7
+ container-author:
+ - family: Shakespeare
+ container-title: 'Collected works \[title field of mvbook-1\]'
+ id: 'inbook-1'
+ issued: 1975
+ number-of-volumes: 4
+ page: '100-200'
+ publisher: Publisher
+ publisher-place: Location
+ title: 'Macbeth \[title field of inbook-1\]'
+ type: chapter
+ volume: 3
+ volume-title: 'Tragedies \[title field of book-1\]'
+- author:
+ - family: Shakespeare
+ container-author:
+ - family: Shakespeare
+ id: 'book-1'
+ issued: 1975
+ number-of-volumes: 4
+ publisher: Publisher
+ publisher-place: Location
+ title: 'Collected works \[title field of mvbook-1\]'
+ type: book
+ volume: 3
+ volume-title: 'Tragedies \[title field of book-1\]'
+- author:
+ - family: Shakespeare
+ id: 'mvbook-1'
+ issued: 1970/1980
+ number-of-volumes: 4
+ publisher: Publisher
+ publisher-place: Location
+ title: 'Collected works \[title field of mvbook-1\]'
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-ctan.md b/test/command/biblatex-ctan.md
new file mode 100644
index 000000000..d15b47b55
--- /dev/null
+++ b/test/command/biblatex-ctan.md
@@ -0,0 +1,73 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(“CTAN: The Comprehensive TeX Archive Network” 2006)
+
+“CTAN: The Comprehensive TeX Archive Network.” 2006.
+<http://www.ctan.org>.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(“CTAN: The Comprehensive TeX Archive Network,” 2006)
+
+CTAN: The Comprehensive TeX Archive Network. (2006). Retrieved October
+01, 2006, from <http://www.ctan.org>
+
+
+NOTES:
+
+- biblio2yaml
+ - if there is no shorttitle, but title and subtitle, the title alone should also be mapped to title-short
+
+- citeproc
+ - citeproc should use title-short (if available) instead of title for in-text citations when there is no author
+
+}
+
+@Online{ctan,
+ title = {{CTAN}},
+ date = 2006,
+ url = {http://www.ctan.org},
+ subtitle = {{The Comprehensive TeX Archive Network}},
+ urldate = {2006-10-01},
+ label = {CTAN},
+ hyphenation = {american},
+ annotation = {This is an online entry. The \textsc{url}, which is
+ given in the url field, is transformed into a
+ clickable link if hyperref support has been
+ enabled. Note the format of the urldate field
+ (yyyy-mm-dd) in the database file. Also note the
+ label field which may be used as a fallback by
+ citation styles which need an author and\slash or a
+ year},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- accessed: '2006-10-01'
+ annote: 'This is an online entry. The [url]{.smallcaps}, which is
+ given in the url field, is transformed into a clickable link if
+ hyperref support has been enabled. Note the format of the urldate
+ field (yyyy-mm-dd) in the database file. Also note the label field
+ which may be used as a fallback by citation styles which need an
+ author and/or a year'
+ id: ctan
+ issued: 2006
+ language: 'en-US'
+ title: 'CTAN: The Comprehensive TeX Archive Network'
+ title-short: CTAN
+ type: webpage
+ url: 'http://www.ctan.org'
+---
+
+
+```
diff --git a/test/command/biblatex-dates.md b/test/command/biblatex-dates.md
new file mode 100644
index 000000000..cb3c5585a
--- /dev/null
+++ b/test/command/biblatex-dates.md
@@ -0,0 +1,162 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+ - Dates
+ - Not included in tests:
+ - malformed dates and date ranges
+ - literal dates ("13th century"; not supported by biblatex)
+ - seasons (would have to come from parsing the issue field)
+ - uncertain dates (use "doubtfuldate" from biblatex-apa?)
+ - dates with single-digit day or month (not supported by biblatex)
+ - negative dates (not supported by biblatex)
+ - Note: biblatex supports years < 1000 but only if padded with leading zeros
+ - TODO:
+ - either biblio2yaml or, probably better, citeproc should strip leading zeros
+ from days and months (CSL can add leading zeros to its output, but not remove
+ them when they are in its input data)
+}
+
+@article{year-month-old,
+ Author = {Author, Al},
+ Journal = {Journal},
+ Month = aug,
+ Title = {Year and Month, bibtex style, supported by biblatex for backwards compatibility},
+ Year = {1999}}
+
+@article{year-month-new,
+ Author = {Author, Al},
+ Journal = {Journal},
+ Month = {08},
+ Title = {Year and Month, biblatex style; note that biblatex does not have a ``day'' field},
+ Year = {1999}}
+
+@article{dates,
+ Author = {Author, Al},
+ Date = {2012-12-13},
+ Eventdate = {2011-10-03},
+ Journal = {Journal},
+ Month = may,
+ Origdate = {1888-10-01},
+ Title = {Dates, default biblatex style; year, month to be ignored if date exists},
+ Urldate = {1999-05-23},
+ Year = {9999}}
+
+@article{date-ranges-different-years,
+ Author = {Author, Al},
+ Date = {1999-10-14/2010-01-23},
+ Eventdate = {1999-12/2000-01},
+ Journal = {Journal},
+ Origdate = {1888-01-02/1913-12-13},
+ Title = {Date ranges; different years},
+ Urldate = {2012-10-12/2013-01-31}}
+
+@article{date-ranges-same-year,
+ Author = {Author, Al},
+ Date = {1999-10-14/1999-10-15},
+ Eventdate = {1999-10/1999-11},
+ Journal = {Journal},
+ Origdate = {1888-01-02/1888-12-13},
+ Title = {Date ranges; same year},
+ Urldate = {2012-10-31/2012-11-01}}
+
+@article{date-ranges-open,
+ Author = {Author, Al},
+ Date = {1999-10-14/},
+ Eventdate = {1999-10/},
+ Journal = {Journal},
+ Origdate = {1888-01-02/},
+ Title = {Date ranges, open-ended},
+ Urldate = {2012-10-31/}}
+
+@article{dates-very-old,
+ Author = {Author, Al},
+ Date = {0712-12-13},
+ Eventdate = {0311-10-03},
+ Journal = {Journal},
+ Month = may,
+ Origdate = {0088-10-01},
+ Title = {Dates, year less than 1000},
+ Urldate = {0999-12-14}}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Author
+ given: Al
+ container-title: Journal
+ id: 'year-month-old'
+ issued: '1999-08'
+ title: 'Year and month, bibtex style, supported by biblatex for
+ backwards compatibility'
+ type: 'article-journal'
+- author:
+ - family: Author
+ given: Al
+ container-title: Journal
+ id: 'year-month-new'
+ issued: '1999-08'
+ title: 'Year and month, biblatex style; note that biblatex does not
+ have a "day" field'
+ type: 'article-journal'
+- accessed: '1999-05-23'
+ author:
+ - family: Author
+ given: Al
+ container-title: Journal
+ event-date: '2011-10-03'
+ id: dates
+ issued: '2012-12-13'
+ original-date: '1888-10-01'
+ title: 'Dates, default biblatex style; year, month to be ignored if
+ date exists'
+ type: 'article-journal'
+- accessed: '2012-10-12/2013-01-31'
+ author:
+ - family: Author
+ given: Al
+ container-title: Journal
+ event-date: '1999-12/2000-01'
+ id: 'date-ranges-different-years'
+ issued: '1999-10-14/2010-01-23'
+ original-date: '1888-01-02/1913-12-13'
+ title: Date ranges; different years
+ type: 'article-journal'
+- accessed: '2012-10-31/2012-11-01'
+ author:
+ - family: Author
+ given: Al
+ container-title: Journal
+ event-date: '1999-10/1999-11'
+ id: 'date-ranges-same-year'
+ issued: '1999-10-14/1999-10-15'
+ original-date: '1888-01-02/1888-12-13'
+ title: Date ranges; same year
+ type: 'article-journal'
+- accessed: '2012-10-31/'
+ author:
+ - family: Author
+ given: Al
+ container-title: Journal
+ event-date: '1999-10/'
+ id: 'date-ranges-open'
+ issued: '1999-10-14/'
+ original-date: '1888-01-02/'
+ title: 'Date ranges, open-ended'
+ type: 'article-journal'
+- accessed: '0999-12-14'
+ author:
+ - family: Author
+ given: Al
+ container-title: Journal
+ event-date: '0311-10-03'
+ id: 'dates-very-old'
+ issued: '0712-12-13'
+ original-date: '0088-10-01'
+ title: 'Dates, year less than 1000'
+ type: 'article-journal'
+---
+
+
+```
diff --git a/test/command/biblatex-doody.md b/test/command/biblatex-doody.md
new file mode 100644
index 000000000..26e2ac830
--- /dev/null
+++ b/test/command/biblatex-doody.md
@@ -0,0 +1,101 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Doody 1974) (Matuz 1990)
+
+Doody, Terrence. 1974. “Hemingway’s Style and Jake’s Narration.” *The
+Journal of Narrative Technique* 4 (3): 212–225.
+
+Matuz, Roger, ed. 1990. *Contemporary Literary Criticism*. Vol. 61.
+Detroit: Gale.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Doody, 1974) (Matuz, 1990)
+
+Doody, T. (1974). Hemingway’s style and Jake’s narration. *The Journal
+of Narrative Technique*, *4*(3), 212–225.
+
+Matuz, R. (Ed.). (1990). *Contemporary literary criticism* (Vol. 61, pp.
+204–208). Detroit: Gale.
+
+
+NOTES
+
+- biblio2yaml
+ - contains fields “related” and “relatedstring”. In principle, these could be appended to CSL "note", if citeproc can handle citations in the bibliography ...
+
+}
+
+@Article{doody,
+ author = {Doody, Terrence},
+ title = {Hemingway's Style and {Jake}'s Narration},
+ year = 1974,
+ volume = 4,
+ number = 3,
+ pages = {212-225},
+ hyphenation = {american},
+ related = {matuz:doody},
+ relatedstring= {\autocap{e}xcerpt in},
+ journal = {The Journal of Narrative Technique},
+ annotation = {An article entry cited as an excerpt from a
+ collection entry. Note the format of the
+ related and relatedstring fields},
+}
+
+@Collection{matuz:doody,
+ editor = {Matuz, Roger},
+ title = {Contemporary Literary Criticism},
+ year = 1990,
+ volume = 61,
+ publisher = {Gale},
+ location = {Detroit},
+ pages = {204-208},
+ hyphenation = {american},
+ annotation = {A collection entry providing the excerpt information
+ for the doody entry. Note the format of the
+ pages field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: An article entry cited as an excerpt from a collection entry.
+ Note the format of the related and relatedstring fields
+ author:
+ - family: Doody
+ given: Terrence
+ container-title: The Journal of Narrative Technique
+ id: doody
+ issue: 3
+ issued: 1974
+ language: 'en-US'
+ page: '212-225'
+ title: 'Hemingway''s style and Jake''s narration'
+ type: 'article-journal'
+ volume: 4
+- annote: A collection entry providing the excerpt information for the
+ doody entry. Note the format of the pages field
+ editor:
+ - family: Matuz
+ given: Roger
+ id: 'matuz:doody'
+ issued: 1990
+ language: 'en-US'
+ page: '204-208'
+ publisher: Gale
+ publisher-place: Detroit
+ title: Contemporary literary criticism
+ type: book
+ volume: 61
+---
+
+
+```
diff --git a/test/command/biblatex-edtf-date.md b/test/command/biblatex-edtf-date.md
new file mode 100644
index 000000000..e14a76cb6
--- /dev/null
+++ b/test/command/biblatex-edtf-date.md
@@ -0,0 +1,73 @@
+```
+% pandoc -f biblatex -t markdown -s
+Note that current CSL doesn't give us a way
+to distinguish between /open and /unknown,
+so item3-3 and item3-4 get parsed similarly.
+That should change in CSL 1.1, and then this
+test should be revised.
+
+@article{item3-3, date={1998/unknown}}
+@article{item3-4, date={1999/open}}
+@article{item3-10, date={2004-04-05T14:34:00}}
+@article{item5-1, date={0000}}
+@article{item5-2, date={-0876}}
+@article{item5-3, date={-0877/-0866}}
+@article{item5-5, date={-0343-02}}
+@article{item5-8, date={1723~}}
+@article{item5-9, date={1723?}}
+@article{item5-10, date={1723?~}}
+@article{item5-11, date={2004-22}}
+@article{item5-12, date={2004-24}}
+@article{item5-13, date={20uu}}
+@article{item5-14, date={y-123456789}}
+
+^D
+---
+nocite: '[@*]'
+references:
+- id: 'item3-3'
+ issued: 1998/
+ type: 'article-journal'
+- id: 'item3-4'
+ issued: 1999/
+ type: 'article-journal'
+- id: 'item3-10'
+ issued: '2004-04-05'
+ type: 'article-journal'
+- id: 'item5-1'
+ issued: 0000
+ type: 'article-journal'
+- id: 'item5-2'
+ issued: '-0876'
+ type: 'article-journal'
+- id: 'item5-3'
+ issued: '-0877/-0866'
+ type: 'article-journal'
+- id: 'item5-5'
+ issued: '-0343-02'
+ type: 'article-journal'
+- id: 'item5-8'
+ issued: 1723\~
+ type: 'article-journal'
+- id: 'item5-9'
+ issued: 1723
+ type: 'article-journal'
+- id: 'item5-10'
+ issued: 1723\~
+ type: 'article-journal'
+- id: 'item5-11'
+ issued: '2004-22'
+ type: 'article-journal'
+- id: 'item5-12'
+ issued: '2004-24'
+ type: 'article-journal'
+- id: 'item5-13'
+ issued: 2000/2099
+ type: 'article-journal'
+- id: 'item5-14'
+ issued: 'y-123456789'
+ type: 'article-journal'
+---
+
+
+```
diff --git a/test/command/biblatex-escapedquotes.md b/test/command/biblatex-escapedquotes.md
new file mode 100644
index 000000000..132684adb
--- /dev/null
+++ b/test/command/biblatex-escapedquotes.md
@@ -0,0 +1,51 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{From jgm/pandoc#1568. Double quotes escaped using {"}.}
+
+@ARTICLE{Koff2009-gn,
+ title = "Pan-Canadian evaluation of irreversible compression ratios
+ ({"}lossy{"} compression) for development of national
+ guidelines",
+ author = "Koff, David and Bak, Peter and Brownrigg, Paul and
+ Hosseinzadeh, Danoush and Khademi, April and Kiss, Alex and
+ Lepanto, Luigi and Michalak, Tracy and Shulman, Harry and
+ Volkening, Andrew",
+ affiliation = "Sunnybrook Health Sciences Centre, 2075 Bayview Ave., Toronto,
+ ON, M4N 3M5, Canada. dkoffmcmaster.ca",
+ journal = "Journal of digital imaging",
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Koff
+ given: David
+ - family: Bak
+ given: Peter
+ - family: Brownrigg
+ given: Paul
+ - family: Hosseinzadeh
+ given: Danoush
+ - family: Khademi
+ given: April
+ - family: Kiss
+ given: Alex
+ - family: Lepanto
+ given: Luigi
+ - family: Michalak
+ given: Tracy
+ - family: Shulman
+ given: Harry
+ - family: Volkening
+ given: Andrew
+ container-title: Journal of digital imaging
+ id: 'Koff2009-gn'
+ title: 'Pan-canadian evaluation of irreversible compression ratios
+ (\"lossy\" compression) for development of national guidelines'
+ type: 'article-journal'
+---
+
+
+```
diff --git a/test/command/biblatex-examples.bib b/test/command/biblatex-examples.bib
new file mode 100644
index 000000000..36ac849dd
--- /dev/null
+++ b/test/command/biblatex-examples.bib
@@ -0,0 +1,1674 @@
+@string{anch-ie = {Angew.~Chem. Int.~Ed.}}
+@string{cup = {Cambridge University Press}}
+@string{dtv = {Deutscher Taschenbuch-Verlag}}
+@string{hup = {Harvard University Press}}
+@string{jams = {J.~Amer. Math. Soc.}}
+@string{jchph = {J.~Chem. Phys.}}
+@string{jomch = {J.~Organomet. Chem.}}
+@string{pup = {Princeton University Press}}
+
+@incollection{westfahl:space,
+ author = {Westfahl, Gary},
+ title = {The True Frontier},
+ subtitle = {Confronting and Avoiding the Realities of Space in {American}
+ Science Fiction Films},
+ pages = {55-65},
+ crossref = {westfahl:frontier},
+ langid = {english},
+ langidopts = {variant=american},
+ indextitle = {True Frontier, The},
+ annotation = {A cross-referenced article from a \texttt{collection}. This is
+ an \texttt{incollection} entry with a \texttt{crossref}
+ field. Note the \texttt{subtitle} and \texttt{indextitle}
+ fields},
+}
+
+@set{set,
+ entryset = {herrmann,aksin,yoon},
+ annotation = {A \texttt{set} with three members. The \texttt{crossref} field
+ in the \texttt{@set} entry and the \texttt{entryset} field in
+ each set member entry is needed only when using BibTeX as the
+ backend},
+}
+
+@set{stdmodel,
+ entryset = {glashow,weinberg,salam},
+ annotation = {A \texttt{set} with three members discussing the standard
+ model of particle physics. The \texttt{crossref} field
+ in the \texttt{@set} entry and the \texttt{entryset} field in
+ each set member entry is needed only when using BibTeX as the
+ backend},
+}
+
+@article{aksin,
+ author = {Aks{\i}n, {\"O}zge and T{\"u}rkmen, Hayati and Artok, Levent
+ and {\c{C}}etinkaya, Bekir and Ni, Chaoying and
+ B{\"u}y{\"u}kg{\"u}ng{\"o}r, Orhan and {\"O}zkal, Erhan},
+ title = {Effect of immobilization on catalytic characteristics of
+ saturated {Pd-N}-heterocyclic carbenes in {Mizoroki-Heck}
+ reactions},
+ journaltitle = jomch,
+ date = 2006,
+ volume = 691,
+ number = 13,
+ pages = {3027-3036},
+ indextitle = {Effect of immobilization on catalytic characteristics},
+}
+
+@article{angenendt,
+ author = {Angenendt, Arnold},
+ title = {In Honore Salvatoris~-- Vom Sinn und Unsinn der
+ Patrozinienkunde},
+ journaltitle = {Revue d'Histoire Eccl{\'e}siastique},
+ date = 2002,
+ volume = 97,
+ pages = {431--456, 791--823},
+ langid = {german},
+ indextitle = {In Honore Salvatoris},
+ shorttitle = {In Honore Salvatoris},
+ annotation = {A German article in a French journal. Apart from that, a
+ typical \texttt{article} entry. Note the \texttt{indextitle}
+ field},
+}
+
+@article{baez/article,
+ author = {Baez, John C. and Lauda, Aaron D.},
+ title = {Higher-Dimensional Algebra {V}: 2-Groups},
+ journaltitle = {Theory and Applications of Categories},
+ date = 2004,
+ volume = 12,
+ pages = {423-491},
+ version = 3,
+ eprint = {math/0307200v3},
+ eprinttype = {arxiv},
+ langid = {english},
+ langidopts = {variant=american},
+ annotation = {An \texttt{article} with \texttt{eprint} and
+ \texttt{eprinttype} fields. Note that the arXiv reference is
+ transformed into a clickable link if \texttt{hyperref} support
+ has been enabled. Compare \texttt{baez\slash online}, which
+ is the same item given as an \texttt{online} entry},
+}
+
+@article{bertram,
+ author = {Bertram, Aaron and Wentworth, Richard},
+ title = {Gromov invariants for holomorphic maps on {Riemann} surfaces},
+ journaltitle = jams,
+ date = 1996,
+ volume = 9,
+ number = 2,
+ pages = {529-571},
+ langid = {english},
+ langidopts = {variant=american},
+ shorttitle = {Gromov invariants},
+ annotation = {An \texttt{article} entry with a \texttt{volume} and a
+ \texttt{number} field},
+}
+
+@article{doody,
+ author = {Doody, Terrence},
+ title = {Hemingway's Style and {Jake's} Narration},
+ year = 1974,
+ volume = 4,
+ number = 3,
+ pages = {212-225},
+ langid = {english},
+ langidopts = {variant=american},
+ related = {matuz:doody},
+ relatedstring= {\autocap{e}xcerpt in},
+ journal = {The Journal of Narrative Technique},
+ annotation = {An \texttt{article} entry cited as an excerpt from a
+ \texttt{collection} entry. Note the format of the
+ \texttt{related} and \texttt{relatedstring} fields},
+}
+
+@collection{matuz:doody,
+ editor = {Matuz, Roger},
+ title = {Contemporary Literary Criticism},
+ year = 1990,
+ volume = 61,
+ publisher = {Gale},
+ location = {Detroit},
+ pages = {204-208},
+ langid = {english},
+ langidopts = {variant=american},
+ annotation = {A \texttt{collection} entry providing the excerpt information
+ for the \texttt{doody} entry. Note the format of the
+ \texttt{pages} field},
+}
+
+@article{gillies,
+ author = {Gillies, Alexander},
+ title = {Herder and the Preparation of {Goethe's} Idea of World
+ Literature},
+ journaltitle = {Publications of the English Goethe Society},
+ date = 1933,
+ series = {newseries},
+ volume = 9,
+ pages = {46-67},
+ langid = {english},
+ langidopts = {variant=british},
+ annotation = {An \texttt{article} entry with a \texttt{series} and a
+ \texttt{volume} field. Note that format of the \texttt{series}
+ field in the database file},
+}
+
+@article{glashow,
+ author = {Glashow, Sheldon},
+ title = {Partial Symmetries of Weak Interactions},
+ journaltitle = {Nucl.~Phys.},
+ date = 1961,
+ volume = 22,
+ pages = {579-588},
+}
+
+@article{herrmann,
+ author = {Herrmann, Wolfgang A. and {\"O}fele, Karl and Schneider,
+ Sabine K. and Herdtweck, Eberhardt and Hoffmann, Stephan D.},
+ title = {A carbocyclic carbene as an efficient catalyst ligand for {C--C}
+ coupling reactions},
+ journaltitle = anch-ie,
+ date = 2006,
+ volume = 45,
+ number = 23,
+ pages = {3859-3862},
+ indextitle = {Carbocyclic carbene as an efficient catalyst, A},
+}
+
+@article{kastenholz,
+ author = {Kastenholz, M. A. and H{\"u}nenberger, Philippe H.},
+ title = {Computation of methodology\hyphen independent ionic solvation
+ free energies from molecular simulations},
+ journaltitle = jchph,
+ date = 2006,
+ subtitle = {{I}. {The} electrostatic potential in molecular liquids},
+ volume = 124,
+ eid = 124106,
+ doi = {10.1063/1.2172593},
+ langid = {english},
+ langidopts = {variant=american},
+ indextitle = {Computation of ionic solvation free energies},
+ annotation = {An \texttt{article} entry with an \texttt{eid} and a
+ \texttt{doi} field. Note that the \textsc{doi} is transformed
+ into a clickable link if \texttt{hyperref} support has been
+ enabled},
+ abstract = {The computation of ionic solvation free energies from
+ atomistic simulations is a surprisingly difficult problem that
+ has found no satisfactory solution for more than 15 years. The
+ reason is that the charging free energies evaluated from such
+ simulations are affected by very large errors. One of these is
+ related to the choice of a specific convention for summing up
+ the contributions of solvent charges to the electrostatic
+ potential in the ionic cavity, namely, on the basis of point
+ charges within entire solvent molecules (M scheme) or on the
+ basis of individual point charges (P scheme). The use of an
+ inappropriate convention may lead to a charge-independent
+ offset in the calculated potential, which depends on the
+ details of the summation scheme, on the quadrupole-moment
+ trace of the solvent molecule, and on the approximate form
+ used to represent electrostatic interactions in the
+ system. However, whether the M or P scheme (if any) represents
+ the appropriate convention is still a matter of on-going
+ debate. The goal of the present article is to settle this
+ long-standing controversy by carefully analyzing (both
+ analytically and numerically) the properties of the
+ electrostatic potential in molecular liquids (and inside
+ cavities within them).},
+}
+
+@article{murray,
+ author = {Hostetler, Michael J. and Wingate, Julia E. and Zhong,
+ Chuan-Jian and Harris, Jay E. and Vachet, Richard W. and
+ Clark, Michael R. and Londono, J. David and Green, Stephen
+ J. and Stokes, Jennifer J. and Wignall, George D. and Glish,
+ Gary L. and Porter, Marc D. and Evans, Neal D. and Murray,
+ Royce W.},
+ title = {Alkanethiolate gold cluster molecules with core diameters from
+ 1.5 to 5.2~{nm}},
+ journaltitle = {Langmuir},
+ date = 1998,
+ subtitle = {Core and monolayer properties as a function of core size},
+ volume = 14,
+ number = 1,
+ pages = {17-30},
+ langid = {english},
+ langidopts = {variant=american},
+ indextitle = {Alkanethiolate gold cluster molecules},
+ shorttitle = {Alkanethiolate gold cluster molecules},
+ annotation = {An \texttt{article} entry with \arabic{author} authors. By
+ default, long author and editor lists are automatically
+ truncated. This is configurable},
+}
+
+@article{reese,
+ author = {Reese, Trevor R.},
+ title = {Georgia in {Anglo-Spanish} Diplomacy, 1736--1739},
+ journaltitle = {William and Mary Quarterly},
+ date = 1958,
+ series = 3,
+ volume = 15,
+ pages = {168-190},
+ langid = {english},
+ langidopts = {variant=american},
+ annotation = {An \texttt{article} entry with a \texttt{series} and a
+ \texttt{volume} field. Note the format of the series. If the
+ value of the \texttt{series} field is an integer, this number
+ is printed as an ordinal and the string \enquote*{series} is
+ appended automatically},
+}
+
+@article{sarfraz,
+ author = {M. Sarfraz and M. F. A. Razzak},
+ title = {Technical section: {An} algorithm for automatic capturing of
+ the font outlines},
+ year = 2002,
+ volume = 26,
+ number = 5,
+ pages = {795-804},
+ issn = {0097-8493},
+ journal = {Computers and Graphics},
+ annotation = {An \texttt{article} entry with an \texttt{issn} field},
+}
+
+@article{shore,
+ author = {Shore, Bradd},
+ title = {Twice-Born, Once Conceived},
+ journaltitle = {American Anthropologist},
+ date = {1991-03},
+ subtitle = {Meaning Construction and Cultural Cognition},
+ series = {newseries},
+ volume = 93,
+ number = 1,
+ pages = {9-27},
+ annotation = {An \texttt{article} entry with \texttt{series},
+ \texttt{volume}, and \texttt{number} fields. Note the format
+ of the \texttt{series} which is a localization key},
+}
+
+@article{sigfridsson,
+ author = {Sigfridsson, Emma and Ryde, Ulf},
+ title = {Comparison of methods for deriving atomic charges from the
+ electrostatic potential and moments},
+ journaltitle = {Journal of Computational Chemistry},
+ date = 1998,
+ volume = 19,
+ number = 4,
+ pages = {377-395},
+ doi = {10.1002/(SICI)1096-987X(199803)19:4<377::AID-JCC1>3.0.CO;2-P},
+ langid = {english},
+ langidopts = {variant=american},
+ indextitle = {Methods for deriving atomic charges},
+ annotation = {An \texttt{article} entry with \texttt{volume},
+ \texttt{number}, and \texttt{doi} fields. Note that the
+ \textsc{doi} is transformed into a clickable link if
+ \texttt{hyperref} support has been enabled},
+ abstract = {Four methods for deriving partial atomic charges from the
+ quantum chemical electrostatic potential (CHELP, CHELPG,
+ Merz-Kollman, and RESP) have been compared and critically
+ evaluated. It is shown that charges strongly depend on how and
+ where the potential points are selected. Two alternative
+ methods are suggested to avoid the arbitrariness in the
+ point-selection schemes and van der Waals exclusion radii:
+ CHELP-BOW, which also estimates the charges from the
+ electrostatic potential, but with potential points that are
+ Boltzmann-weighted after their occurrence in actual
+ simulations using the energy function of the program in which
+ the charges will be used, and CHELMO, which estimates the
+ charges directly from the electrostatic multipole
+ moments. Different criteria for the quality of the charges are
+ discussed.},
+}
+
+@article{spiegelberg,
+ author = {Spiegelberg, Herbert},
+ title = {\mkbibquote{Intention} und \mkbibquote{Intentionalit{\"a}t} in
+ der Scholastik, bei Brentano und Husserl},
+ journaltitle = {Studia Philosophica},
+ date = 1969,
+ volume = 29,
+ pages = {189-216},
+ langid = {german},
+ sorttitle = {Intention und Intentionalitat in der Scholastik, bei Brentano
+ und Husserl},
+ indexsorttitle= {Intention und Intentionalitat in der Scholastik, bei Brentano
+ und Husserl},
+ shorttitle = {Intention und Intentionalit{\"a}t},
+ annotation = {An \texttt{article} entry. Note the \texttt{sorttitle} and
+ \texttt{indexsorttitle} fields and the markup of the quotes in
+ the database file},
+}
+
+@article{springer,
+ author = {Springer, Otto},
+ title = {Mediaeval Pilgrim Routes from {Scandinavia} to {Rome}},
+ journaltitle = {Mediaeval Studies},
+ date = 1950,
+ volume = 12,
+ pages = {92-122},
+ langid = {english},
+ langidopts = {variant=british},
+ shorttitle = {Mediaeval Pilgrim Routes},
+ annotation = {A plain \texttt{article} entry},
+}
+
+@article{weinberg,
+ author = {Weinberg, Steven},
+ title = {A Model of Leptons},
+ journaltitle = {Phys.~Rev.~Lett.},
+ date = 1967,
+ volume = 19,
+ pages = {1264-1266},
+}
+
+@article{yoon,
+ author = {Yoon, Myeong S. and Ryu, Dowook and Kim, Jeongryul and Ahn,
+ Kyo Han},
+ title = {Palladium pincer complexes with reduced bond angle strain:
+ efficient catalysts for the {Heck} reaction},
+ journaltitle = {Organometallics},
+ date = 2006,
+ volume = 25,
+ number = 10,
+ pages = {2409-2411},
+ indextitle = {Palladium pincer complexes},
+}
+
+@book{aristotle:anima,
+ author = {Aristotle},
+ title = {De Anima},
+ date = 1907,
+ editor = {Hicks, Robert Drew},
+ publisher = cup,
+ location = {Cambridge},
+ keywords = {primary},
+ langid = {english},
+ langidopts = {variant=british},
+ annotation = {A \texttt{book} entry with an \texttt{author} and an
+ \texttt{editor}},
+}
+
+@book{aristotle:physics,
+ author = {Aristotle},
+ title = {Physics},
+ date = 1929,
+ translator = {Wicksteed, P. H. and Cornford, F. M.},
+ publisher = {G. P. Putnam},
+ location = {New York},
+ keywords = {primary},
+ langid = {english},
+ langidopts = {variant=american},
+ shorttitle = {Physics},
+ annotation = {A \texttt{book} entry with a \texttt{translator} field},
+}
+
+@book{aristotle:poetics,
+ author = {Aristotle},
+ title = {Poetics},
+ date = 1968,
+ editor = {Lucas, D. W.},
+ series = {Clarendon {Aristotle}},
+ publisher = {Clarendon Press},
+ location = {Oxford},
+ keywords = {primary},
+ langid = {english},
+ langidopts = {variant=british},
+ shorttitle = {Poetics},
+ annotation = {A \texttt{book} entry with an \texttt{author} and an
+ \texttt{editor} as well as a \texttt{series} field},
+}
+
+@book{aristotle:rhetoric,
+ author = {Aristotle},
+ title = {The Rhetoric of {Aristotle} with a commentary by the late {Edward
+ Meredith Cope}},
+ date = 1877,
+ editor = {Cope, Edward Meredith},
+ commentator = {Cope, Edward Meredith},
+ volumes = 3,
+ publisher = cup,
+ keywords = {primary},
+ langid = {english},
+ langidopts = {variant=british},
+ sorttitle = {Rhetoric of Aristotle},
+ indextitle = {Rhetoric of {Aristotle}, The},
+ shorttitle = {Rhetoric},
+ annotation = {A commented edition. Note the concatenation of the
+ \texttt{editor} and \texttt{commentator} fields as well as the
+ \texttt{volumes}, \texttt{sorttitle}, and \texttt{indextitle}
+ fields},
+}
+
+@book{augustine,
+ author = {Augustine, Robert L.},
+ title = {Heterogeneous catalysis for the synthetic chemist},
+ date = 1995,
+ publisher = {Marcel Dekker},
+ location = {New York},
+ langid = {english},
+ langidopts = {variant=american},
+ shorttitle = {Heterogeneous catalysis},
+ annotation = {A plain \texttt{book} entry},
+}
+
+@book{averroes/bland,
+ author = {Averroes},
+ title = {The Epistle on the Possibility of Conjunction with the Active
+ Intellect by {Ibn Rushd} with the Commentary of {Moses Narboni}},
+ date = 1982,
+ editor = {Bland, Kalman P.},
+ translator = {Bland, Kalman P.},
+ series = {Moreshet: Studies in {Jewish} History, Literature and Thought},
+ number = 7,
+ publisher = {Jewish Theological Seminary of America},
+ location = {New York},
+ keywords = {primary},
+ langid = {english},
+ langidopts = {variant=american},
+ indextitle = {Epistle on the Possibility of Conjunction, The},
+ shorttitle = {Possibility of Conjunction},
+ annotation = {A \texttt{book} entry with a \texttt{series} and a
+ \texttt{number}. Note the concatenation of the \texttt{editor}
+ and \texttt{translator} fields as well as the
+ \texttt{indextitle} field},
+}
+
+@book{averroes/hannes,
+ author = {Averroes},
+ title = {Des Averro{\"e}s Abhandlung: \mkbibquote{{\"U}ber die
+ M{\"o}glichkeit der Conjunktion} oder \mkbibquote{{\"U}ber den
+ materiellen Intellekt}},
+ date = 1892,
+ editor = {Hannes, Ludwig},
+ translator = {Hannes, Ludwig},
+ annotator = {Hannes, Ludwig},
+ publisher = {C.~A. Kaemmerer},
+ location = {Halle an der Saale},
+ keywords = {primary},
+ langid = {german},
+ sorttitle = {Uber die Moglichkeit der Conjunktion},
+ indexsorttitle= {Uber die Moglichkeit der Conjunktion},
+ indextitle = {{\"U}ber die M{\"o}glichkeit der Conjunktion},
+ shorttitle = {{\"U}ber die M{\"o}glichkeit der Conjunktion},
+ annotation = {An annotated edition. Note the concatenation of the
+ \texttt{editor}, \texttt{translator}, and \texttt{annotator}
+ fields. Also note the \texttt{shorttitle},
+ \texttt{indextitle}, \texttt{sorttitle}, and
+ \texttt{indexsorttitle} fields},
+}
+
+@book{averroes/hercz,
+ author = {Averroes},
+ title = {Drei Abhandlungen {\"u}ber die Conjunction des separaten
+ Intellects mit dem Menschen},
+ date = 1869,
+ editor = {Hercz, J.},
+ translator = {Hercz, J.},
+ publisher = {S.~Hermann},
+ location = {Berlin},
+ keywords = {primary},
+ langid = {german},
+ indexsorttitle= {Drei Abhandlungen uber die Conjunction},
+ indextitle = {Drei Abhandlungen {\"u}ber die Conjunction},
+ subtitle = {Von Averroes (Vater und Sohn), aus dem Arabischen
+ {\"u}bersetzt von Samuel Ibn Tibbon},
+ shorttitle = {Drei Abhandlungen},
+ annotation = {A \texttt{book} entry. Note the concatenation of the
+ \texttt{editor} and \texttt{translator} fields as well as the
+ \texttt{indextitle} and \texttt{indexsorttitle} fields},
+}
+
+@book{cicero,
+ author = {Cicero, Marcus Tullius},
+ title = {De natura deorum. {\"U}ber das Wesen der G{\"o}tter},
+ date = 1995,
+ editor = {Blank-Sangmeister, Ursula},
+ translator = {Blank-Sangmeister, Ursula},
+ afterword = {Thraede, Klaus},
+ language = {langlatin and langgerman},
+ publisher = {Reclam},
+ location = {Stuttgart},
+ langid = {german},
+ indextitle = {De natura deorum},
+ shorttitle = {De natura deorum},
+ annotation = {A bilingual edition of Cicero's \emph{De natura deorum}, with
+ a German translation. Note the format of the \texttt{language}
+ field in the database file, the concatenation of the
+ \texttt{editor} and \texttt{translator} fields, and the
+ \texttt{afterword} field},
+}
+
+@book{coleridge,
+ author = {Coleridge, Samuel Taylor},
+ title = {Biographia literaria, or {Biographical} sketches of my literary
+ life and opinions},
+ date = 1983,
+ editor = {Coburn, Kathleen and Engell, James and Bate, W. Jackson},
+ maintitle = {The collected works of {Samuel Taylor Coleridge}},
+ volume = 7,
+ part = 2,
+ series = {Bollingen Series},
+ number = 75,
+ publisher = {Routledge {and} Kegan Paul},
+ location = {London},
+ langid = {english},
+ langidopts = {variant=british},
+ indextitle = {Biographia literaria},
+ shorttitle = {Biographia literaria},
+ annotation = {One (partial) volume of a multivolume book. This is a
+ \texttt{book} entry with a \texttt{volume} and a \texttt{part}
+ field which explicitly refers to the second (physical) part of
+ the seventh (logical) volume. Also note the \texttt{series}
+ and \texttt{number} fields},
+}
+
+@book{companion,
+ author = {Goossens, Michel and Mittelbach, Frank and Samarin, Alexander},
+ title = {The {LaTeX} Companion},
+ date = 1994,
+ edition = 1,
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ pagetotal = 528,
+ langid = {english},
+ langidopts = {variant=american},
+ sorttitle = {LaTeX Companion},
+ indextitle = {LaTeX Companion, The},
+ shorttitle = {LaTeX Companion},
+ annotation = {A book with three authors. Note the formatting of the author
+ list. By default, only the first name is reversed in the
+ bibliography},
+}
+
+@book{cotton,
+ author = {Cotton, Frank Albert and Wilkinson, Geoffrey and Murillio,
+ Carlos A. and Bochmann, Manfred},
+ title = {Advanced inorganic chemistry},
+ date = 1999,
+ edition = 6,
+ publisher = {Wiley},
+ location = {Chichester},
+ langid = {english},
+ langidopts = {variant=british},
+ annotation = {A \texttt{book} entry with \arabic{author} authors and an
+ \texttt{edition} field. By default, long \texttt{author} and
+ \texttt{editor} lists are automatically truncated. This is
+ configurable},
+}
+
+@book{gerhardt,
+ author = {Gerhardt, Michael J.},
+ title = {The Federal Appointments Process},
+ date = 2000,
+ publisher = {Duke University Press},
+ location = {Durham and London},
+ langid = {english},
+ langidopts = {variant=american},
+ sorttitle = {Federal Appointments Process},
+ indextitle = {Federal Appointments Process, The},
+ subtitle = {A Constitutional and Historical Analysis},
+ shorttitle = {Federal Appointments Process},
+ annotation = {This is a \texttt{book} entry. Note the format of the
+ \texttt{location} field as well as the \texttt{sorttitle} and
+ \texttt{indextitle} fields},
+}
+
+@book{gonzalez,
+ author = {Gonzalez, Ray},
+ title = {The Ghost of {John Wayne} and Other Stories},
+ date = 2001,
+ publisher = {The University of Arizona Press},
+ location = {Tucson},
+ isbn = {0-816-52066-6},
+ langid = {english},
+ langidopts = {variant=american},
+ sorttitle = {Ghost of John Wayne and Other Stories},
+ indextitle = {Ghost of {John Wayne} and Other Stories, The},
+ shorttitle = {Ghost of {John Wayne}},
+ annotation = {A collection of short stories. This is a \texttt{book} entry.
+ Note the \texttt{sorttitle} and \texttt{indextitle} fields in
+ the database file. There's also an \texttt{isbn} field},
+}
+
+@book{hammond,
+ author = {Hammond, Christopher},
+ title = {The basics of crystallography and diffraction},
+ date = 1997,
+ publisher = {International Union of Crystallography and Oxford University
+ Press},
+ location = {Oxford},
+ langid = {english},
+ langidopts = {variant=british},
+ sorttitle = {Basics of crystallography and diffraction},
+ indextitle = {Basics of crystallography and diffraction, The},
+ shorttitle = {Crystallography and diffraction},
+ annotation = {A \texttt{book} entry. Note the \texttt{sorttitle} and
+ \texttt{indextitle} fields as well as the format of the
+ \texttt{publisher} field},
+}
+
+@book{iliad,
+ author = {Homer},
+ title = {Die Ilias},
+ date = 2004,
+ translator = {Schadewaldt, Wolfgang},
+ introduction = {Latacz, Joachim},
+ edition = 3,
+ publisher = {Artemis \& Winkler},
+ location = {D{\"u}sseldorf and Z{\"u}rich},
+ langid = {german},
+ sorttitle = {Ilias},
+ indextitle = {Ilias, Die},
+ shorttitle = {Ilias},
+ annotation = {A German translation of the \emph{Iliad}. Note the
+ \texttt{translator} and \texttt{introduction} fields and the
+ format of the \texttt{location} field in the database
+ file. Also note the \texttt{sorttitle} and \texttt{indextitle}
+ fields},
+}
+
+@book{knuth:ct,
+ author = {Knuth, Donald E.},
+ title = {Computers \& Typesetting},
+ date = {1984/1986},
+ volumes = 5,
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ langid = {english},
+ langidopts = {variant=american},
+ sortyear = {1984-0},
+ sorttitle = {Computers & Typesetting},
+ indexsorttitle= {Computers & Typesetting},
+ annotation = {A five-volume book cited as a whole. This is a \texttt{book}
+ entry, note the \texttt{volumes} field},
+}
+
+@book{knuth:ct:a,
+ author = {Knuth, Donald E.},
+ title = {The {\TeX} book},
+ date = 1984,
+ maintitle = {Computers \& Typesetting},
+ volume = {A},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ langid = {english},
+ langidopts = {variant=american},
+ sortyear = {1984-1},
+ sorttitle = {Computers & Typesetting A},
+ indexsorttitle= {The TeXbook},
+ indextitle = {\protect\TeX book, The},
+ shorttitle = {\TeX book},
+ annotation = {The first volume of a five-volume book. Note the
+ \texttt{sorttitle} and \texttt{sortyear} fields. We want this
+ volume to be listed after the entry referring to the entire
+ five-volume set. Also note the \texttt{indextitle} and
+ \texttt{indexsorttitle} fields. Indexing packages that don't
+ generate robust index entries require some control sequences
+ to be protected from expansion},
+}
+
+@book{knuth:ct:b,
+ author = {Knuth, Donald E.},
+ title = {\TeX: The Program},
+ date = 1986,
+ maintitle = {Computers \& Typesetting},
+ volume = {B},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ langid = {english},
+ langidopts = {variant=american},
+ sortyear = {1986-1},
+ sorttitle = {Computers & Typesetting B},
+ indexsorttitle= {TeX: The Program},
+ shorttitle = {\TeX},
+ annotation = {The second volume of a five-volume book. Note the
+ \texttt{sorttitle} and \texttt{sortyear} fields. Also note the
+ \texttt{indexsorttitle} field},
+}
+
+@book{knuth:ct:c,
+ author = {Knuth, Donald E.},
+ title = {The {METAFONTbook}},
+ date = 1986,
+ maintitle = {Computers \& Typesetting},
+ volume = {C},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ langid = {english},
+ langidopts = {variant=american},
+ sortyear = {1986-2},
+ sorttitle = {Computers & Typesetting C},
+ indextitle = {METAFONTbook, The},
+ shorttitle = {METAFONTbook},
+ annotation = {The third volume of a five-volume book. Note the
+ \texttt{sorttitle} and \texttt{sortyear} fields as well as the
+ \texttt{indextitle} field},
+}
+
+@book{knuth:ct:d,
+ author = {Knuth, Donald E.},
+ title = {METAFONT: The Program},
+ date = 1986,
+ maintitle = {Computers \& Typesetting},
+ volume = {D},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ langid = {english},
+ langidopts = {variant=american},
+ sortyear = {1986-3},
+ sorttitle = {Computers & Typesetting D},
+ shorttitle = {METAFONT},
+ annotation = {The fourth volume of a five-volume book. Note the
+ \texttt{sorttitle} and \texttt{sortyear} fields},
+}
+
+@book{knuth:ct:e,
+ author = {Knuth, Donald E.},
+ title = {{Computer Modern} Typefaces},
+ date = 1986,
+ maintitle = {Computers \& Typesetting},
+ volume = {E},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ langid = {english},
+ langidopts = {variant=american},
+ sortyear = {1986-4},
+ sorttitle = {Computers & Typesetting E},
+ annotation = {The fifth volume of a five-volume book. Note the
+ \texttt{sorttitle} and \texttt{sortyear} fields},
+}
+
+@book{knuth:ct:related,
+ author = {Knuth, Donald E.},
+ title = {Computers \& Typesetting},
+ date = {1984/1986},
+ volumes = 5,
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ langid = {english},
+ langidopts = {variant=american},
+ sortyear = {1984-0},
+ sorttitle = {Computers & Typesetting},
+ indexsorttitle= {Computers & Typesetting},
+ related = {knuth:ct:a,knuth:ct:b,knuth:ct:c,knuth:ct:d,knuth:ct:e},
+ relatedtype = {multivolume},
+ annotation = {A five-volume book cited as a whole and related to its
+ individual volumes. Note the \texttt{related} and
+ \texttt{relatedtype} fields},
+}
+
+@book{kullback,
+ author = {Kullback, Solomon},
+ title = {Information Theory and Statistics},
+ year = 1959,
+ publisher = {John Wiley \& Sons},
+ location = {New York},
+ langid = {english},
+ langidopts = {variant=american},
+}
+
+@book{kullback:reprint,
+ author = {Kullback, Solomon},
+ title = {Information Theory and Statistics},
+ year = 1997,
+ publisher = {Dover Publications},
+ location = {New York},
+ origyear = 1959,
+ origpublisher= {John Wiley \& Sons},
+ langid = {english},
+ langidopts = {variant=american},
+ annotation = {A reprint of the \texttt{kullback} entry. Note the format of
+ \texttt{origyear} and \texttt{origpublisher}. These fields are
+ not used by the standard bibliography styles},
+}
+
+@book{kullback:related,
+ author = {Kullback, Solomon},
+ title = {Information Theory and Statistics},
+ year = 1997,
+ publisher = {Dover Publications},
+ location = {New York},
+ langid = {english},
+ langidopts = {variant=american},
+ related = {kullback},
+ relatedtype = {origpubin},
+ annotation = {A reprint of the \texttt{kullback} entry. Note the format of
+ the \texttt{related} and \texttt{relatedtype} fields},
+}
+
+@book{malinowski,
+ author = {Malinowski, Bronis{\l}aw},
+ title = {Argonauts of the {Western Pacific}},
+ date = 1972,
+ edition = 8,
+ publisher = {Routledge {and} Kegan Paul},
+ location = {London},
+ langid = {english},
+ langidopts = {variant=british},
+ subtitle = {An account of native enterprise and adventure in the
+ Archipelagoes of {Melanesian New Guinea}},
+ shorttitle = {Argonauts},
+ annotation = {This is a \texttt{book} entry. Note the format of the
+ \texttt{publisher} and \texttt{edition} fields as well as the
+ \texttt{subtitle} field},
+}
+
+@book{maron,
+ author = {Maron, Monika},
+ title = {Animal Triste},
+ date = 2000,
+ translator = {Brigitte Goldstein},
+ origlanguage = {german},
+ publisher = {University of Nebraska Press},
+ location = {Lincoln},
+ langid = {english},
+ langidopts = {variant=american},
+ shorttitle = {Animal Triste},
+ annotation = {An English translation of a German novel with a French title.
+ In other words: a \texttt{book} entry with a
+ \texttt{translator} field. Note the \texttt{origlanguage}
+ field which is concatenated with the \texttt{translator}},
+}
+
+@book{massa,
+ author = {Werner Massa},
+ title = {Crystal structure determination},
+ date = 2004,
+ edition = 2,
+ publisher = {Spinger},
+ location = {Berlin},
+ langid = {english},
+ langidopts = {variant=british},
+ annotation = {A \texttt{book} entry with an \texttt{edition} field},
+}
+
+@article{moore,
+ author = {Moore, Gordon E.},
+ title = {Cramming more components onto integrated circuits},
+ journaltitle = {Electronics},
+ year = 1965,
+ volume = 38,
+ number = 8,
+ pages = {114-117},
+ langid = {english},
+ langidopts = {variant=american},
+}
+
+@article{moore:related,
+ author = {Moore, Gordon E.},
+ title = {Cramming more components onto integrated circuits},
+ journaltitle = {Proceedings of the {IEEE}},
+ year = 1998,
+ volume = 86,
+ number = 1,
+ pages = {82-85},
+ langid = {english},
+ langidopts = {variant=american},
+ related = {moore},
+ relatedtype = {reprintfrom},
+ annotation = {A reprint of Moore's law. Note the \texttt{related} and
+ \texttt{relatedtype} fields},
+}
+
+@book{nietzsche:ksa,
+ author = {Nietzsche, Friedrich},
+ title = {S{\"a}mtliche Werke},
+ date = 1988,
+ editor = {Colli, Giorgio and Montinari, Mazzino},
+ edition = 2,
+ volumes = 15,
+ publisher = dtv # { and Walter de Gruyter},
+ location = {M{\"u}nchen and Berlin and New York},
+ langid = {german},
+ sortyear = {1988-0},
+ sorttitle = {Werke-00-000},
+ indexsorttitle= {Samtliche Werke},
+ subtitle = {Kritische Studienausgabe},
+ annotation = {The critical edition of Nietzsche's works. This is a
+ \texttt{book} entry referring to a 15-volume work as a
+ whole. Note the \texttt{volumes} field and the format of the
+ \texttt{publisher} and \texttt{location} fields in the
+ database file. Also note the \texttt{sorttitle} and
+ \texttt{sortyear} fields which are used to fine-tune the
+ sorting order of the bibliography. We want this item listed
+ first in the bibliography},
+}
+
+@book{nietzsche:ksa1,
+ author = {Nietzsche, Friedrich},
+ title = {Die Geburt der Trag{\"o}die. Unzeitgem{\"a}{\ss}e
+ Betrachtungen I--IV. Nachgelassene Schriften 1870--1973},
+ date = 1988,
+ editor = {Colli, Giorgio and Montinari, Mazzino},
+ maintitle = {S{\"a}mtliche Werke},
+ mainsubtitle = {Kritische Studienausgabe},
+ volume = 1,
+ edition = 2,
+ publisher = dtv # { and Walter de Gruyter},
+ location = {M{\"u}nchen and Berlin and New York},
+ langid = {german},
+ sortyear = {1988-1},
+ sorttitle = {Werke-01-000},
+ indexsorttitle= {Samtliche Werke I},
+ bookauthor = {Nietzsche, Friedrich},
+ indextitle = {S{\"a}mtliche Werke I},
+ shorttitle = {S{\"a}mtliche Werke I},
+ annotation = {A single volume from the critical edition of Nietzsche's
+ works. This \texttt{book} entry explicitly refers to the first
+ volume only. Note the \texttt{title} and \texttt{maintitle}
+ fields. Also note the \texttt{sorttitle} and \texttt{sortyear}
+ fields. We want this entry to be listed after the entry
+ referring to the entire edition},
+}
+
+@book{nussbaum,
+ author = {Nussbaum, Martha},
+ title = {Aristotle's \mkbibquote{De Motu Animalium}},
+ date = 1978,
+ publisher = pup,
+ location = {Princeton},
+ keywords = {secondary},
+ langid = {english},
+ langidopts = {variant=american},
+ sorttitle = {Aristotle's De Motu Animalium},
+ indexsorttitle= {Aristotle's De Motu Animalium},
+ annotation = {A \texttt{book} entry. Note the \texttt{sorttitle} and
+ \texttt{indexsorttitle} fields and the markup of the quotes in
+ the database file},
+}
+
+@book{piccato,
+ author = {Piccato, Pablo},
+ title = {City of Suspects},
+ date = 2001,
+ publisher = {Duke University Press},
+ location = {Durham and London},
+ langid = {english},
+ langidopts = {variant=american},
+ subtitle = {Crime in {Mexico City}, 1900--1931},
+ shorttitle = {City of Suspects},
+ annotation = {This is a \texttt{book} entry. Note the format of the
+ \texttt{location} field in the database file},
+}
+
+@book{vangennep,
+ author = {van Gennep, Arnold},
+ title = {Les rites de passage},
+ date = 1909,
+ publisher = {Nourry},
+ location = {Paris},
+ options = {useprefix},
+ langid = {french},
+ sorttitle = {Rites de passage},
+ indextitle = {Rites de passage, Les},
+ shorttitle = {Rites de passage},
+ annotation = {A \texttt{book} entry. Note the format of the printed name and
+ compare the \texttt{useprefix} option in the \texttt{options}
+ field as well as \texttt{brandt} and \texttt{geer}},
+}
+
+@book{vangennep:trans,
+ author = {van Gennep, Arnold},
+ title = {The Rites of Passage},
+ year = 1960,
+ translator = {Vizedom, Monika B. and Caffee, Gabrielle L.},
+ language = {english},
+ origlanguage = {french},
+ publisher = {University of Chicago Press},
+ options = {useprefix},
+ indextitle = {Rites of Passage, The},
+ sorttitle = {Rites of Passage},
+ shorttitle = {Rites of Passage},
+ langid = {english},
+ langidopts = {variant=american},
+ annotation = {A translation of the \texttt{vangennep} entry. Note the
+ \texttt{translator} and \texttt{origlanguage} fields. Compare
+ with the \texttt{vangennep:related} entry.},
+}
+
+@book{vangennep:related,
+ author = {van Gennep, Arnold},
+ title = {Les rites de passage},
+ date = 1909,
+ publisher = {Nourry},
+ location = {Paris},
+ options = {useprefix},
+ langid = {french},
+ related = {vizedom:related},
+ relatedtype = {bytranslator},
+ sorttitle = {Rites de passage},
+ indextitle = {Rites de passage, Les},
+ shorttitle = {Rites de passage},
+ annotation = {A variant of the \texttt{vangennep} entry related to its
+ translation. Note the format of the \texttt{related} and
+ \texttt{relatedtype} fields},
+}
+
+@book{vizedom:related,
+ title = {The Rites of Passage},
+ year = 1960,
+ translator = {Vizedom, Monika B. and Caffee, Gabrielle L.},
+ language = {english},
+ publisher = {University of Chicago Press},
+ langid = {english},
+ langidopts = {variant=american},
+ options = {usetranslator},
+ related = {vangennep},
+ relatedtype = {translationof},
+ indextitle = {Rites of Passage, The},
+ sorttitle = {Rites of Passage},
+ shorttitle = {Rites of Passage},
+ annotation = {A translated work from \texttt{vangennep}. Note the format of
+ the \texttt{related} and \texttt{relatedtype} fields},
+}
+
+@book{vazques-de-parga,
+ author = {V{\'a}zques{ de }Parga, Luis and Lacarra, Jos{\'e} Mar{\'i}a
+ and Ur{\'i}a R{\'i}u, Juan},
+ title = {Las Peregrinaciones a Santiago de Compostela},
+ date = 1993,
+ volumes = 3,
+ note = {Ed. facs. de la realizada en 1948--49},
+ publisher = {Iberdrola},
+ location = {Pamplona},
+ langid = {spanish},
+ sorttitle = {Peregrinaciones a Santiago de Compostela},
+ indextitle = {Peregrinaciones a Santiago de Compostela, Las},
+ shorttitle = {Peregrinaciones},
+ annotation = {A multivolume book cited as a whole. This is a \texttt{book}
+ entry with \texttt{volumes}, \texttt{note},
+ \texttt{sorttitle}, and \texttt{indextitle} fields},
+}
+
+@book{wilde,
+ author = {Wilde, Oscar},
+ title = {The Importance of Being Earnest: A Trivial Comedy for Serious
+ People},
+ year = 1899,
+ series = {English and {American} drama of the Nineteenth Century},
+ publisher = {Leonard Smithers {and} Company},
+ eprint = {4HIWAAAAYAAJ},
+ eprinttype = {googlebooks},
+ annotation = {A \texttt{book} with \texttt{eprint} and \texttt{eprinttype}
+ fields.},
+}
+
+@book{worman,
+ author = {Worman, Nancy},
+ title = {The Cast of Character},
+ date = 2002,
+ publisher = {University of Texas Press},
+ location = {Austin},
+ langid = {english},
+ langidopts = {variant=american},
+ sorttitle = {Cast of Character},
+ indextitle = {Cast of Character, The},
+ subtitle = {Style in {Greek} Literature},
+ shorttitle = {Cast of Character},
+ annotation = {A \texttt{book} entry. Note the \texttt{sorttitle} and
+ \texttt{indextitle} fields},
+}
+
+@collection{britannica,
+ editor = {Preece, Warren E.},
+ title = {The {New Encyclop{\ae}dia Britannica}},
+ date = 2003,
+ edition = 15,
+ volumes = 32,
+ publisher = {Encyclop{\ae}dia Britannica},
+ location = {Chicago, Ill.},
+ options = {useeditor=false},
+ label = {EB},
+ langid = {english},
+ langidopts = {variant=british},
+ sorttitle = {Encyclop{\ae}dia Britannica},
+ indextitle = {{Encyclop{\ae}dia Britannica}, The {New}},
+ shorttitle = {{Encyclop{\ae}dia Britannica}},
+ annotation = {This is a \texttt{collection} entry for an encyclopedia. Note
+ the \texttt{useeditor} option in the \texttt{options} field as
+ well as the \texttt{sorttitle} field. We want this entry to be
+ cited and alphabetized by title even though there is an
+ editor. In addition to that, we want the title to be
+ alphabetized under \enquote*{E} rather than \enquote*{T}. Also
+ note the \texttt{label} field which is provided for
+ author-year citation styles},
+}
+
+@collection{gaonkar,
+ editor = {Gaonkar, Dilip Parameshwar},
+ title = {Alternative Modernities},
+ date = 2001,
+ publisher = {Duke University Press},
+ location = {Durham and London},
+ isbn = {0-822-32714-7},
+ langid = {english},
+ langidopts = {variant=american},
+ annotation = {This is a \texttt{collection} entry. Note the format of the
+ \texttt{location} field in the database file as well as the
+ \texttt{isbn} field},
+}
+
+@InCollection{gaonkar:in,
+ author = {Gaonkar, Dilip Parameshwar},
+ editor = {Gaonkar, Dilip Parameshwar},
+ title = {On Alternative Modernities},
+ date = 2001,
+ booktitle = {Alternative Modernities},
+ publisher = {Duke University Press},
+ location = {Durham and London},
+ isbn = {0-822-32714-7},
+ pages = {1-23},
+}
+
+@collection{jaffe,
+ editor = {Jaff{\'e}, Philipp},
+ title = {Regesta Pontificum Romanorum ab condita ecclesia ad annum post
+ Christum natum \textsc{mcxcviii}},
+ date = {1885/1888},
+ editora = {Loewenfeld, Samuel and Kaltenbrunner, Ferdinand and Ewald,
+ Paul},
+ edition = 2,
+ volumes = 2,
+ location = {Leipzig},
+ langid = {latin},
+ editoratype = {redactor},
+ indextitle = {Regesta Pontificum Romanorum},
+ shorttitle = {Regesta Pontificum Romanorum},
+ annotation = {A \texttt{collection} entry with \texttt{edition} and
+ \texttt{volumes} fields. Note the \texttt{editora} and
+ \texttt{editoratype} fields},
+}
+
+@collection{westfahl:frontier,
+ editor = {Westfahl, Gary},
+ title = {Space and Beyond},
+ date = 2000,
+ subtitle = {The Frontier Theme in Science Fiction},
+ publisher = {Greenwood},
+ location = {Westport, Conn. and London},
+ langid = {english},
+ langidopts = {variant=american},
+ booktitle = {Space and Beyond},
+ booksubtitle = {The Frontier Theme in Science Fiction},
+ annotation = {This is a \texttt{collection} entry. Note the format of the
+ \texttt{location} field as well as the \texttt{subtitle} and
+ \texttt{booksubtitle} fields},
+}
+
+@inbook{kant:kpv,
+ title = {Kritik der praktischen Vernunft},
+ date = 1968,
+ author = {Kant, Immanuel},
+ booktitle = {Kritik der praktischen Vernunft. Kritik der Urtheilskraft},
+ bookauthor = {Kant, Immanuel},
+ maintitle = {Kants Werke. Akademie Textausgabe},
+ volume = 5,
+ publisher = {Walter de Gruyter},
+ location = {Berlin},
+ pages = {1-163},
+ shorthand = {KpV},
+ langid = {german},
+ shorttitle = {Kritik der praktischen Vernunft},
+ annotation = {An edition of Kant's \emph{Collected Works}, volume five. This
+ is an \texttt{inbook} entry which explicitly refers to the
+ \emph{Critique of Practical Reason} only, not to the entire
+ fifth volume. Note the \texttt{author} and \texttt{bookauthor}
+ fields in the database file. By default, the
+ \texttt{bookauthor} is omitted if the values of the
+ \texttt{author} and \texttt{bookauthor} fields are identical},
+}
+
+@inbook{kant:ku,
+ title = {Kritik der Urtheilskraft},
+ date = 1968,
+ author = {Kant, Immanuel},
+ booktitle = {Kritik der praktischen Vernunft. Kritik der Urtheilskraft},
+ bookauthor = {Kant, Immanuel},
+ maintitle = {Kants Werke. Akademie Textausgabe},
+ volume = 5,
+ publisher = {Walter de Gruyter},
+ location = {Berlin},
+ pages = {165-485},
+ shorthand = {KU},
+ langid = {german},
+ annotation = {An edition of Kant's \emph{Collected Works}, volume five. This
+ is an \texttt{inbook} entry which explicitly refers to the
+ \emph{Critique of Judgment} only, not to the entire fifth
+ volume},
+}
+
+@inbook{nietzsche:historie,
+ title = {Unzeitgem{\"a}sse Betrachtungen. Zweites St{\"u}ck},
+ date = 1988,
+ author = {Nietzsche, Friedrich},
+ booktitle = {Die Geburt der Trag{\"o}die. Unzeitgem{\"a}{\ss}e
+ Betrachtungen I--IV. Nachgelassene Schriften 1870--1973},
+ bookauthor = {Nietzsche, Friedrich},
+ editor = {Colli, Giorgio and Montinari, Mazzino},
+ subtitle = {Vom Nutzen und Nachtheil der Historie f{\"u}r das Leben},
+ maintitle = {S{\"a}mtliche Werke},
+ mainsubtitle = {Kritische Studienausgabe},
+ volume = 1,
+ publisher = dtv # { and Walter de Gruyter},
+ location = {M{\"u}nchen and Berlin and New York},
+ pages = {243-334},
+ langid = {german},
+ sortyear = {1988-2},
+ sorttitle = {Werke-01-243},
+ indexsorttitle= {Vom Nutzen und Nachtheil der Historie fur das Leben},
+ indextitle = {Vom Nutzen und Nachtheil der Historie f{\"u}r das Leben},
+ shorttitle = {Vom Nutzen und Nachtheil der Historie},
+ annotation = {A single essay from the critical edition of Nietzsche's works.
+ This \texttt{inbook} entry explicitly refers to an essay found
+ in the first volume. Note the \texttt{title},
+ \texttt{booktitle}, and \texttt{maintitle} fields. Also note
+ the \texttt{sorttitle} and \texttt{sortyear} fields. We want
+ this entry to be listed after the entry referring to the
+ entire first volume},
+}
+
+@incollection{brandt,
+ author = {von Brandt, Ahasver and Erich Hoffmann},
+ editor = {Ferdinand Seibt},
+ title = {Die nordischen L{\"a}nder von der Mitte des 11.~Jahrhunderts
+ bis 1448},
+ date = 1987,
+ booktitle = {Europa im Hoch- und Sp{\"a}tmittelalter},
+ series = {Handbuch der europ{\"a}ischen Geschichte},
+ number = 2,
+ publisher = {Klett-Cotta},
+ location = {Stuttgart},
+ pages = {884-917},
+ options = {useprefix=false},
+ langid = {german},
+ indexsorttitle= {Nordischen Lander von der Mitte des 11. Jahrhunderts bis
+ 1448},
+ indextitle = {Nordischen L{\"a}nder von der Mitte des 11.~Jahrhunderts bis
+ 1448, Die},
+ shorttitle = {Die nordischen L{\"a}nder},
+ annotation = {An \texttt{incollection} entry with a \texttt{series} and a
+ \texttt{number}. Note the format of the printed name and
+ compare the \texttt{useprefix} option in the \texttt{options}
+ field as well as \texttt{vangennep}. Also note the
+ \texttt{indextitle, and \texttt{indexsorttitle} fields}},
+}
+
+@incollection{hyman,
+ author = {Arthur Hyman},
+ editor = {O'Meara, Dominic J.},
+ title = {Aristotle's Theory of the Intellect and its Interpretation by
+ {Averroes}},
+ date = 1981,
+ booktitle = {Studies in {Aristotle}},
+ series = {Studies in Philosophy and the History of Philosophy},
+ number = 9,
+ publisher = {The Catholic University of America Press},
+ location = {Washington, D.C.},
+ pages = {161-191},
+ keywords = {secondary},
+ langid = {english},
+ langidopts = {variant=american},
+ indextitle = {Aristotle's Theory of the Intellect},
+ shorttitle = {Aristotle's Theory of the Intellect},
+ annotation = {An \texttt{incollection} entry with a \texttt{series} and
+ \texttt{number} field},
+}
+
+@incollection{pines,
+ author = {Pines, Shlomo},
+ editor = {Twersky, Isadore},
+ title = {The Limitations of Human Knowledge According to {Al-Farabi}, {ibn
+ Bajja}, and {Maimonides}},
+ date = 1979,
+ booktitle = {Studies in Medieval {Jewish} History and Literature},
+ publisher = hup,
+ location = {Cambridge, Mass.},
+ pages = {82-109},
+ keywords = {secondary},
+ langid = {english},
+ langidopts = {variant=american},
+ indextitle = {Limitations of Human Knowledge According to {Al-Farabi}, {ibn
+ Bajja}, and {Maimonides}, The},
+ shorttitle = {Limitations of Human Knowledge},
+ annotation = {A typical \texttt{incollection} entry. Note the
+ \texttt{indextitle} field},
+}
+
+@inproceedings{moraux,
+ author = {Moraux, Paul},
+ editor = {Lloyd, G. E. R. and Owen, G. E. L.},
+ title = {Le \emph{De Anima} dans la tradition gr{\`e}cque},
+ date = 1979,
+ booktitle = {Aristotle on Mind and the Senses},
+ subtitle = {Quelques aspects de l'interpretation du trait{\'e}, de
+ Theophraste {\`a} Themistius},
+ booktitleaddon= {Proceedings of the Seventh Symposium Aristotelicum},
+ eventdate = 1975,
+ publisher = cup,
+ location = {Cambridge},
+ pages = {281-324},
+ keywords = {secondary},
+ langid = {french},
+ indexsorttitle= {De Anima dans la tradition grecque},
+ indextitle = {\emph{De Anima} dans la tradition gr{\`e}cque, Le},
+ shorttitle = {\emph{De Anima} dans la tradition gr{\`e}cque},
+ annotation = {This is a typical \texttt{inproceedings} entry. Note the
+ \texttt{booksubtitle}, \texttt{shorttitle},
+ \texttt{indextitle}, and \texttt{indexsorttitle} fields. Also
+ note the \texttt{eventdate} field.},
+}
+
+@inproceedings{salam,
+ author = {Salam, Abdus},
+ editor = {Svartholm, Nils},
+ title = {Weak and Electromagnetic Interactions},
+ date = 1968,
+ booktitle = {Elementary particle theory},
+ booksubtitle = {Relativistic groups and analyticity},
+ booktitleaddon= {Proceedings of the {Eighth Nobel Symposium}},
+ eventdate = {1968-05-19/1968-05-25},
+ venue = {Aspen{\"a}sgarden, Lerum},
+ publisher = {Almquist \& Wiksell},
+ location = {Stockholm},
+ pages = {367-377},
+}
+
+@manual{cms,
+ title = {The {Chicago} Manual of Style},
+ date = 2003,
+ subtitle = {The Essential Guide for Writers, Editors, and Publishers},
+ edition = 15,
+ publisher = {University of Chicago Press},
+ location = {Chicago, Ill.},
+ isbn = {0-226-10403-6},
+ label = {CMS},
+ langid = {english},
+ langidopts = {variant=american},
+ sorttitle = {Chicago Manual of Style},
+ indextitle = {Chicago Manual of Style, The},
+ shorttitle = {Chicago Manual of Style},
+ annotation = {This is a \texttt{manual} entry without an \texttt{author} or
+ \texttt{editor}. Note the \texttt{label} field in the database
+ file which is provided for author-year citation styles. Also
+ note the \texttt{sorttitle} and \texttt{indextitle} fields. By
+ default, all entries without an \texttt{author} or
+ \texttt{editor} are alphabetized by \texttt{title} but we want
+ this entry to be alphabetized under \enquote*{C} rather than
+ \enquote*{T}. There's also an \texttt{isbn} field},
+}
+
+@online{baez/online,
+ author = {Baez, John C. and Lauda, Aaron D.},
+ title = {Higher-Dimensional Algebra {V}: 2-Groups},
+ date = {2004-10-27},
+ version = 3,
+ langid = {english},
+ langidopts = {variant=american},
+ eprinttype = {arxiv},
+ eprint = {math/0307200v3},
+ annotation = {An \texttt{online} reference from arXiv. Note the
+ \texttt{eprint} and \texttt{eprinttype} fields. Compare
+ \texttt{baez\slash article} which is the same item given as an
+ \texttt{article} entry with eprint information},
+}
+
+@online{ctan,
+ title = {CTAN},
+ date = 2006,
+ url = {http://www.ctan.org},
+ subtitle = {The {Comprehensive TeX Archive Network}},
+ urldate = {2006-10-01},
+ label = {CTAN},
+ langid = {english},
+ langidopts = {variant=american},
+ annotation = {This is an \texttt{online} entry. The \textsc{url}, which is
+ given in the \texttt{url} field, is transformed into a
+ clickable link if \texttt{hyperref} support has been
+ enabled. Note the format of the \texttt{urldate} field
+ (\texttt{yyyy-mm-dd}) in the database file. Also note the
+ \texttt{label} field which may be used as a fallback by
+ citation styles which need an \texttt{author} and\slash or a
+ \texttt{year}},
+}
+
+@online{itzhaki,
+ author = {Itzhaki, Nissan},
+ title = {Some remarks on {'t Hooft's} {S}-matrix for black holes},
+ date = {1996-03-11},
+ version = 1,
+ langid = {english},
+ langidopts = {variant=american},
+ eprinttype = {arxiv},
+ eprint = {hep-th/9603067},
+ annotation = {An \texttt{online} reference from arXiv. Note the
+ \texttt{eprint} and \texttt{eprinttype} fields. Also note that
+ the arXiv reference is transformed into a clickable link if
+ \texttt{hyperref} support has been enabled},
+ abstract = {We discuss the limitations of 't Hooft's proposal for the
+ black hole S-matrix. We find that the validity of the S-matrix
+ implies violation of the semi-classical approximation at
+ scales large compared to the Planck scale. We also show that
+ the effect of the centrifugal barrier on the S-matrix is
+ crucial even for large transverse distances.},
+}
+
+@online{markey,
+ author = {Markey, Nicolas},
+ title = {Tame the {BeaST}},
+ date = {2005-10-16},
+ url = {http://mirror.ctan.org/info/bibtex/tamethebeast/ttb_en.pdf},
+ subtitle = {The {B} to {X} of {BibTeX}},
+ version = {1.3},
+ urldate = {2006-10-01},
+ langid = {english},
+ langidopts = {variant=american},
+ sorttitle = {Tame the Beast},
+ annotation = {An \texttt{online} entry for a tutorial. Note the format of
+ the \texttt{date} field (\texttt{yyyy-mm-dd}) in the database
+ file.},
+}
+
+@online{wassenberg,
+ author = {Wassenberg, Jan and Sanders, Peter},
+ title = {Faster Radix Sort via Virtual Memory and Write-Combining},
+ date = {2010-08-17},
+ version = 1,
+ langid = {english},
+ langidopts = {variant=american},
+ eprinttype = {arxiv},
+ eprintclass = {cs.DS},
+ eprint = {1008.2849v1},
+ annotation = {A recent \texttt{online} reference from arXiv using the new
+ (April 2007 onward) identifier format. Note the
+ \texttt{eprint}, \texttt{eprinttype}, and \texttt{eprintclass}
+ fields. Also note that the arXiv reference is transformed into
+ a clickable link if \texttt{hyperref} support has been
+ enabled},
+ abstract = {Sorting algorithms are the deciding factor for the performance
+ of common operations such as removal of duplicates or database
+ sort-merge joins. This work focuses on 32-bit integer keys,
+ optionally paired with a 32-bit value. We present a fast radix
+ sorting algorithm that builds upon a microarchitecture-aware
+ variant of counting sort},
+}
+
+@patent{almendro,
+ author = {Almendro, Jos{\'e} L. and Mart{\'i}n, Jacinto and S{\'a}nchez,
+ Alberto and Nozal, Fernando},
+ title = {Elektromagnetisches Signalhorn},
+ number = {EU-29702195U},
+ date = 1998,
+ location = {countryfr and countryuk and countryde},
+ langid = {german},
+ annotation = {This is a \texttt{patent} entry with a \texttt{location}
+ field. The number is given in the \texttt{number} field. Note
+ the format of the \texttt{location} field in the database
+ file. Compare \texttt{laufenberg}, \texttt{sorace}, and
+ \texttt{kowalik}},
+}
+
+@patent{kowalik,
+ author = {Kowalik, F. and Isard, M.},
+ title = {Estimateur d'un d{\'e}faut de fonctionnement d'un modulateur
+ en quadrature et {\'e}tage de modulation l'utilisant},
+ number = 9500261,
+ date = {1995-01-11},
+ type = {patreqfr},
+ langid = {french},
+ indextitle = {Estimateur d'un d{\'e}faut de fonctionnement},
+ annotation = {This is a \texttt{patent} entry for a French patent request
+ with a full date. The number is given in the \texttt{number}
+ field. Note the format of the \texttt{type} and \texttt{date}
+ fields in the database file. Compare \texttt{almendro},
+ \texttt{laufenberg}, and \texttt{sorace}},
+}
+
+@patent{laufenberg,
+ author = {Laufenberg, Xaver and Eynius, Dominique and Suelzle, Helmut
+ and Usbeck, Stephan and Spaeth, Matthias and Neuser-Hoffmann,
+ Miriam and Myrzik, Christian and Schmid, Manfred and Nietfeld,
+ Franz and Thiel, Alexander and Braun, Harald and Ebner,
+ Norbert},
+ title = {Elektrische Einrichtung und Betriebsverfahren},
+ number = 1700367,
+ date = {2006-09-13},
+ holder = {{Robert Bosch GmbH} and {Daimler Chrysler AG} and {Bayerische
+ Motoren Werke AG}},
+ type = {patenteu},
+ langid = {german},
+ annotation = {This is a \texttt{patent} entry with a \texttt{holder} field.
+ Note the format of the \texttt{type} and \texttt{location}
+ fields in the database file. Compare \texttt{almendro},
+ \texttt{sorace}, and \texttt{kowalik}},
+ abstract = {The invention relates to an electric device comprising a
+ generator, in particular for use in the vehicle electric
+ system of a motor vehicle and a controller for controlling the
+ generator voltage. The device is equipped with a control zone,
+ in which the voltage is controlled and zones, in which the
+ torque is controlled. The invention also relates to methods
+ for operating a device of this type.},
+ file = {http://v3.espacenet.com/textdoc?IDX=EP1700367},
+}
+
+@patent{sorace,
+ author = {Sorace, Ronald E. and Reinhardt, Victor S. and Vaughn, Steven
+ A.},
+ title = {High-Speed Digital-to-{RF} Converter},
+ number = 5668842,
+ date = {1997-09-16},
+ holder = {{Hughes Aircraft Company}},
+ type = {patentus},
+ langid = {english},
+ langidopts = {variant=american},
+ annotation = {This is a \texttt{patent} entry with a \texttt{holder} field.
+ Note the format of the \texttt{type} and \texttt{date} fields
+ in the database file. Compare \texttt{almendro},
+ \texttt{laufenberg}, and \texttt{kowalik}},
+}
+
+@periodical{jcg,
+ title = {Computers and Graphics},
+ year = 2011,
+ issuetitle = {Semantic {3D} Media and Content},
+ volume = 35,
+ number = 4,
+ issn = {0097-8493},
+ annotation = {This is a \texttt{periodical} entry with an \texttt{issn}
+ field.},
+}
+
+@report{chiu,
+ author = {Chiu, Willy W. and Chow, We Min},
+ title = {A Hybrid Hierarchical Model of a {Multiple Virtual Storage}
+ ({MVS}) Operating System},
+ type = {resreport},
+ institution = {IBM},
+ date = 1978,
+ number = {RC-6947},
+ langid = {english},
+ langidopts = {variant=american},
+ sorttitle = {Hybrid Hierarchical Model of a Multiple Virtual Storage (MVS)
+ Operating System},
+ indextitle = {Hybrid Hierarchical Model, A},
+ annotation = {This is a \texttt{report} entry for a research report. Note
+ the format of the \texttt{type} field in the database file
+ which uses a localization key. The number of the report is
+ given in the \texttt{number} field. Also note the
+ \texttt{sorttitle} and \texttt{indextitle} fields},
+}
+
+@report{padhye,
+ author = {Padhye, Jitendra and Firoiu, Victor and Towsley, Don},
+ title = {A Stochastic Model of {TCP Reno} Congestion Avoidance and
+ Control},
+ type = {techreport},
+ institution = {University of Massachusetts},
+ date = 1999,
+ number = {99-02},
+ location = {Amherst, Mass.},
+ langid = {english},
+ langidopts = {variant=american},
+ sorttitle = {A Stochastic Model of TCP Reno Congestion Avoidance and
+ Control},
+ indextitle = {Stochastic Model of {TCP Reno} Congestion Avoidance and Control,
+ A},
+ annotation = {This is a \texttt{report} entry for a technical report. Note
+ the format of the \texttt{type} field in the database file
+ which uses a localization key. The number of the report is
+ given in the \texttt{number} field. Also note the
+ \texttt{sorttitle} and \texttt{indextitle} fields},
+ abstract = {The steady state performance of a bulk transfer TCP flow
+ (i.e. a flow with a large amount of data to send, such as FTP
+ transfers) may be characterized by three quantities. The first
+ is the send rate, which is the amount of data sent by the
+ sender in unit time. The second is the throughput, which is
+ the amount of data received by the receiver in unit time. Note
+ that the throughput will always be less than or equal to the
+ send rate due to losses. Finally, the number of non-duplicate
+ packets received by the receiver in unit time gives us the
+ goodput of the connection. The goodput is always less than or
+ equal to the throughput, since the receiver may receive two
+ copies of the same packet due to retransmissions by the
+ sender. In a previous paper, we presented a simple model for
+ predicting the steady state send rate of a bulk transfer TCP
+ flow as a function of loss rate and round trip time. In this
+ paper, we extend that work in two ways. First, we analyze the
+ performance of bulk transfer TCP flows using more precise,
+ stochastic analysis. Second, we build upon the previous
+ analysis to provide both an approximate formula as well as a
+ more accurate stochastic model for the steady state throughput
+ of a bulk transfer TCP flow.},
+ file = {ftp://gaia.cs.umass.edu/pub/Padhey99-markov.ps},
+}
+
+@thesis{geer,
+ author = {de Geer, Ingrid},
+ title = {Earl, Saint, Bishop, Skald~-- and Music},
+ type = {phdthesis},
+ institution = {Uppsala Universitet},
+ date = 1985,
+ subtitle = {The {Orkney Earldom} of the Twelfth Century. {A} Musicological
+ Study},
+ location = {Uppsala},
+ options = {useprefix=false},
+ langid = {english},
+ langidopts = {variant=british},
+ annotation = {This is a typical \texttt{thesis} entry for a PhD thesis. Note
+ the \texttt{type} field in the database file which uses a
+ localization key. Also note the format of the printed name and
+ compare the \texttt{useprefix} option in the \texttt{options}
+ field as well as \texttt{vangennep}},
+}
+
+@thesis{loh,
+ author = {Loh, Nin C.},
+ title = {High-Resolution Micromachined Interferometric Accelerometer},
+ type = {mathesis},
+ institution = {Massachusetts Institute of Technology},
+ date = 1992,
+ location = {Cambridge, Mass.},
+ langid = {english},
+ langidopts = {variant=american},
+ annotation = {This is a typical \texttt{thesis} entry for an MA thesis. Note
+ the \texttt{type} field in the database file which uses a
+ localization key},
+}
diff --git a/test/command/biblatex-formatting.md b/test/command/biblatex-formatting.md
new file mode 100644
index 000000000..1fbd5a6a1
--- /dev/null
+++ b/test/command/biblatex-formatting.md
@@ -0,0 +1,23 @@
+```
+% pandoc -f biblatex -t markdown -s
+@article{item1,
+ Title = {The Title:
+ \textit{italics},
+ \textbf{bold},
+ \textsubscript{subscript},
+ \textsuperscript{superscript},
+ \textsc{small-caps}}
+}
+^D
+---
+nocite: '[@*]'
+references:
+- id: item1
+ title: 'The title: *Italics*, **bold**, ~subscript~, ^superscript^,
+ [small-caps]{.smallcaps}'
+ title-short: The title
+ type: 'article-journal'
+---
+
+
+```
diff --git a/test/command/biblatex-gaonkar-in.md b/test/command/biblatex-gaonkar-in.md
new file mode 100644
index 000000000..5073fc884
--- /dev/null
+++ b/test/command/biblatex-gaonkar-in.md
@@ -0,0 +1,62 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Gaonkar 2001)
+
+Gaonkar, Dilip Parameshwar. 2001. “On Alternative Modernities.” In
+*Alternative Modernities*, edited by Dilip Parameshwar Gaonkar, 1–23.
+Durham; London: Duke University Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Gaonkar, 2001)
+
+Gaonkar, D. P. (2001). On alternative modernities. In D. P. Gaonkar
+(Ed.), *Alternative modernities* (pp. 1–23). Durham; London: Duke
+University Press.
+
+
+}
+
+@InCollection{gaonkar:in,
+ author = {Gaonkar, Dilip Parameshwar},
+ editor = {Gaonkar, Dilip Parameshwar},
+ title = {On Alternative Modernities},
+ date = 2001,
+ booktitle = {Alternative Modernities},
+ publisher = {Duke University Press},
+ location = {Durham and London},
+ isbn = {0-822-32714-7},
+ pages = {1-23},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Gaonkar
+ given: Dilip Parameshwar
+ container-title: Alternative modernities
+ editor:
+ - family: Gaonkar
+ given: Dilip Parameshwar
+ id: 'gaonkar:in'
+ isbn: '0-822-32714-7'
+ issued: 2001
+ page: '1-23'
+ publisher: Duke University Press
+ publisher-place: Durham; London
+ title: On alternative modernities
+ type: chapter
+---
+
+
+```
diff --git a/test/command/biblatex-gaonkar.md b/test/command/biblatex-gaonkar.md
new file mode 100644
index 000000000..102c52ebb
--- /dev/null
+++ b/test/command/biblatex-gaonkar.md
@@ -0,0 +1,59 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Gaonkar 2001)
+
+Gaonkar, Dilip Parameshwar, ed. 2001. *Alternative Modernities*. Durham;
+London: Duke University Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Gaonkar, 2001)
+
+Gaonkar, D. P. (Ed.). (2001). *Alternative modernities*. Durham; London:
+Duke University Press.
+
+
+}
+
+@Collection{gaonkar,
+ editor = {Gaonkar, Dilip Parameshwar},
+ title = {Alternative Modernities},
+ date = 2001,
+ publisher = {Duke University Press},
+ location = {Durham and London},
+ isbn = {0-822-32714-7},
+ hyphenation = {american},
+ annotation = {This is a collection entry. Note the format of the
+ location field in the database file as well as the
+ isbn field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a collection entry. Note the format of the location
+ field in the database file as well as the isbn field
+ editor:
+ - family: Gaonkar
+ given: Dilip Parameshwar
+ id: gaonkar
+ isbn: '0-822-32714-7'
+ issued: 2001
+ language: 'en-US'
+ publisher: Duke University Press
+ publisher-place: Durham; London
+ title: Alternative modernities
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-geer.md b/test/command/biblatex-geer.md
new file mode 100644
index 000000000..c3acec4fa
--- /dev/null
+++ b/test/command/biblatex-geer.md
@@ -0,0 +1,70 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Geer 1985)
+
+Geer, Ingrid de. 1985. “Earl, Saint, Bishop, Skald – and Music: The
+Orkney Earldom of the Twelfth Century. A Musicological Study.” PhD
+thesis, Uppsala: Uppsala Universitet.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Geer, 1985)
+
+Geer, I. de. (1985). *Earl, saint, bishop, skald – and music: The Orkney
+earldom of the twelfth century. A musicological study* (PhD thesis).
+Uppsala Universitet, Uppsala.
+
+
+}
+
+@Thesis{geer,
+ author = {de Geer, Ingrid},
+ title = {Earl, Saint, Bishop, Skald~-- and Music},
+ type = {phdthesis},
+ institution = {Uppsala Universitet},
+ date = 1985,
+ subtitle = {The {Orkney} Earldom of the Twelfth Century. {A} Musicological
+ Study},
+ location = {Uppsala},
+ options = {useprefix=false},
+ hyphenation = {british},
+ annotation = {This is a typical thesis entry for a PhD thesis. Note
+ the type field in the database file which uses a
+ localization key. Also note the format of the printed name and
+ compare the useprefix option in the options
+ field as well as vangennep},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a typical thesis entry for a PhD thesis. Note the type
+ field in the database file which uses a localization key. Also note
+ the format of the printed name and compare the useprefix option in
+ the options field as well as vangennep
+ author:
+ - dropping-particle: de
+ family: Geer
+ given: Ingrid
+ genre: PhD thesis
+ id: geer
+ issued: 1985
+ language: 'en-GB'
+ publisher: Uppsala Universitet
+ publisher-place: Uppsala
+ title: 'Earl, saint, bishop, skald -- and music: The Orkney earldom of
+ the twelfth century. A musicological study'
+ title-short: 'Earl, saint, bishop, skald -- and music'
+ type: thesis
+---
+
+
+```
diff --git a/test/command/biblatex-gerhardt.md b/test/command/biblatex-gerhardt.md
new file mode 100644
index 000000000..c4bc42802
--- /dev/null
+++ b/test/command/biblatex-gerhardt.md
@@ -0,0 +1,64 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Gerhardt 2000)
+
+Gerhardt, Michael J. 2000. *The Federal Appointments Process: A
+Constitutional and Historical Analysis*. Durham; London: Duke University
+Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Gerhardt, 2000)
+
+Gerhardt, M. J. (2000). *The federal appointments process: A
+constitutional and historical analysis*. Durham; London: Duke University
+Press.
+
+
+}
+
+@Book{gerhardt,
+ author = {Gerhardt, Michael J.},
+ title = {The Federal Appointments Process},
+ date = 2000,
+ publisher = {Duke University Press},
+ location = {Durham and London},
+ hyphenation = {american},
+ sorttitle = {Federal Appointments Process},
+ indextitle = {Federal Appointments Process, The},
+ subtitle = {A Constitutional and Historical Analysis},
+ shorttitle = {Federal Appointments Process},
+ annotation = {This is a book entry. Note the format of the
+ location field as well as the sorttitle and
+ indextitle fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a book entry. Note the format of the location field as
+ well as the sorttitle and indextitle fields
+ author:
+ - family: Gerhardt
+ given: Michael J.
+ id: gerhardt
+ issued: 2000
+ language: 'en-US'
+ publisher: Duke University Press
+ publisher-place: Durham; London
+ title: 'The federal appointments process: A constitutional and
+ historical analysis'
+ title-short: Federal appointments process
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-gillies.md b/test/command/biblatex-gillies.md
new file mode 100644
index 000000000..79d3f5949
--- /dev/null
+++ b/test/command/biblatex-gillies.md
@@ -0,0 +1,70 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Gillies 1933)
+
+Gillies, Alexander. 1933. “Herder and the Preparation of Goethe’s Idea
+of World Literature.” *Publications of the English Goethe Society, New
+Series* 9: 46–67.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Gillies, 1933)
+
+Gillies, A. (1933). Herder and the preparation of Goethe’s idea of world
+literature. *Publications of the English Goethe Society, new series*,
+*9*, 46–67.
+
+
+NOTES:
+
+- biblio2yaml
+ - "new series" is not pretty, but it’s the best we can do at the moment, given the limitations of CSL.
+
+}
+
+@Article{gillies,
+ author = {Gillies, Alexander},
+ title = {Herder and the Preparation of {Goethe}'s Idea of World
+ Literature},
+ journaltitle = {Publications of the English Goethe Society},
+ date = 1933,
+ series = {newseries},
+ volume = 9,
+ pages = {46-67},
+ hyphenation = {british},
+ annotation = {An article entry with a series and a
+ volume field. Note that format of the series
+ field in the database file},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: An article entry with a series and a volume field. Note that
+ format of the series field in the database file
+ author:
+ - family: Gillies
+ given: Alexander
+ collection-title: new series
+ container-title: Publications of the English Goethe Society
+ id: gillies
+ issued: 1933
+ language: 'en-GB'
+ page: '46-67'
+ title: 'Herder and the preparation of Goethe''s idea of world
+ literature'
+ type: 'article-journal'
+ volume: 9
+---
+
+
+```
diff --git a/test/command/biblatex-glashow.md b/test/command/biblatex-glashow.md
new file mode 100644
index 000000000..f8c23415c
--- /dev/null
+++ b/test/command/biblatex-glashow.md
@@ -0,0 +1,51 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Glashow 1961)
+
+Glashow, Sheldon. 1961. “Partial Symmetries of Weak Interactions.”
+*Nucl. Phys.* 22: 579–588.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Glashow, 1961)
+
+Glashow, S. (1961). Partial symmetries of weak interactions.
+*Nucl. Phys.*, *22*, 579–588.
+
+
+}
+
+@Article{glashow,
+ author = {Glashow, Sheldon},
+ title = {Partial Symmetries of Weak Interactions},
+ journaltitle = {Nucl.~Phys.},
+ date = 1961,
+ volume = 22,
+ pages = {579-588},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Glashow
+ given: Sheldon
+ container-title: Nucl. Phys.
+ id: glashow
+ issued: 1961
+ page: '579-588'
+ title: Partial symmetries of weak interactions
+ type: 'article-journal'
+ volume: 22
+---
+
+
+```
diff --git a/test/command/biblatex-gonzalez.md b/test/command/biblatex-gonzalez.md
new file mode 100644
index 000000000..981deba94
--- /dev/null
+++ b/test/command/biblatex-gonzalez.md
@@ -0,0 +1,62 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Gonzalez 2001)
+
+Gonzalez, Ray. 2001. *The Ghost of John Wayne and Other Stories*.
+Tucson: The University of Arizona Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Gonzalez, 2001)
+
+Gonzalez, R. (2001). *The ghost of John Wayne and other stories*.
+Tucson: The University of Arizona Press.
+
+}
+
+@Book{gonzalez,
+ author = {Gonzalez, Ray},
+ title = {The Ghost of {John Wayne} and Other Stories},
+ date = 2001,
+ publisher = {The University of Arizona Press},
+ location = {Tucson},
+ isbn = {0-816-52066-6},
+ hyphenation = {american},
+ sorttitle = {Ghost of John Wayne and Other Stories},
+ indextitle = {Ghost of {John Wayne} and Other Stories, The},
+ shorttitle = {Ghost of {John Wayne}},
+ annotation = {A collection of short stories. This is a book entry.
+ Note the sorttitle and indextitle fields in
+ the database file. There's also an isbn field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A collection of short stories. This is a book entry. Note the
+ sorttitle and indextitle fields in the database file. There''s also
+ an isbn field'
+ author:
+ - family: Gonzalez
+ given: Ray
+ id: gonzalez
+ isbn: '0-816-52066-6'
+ issued: 2001
+ language: 'en-US'
+ publisher: The University of Arizona Press
+ publisher-place: Tucson
+ title: The ghost of John Wayne and other stories
+ title-short: Ghost of John Wayne
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-hammond.md b/test/command/biblatex-hammond.md
new file mode 100644
index 000000000..77b898730
--- /dev/null
+++ b/test/command/biblatex-hammond.md
@@ -0,0 +1,63 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Hammond 1997)
+
+Hammond, Christopher. 1997. *The Basics of Crystallography and
+Diffraction*. Oxford: International Union of Crystallography; Oxford
+University Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Hammond, 1997)
+
+Hammond, C. (1997). *The basics of crystallography and diffraction*.
+Oxford: International Union of Crystallography; Oxford University Press.
+
+
+}
+
+@Book{hammond,
+ author = {Hammond, Christopher},
+ title = {The basics of crystallography and diffraction},
+ date = 1997,
+ publisher = {International Union of Crystallography and Oxford University
+ Press},
+ location = {Oxford},
+ hyphenation = {british},
+ sorttitle = {Basics of crystallography and diffraction},
+ indextitle = {Basics of crystallography and diffraction, The},
+ shorttitle = {Crystallography and diffraction},
+ annotation = {A book entry. Note the sorttitle and
+ indextitle fields as well as the format of the
+ publisher field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry. Note the sorttitle and indextitle fields as well
+ as the format of the publisher field
+ author:
+ - family: Hammond
+ given: Christopher
+ id: hammond
+ issued: 1997
+ language: 'en-GB'
+ publisher: International Union of Crystallography; Oxford University
+ Press
+ publisher-place: Oxford
+ title: The basics of crystallography and diffraction
+ title-short: Crystallography and diffraction
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-herrmann.md b/test/command/biblatex-herrmann.md
new file mode 100644
index 000000000..6445f270a
--- /dev/null
+++ b/test/command/biblatex-herrmann.md
@@ -0,0 +1,70 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Herrmann et al. 2006)
+
+Herrmann, Wolfgang A., Karl Öfele, Sabine K. Schneider, Eberhardt
+Herdtweck, and Stephan D. Hoffmann. 2006. “A Carbocyclic Carbene as an
+Efficient Catalyst Ligand for C–C Coupling Reactions.” *Angew. Chem.
+Int. Ed.* 45 (23): 3859–3862.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Herrmann, Öfele, Schneider, Herdtweck, & Hoffmann, 2006)
+
+Herrmann, W. A., Öfele, K., Schneider, S. K., Herdtweck, E., & Hoffmann,
+S. D. (2006). A carbocyclic carbene as an efficient catalyst ligand for
+C–C coupling reactions. *Angew. Chem. Int. Ed.*, *45*(23), 3859–3862.
+
+
+}
+
+@string{ anch-ie = {Angew.~Chem. Int.~Ed.} }
+
+@Article{herrmann,
+ author = {Herrmann, Wolfgang A. and {\"O}fele, Karl and Schneider,
+ Sabine K. and Herdtweck, Eberhardt and Hoffmann, Stephan D.},
+ title = {A carbocyclic carbene as an efficient catalyst ligand for {C--C}
+ coupling reactions},
+ journaltitle = anch-ie,
+ date = 2006,
+ volume = 45,
+ number = 23,
+ pages = {3859-3862},
+ indextitle = {Carbocyclic carbene as an efficient catalyst, A},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Herrmann
+ given: Wolfgang A.
+ - family: Öfele
+ given: Karl
+ - family: Schneider
+ given: Sabine K.
+ - family: Herdtweck
+ given: Eberhardt
+ - family: Hoffmann
+ given: Stephan D.
+ container-title: Angew. Chem. Int. Ed.
+ id: herrmann
+ issue: 23
+ issued: 2006
+ page: '3859-3862'
+ title: 'A carbocyclic carbene as an efficient catalyst ligand for C--C
+ coupling reactions'
+ type: 'article-journal'
+ volume: 45
+---
+
+
+```
diff --git a/test/command/biblatex-hyman.md b/test/command/biblatex-hyman.md
new file mode 100644
index 000000000..966dc9133
--- /dev/null
+++ b/test/command/biblatex-hyman.md
@@ -0,0 +1,79 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Hyman 1981)
+
+Hyman, Arthur. 1981. “Aristotle’s Theory of the Intellect and Its
+Interpretation by Averroes.” In *Studies in Aristotle*, edited by
+Dominic J. O’Meara, 161–191. Studies in Philosophy and the History of
+Philosophy 9. Washington, D.C.: The Catholic University of America
+Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Hyman, 1981)
+
+Hyman, A. (1981). Aristotle’s theory of the intellect and its
+interpretation by Averroes. In D. J. O’Meara (Ed.), *Studies in
+Aristotle* (pp. 161–191). Washington, D.C.: The Catholic University of
+America Press.
+
+
+}
+
+@InCollection{hyman,
+ author = {Arthur Hyman},
+ editor = {O'Meara, Dominic J.},
+ title = {Aristotle's Theory of the Intellect and its Interpretation by
+ {Averroes}},
+ date = 1981,
+ booktitle = {Studies in {Aristotle}},
+ series = {Studies in Philosophy and the History of Philosophy},
+ number = 9,
+ publisher = {The Catholic University of America Press},
+ location = {Washington, D.C.},
+ pages = {161-191},
+ keywords = {secondary},
+ hyphenation = {american},
+ indextitle = {Aristotle's Theory of the Intellect},
+ shorttitle = {Aristotle's Theory of the Intellect},
+ annotation = {An incollection entry with a series and
+ number field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: An incollection entry with a series and number field
+ author:
+ - family: Hyman
+ given: Arthur
+ collection-number: 9
+ collection-title: Studies in philosophy and the history of philosophy
+ container-title: Studies in Aristotle
+ editor:
+ - family: 'O''Meara'
+ given: Dominic J.
+ id: hyman
+ issued: 1981
+ keyword: secondary
+ language: 'en-US'
+ page: '161-191'
+ publisher: The Catholic University of America Press
+ publisher-place: 'Washington, D.C.'
+ title: 'Aristotle''s theory of the intellect and its interpretation by
+ Averroes'
+ title-short: 'Aristotle''s theory of the intellect'
+ type: chapter
+---
+
+
+```
diff --git a/test/command/biblatex-iliad.md b/test/command/biblatex-iliad.md
new file mode 100644
index 000000000..4497cf5c3
--- /dev/null
+++ b/test/command/biblatex-iliad.md
@@ -0,0 +1,68 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Homer 2004)
+
+Homer. 2004. *Die Ilias*. Translated by Wolfgang Schadewaldt. 3rd ed.
+Düsseldorf; Zürich: Artemis & Winkler.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Homer, 2004)
+
+Homer. (2004). *Die Ilias*. (W. Schadewaldt, trans.) (3rd ed.).
+Düsseldorf; Zürich: Artemis & Winkler.
+
+}
+
+@Book{iliad,
+ author = {Homer},
+ title = {Die Ilias},
+ date = 2004,
+ translator = {Schadewaldt, Wolfgang},
+ introduction = {Latacz, Joachim},
+ edition = 3,
+ publisher = {Artemis \& Winkler},
+ location = {D{\"u}sseldorf and Z{\"u}rich},
+ hyphenation = {german},
+ sorttitle = {Ilias},
+ indextitle = {Ilias, Die},
+ shorttitle = {Ilias},
+ annotation = {A German translation of the \emph{Iliad}. Note the
+ translator and introduction fields and the
+ format of the location field in the database
+ file. Also note the sorttitle and indextitle
+ fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A German translation of the *Iliad*. Note the translator and
+ introduction fields and the format of the location field in the
+ database file. Also note the sorttitle and indextitle fields'
+ author:
+ - family: Homer
+ edition: 3
+ id: iliad
+ issued: 2004
+ language: 'de-DE'
+ publisher: 'Artemis & Winkler'
+ publisher-place: Düsseldorf; Zürich
+ title: Die Ilias
+ title-short: Ilias
+ translator:
+ - family: Schadewaldt
+ given: Wolfgang
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-inbook-title-booktitle-maintitle-series-2.md b/test/command/biblatex-inbook-title-booktitle-maintitle-series-2.md
new file mode 100644
index 000000000..806cbb238
--- /dev/null
+++ b/test/command/biblatex-inbook-title-booktitle-maintitle-series-2.md
@@ -0,0 +1,48 @@
+```
+% pandoc -f biblatex -t markdown -s
+@inbook{item1,
+ Author = {Author, Al},
+ Bookauthor = {Bookauthor, Bob},
+ Booksubtitle = {Booksubtitle},
+ Booktitle = {Booktitle},
+ Booktitleaddon = {Booktitleaddon},
+ Date = {2011},
+ Hyphenation = {french},
+ Location = {Location},
+ Mainsubtitle = {Mainsubtitle},
+ Maintitle = {Maintitle},
+ Maintitleaddon = {Maintitleaddon},
+ Number = {3},
+ Publisher = {Publisher},
+ Series = {Series},
+ Subtitle = {Subtitle},
+ Title = {Title of the ``inbook'' Entry},
+ Titleaddon = {Titleaddon},
+ Volume = {4}}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Author
+ given: Al
+ collection-number: 3
+ collection-title: Series
+ container-author:
+ - family: Bookauthor
+ given: Bob
+ container-title: 'Maintitle: Mainsubtitle. Maintitleaddon'
+ id: item1
+ issued: 2011
+ language: 'fr-FR'
+ publisher: Publisher
+ publisher-place: Location
+ title: 'Title of the "inbook" Entry: Subtitle. Titleaddon'
+ type: chapter
+ volume: 4
+ volume-title: 'Booktitle: Booksubtitle. Booktitleaddon'
+---
+
+
+```
diff --git a/test/command/biblatex-inbook-title-booktitle-maintitle-series.md b/test/command/biblatex-inbook-title-booktitle-maintitle-series.md
new file mode 100644
index 000000000..bd428f672
--- /dev/null
+++ b/test/command/biblatex-inbook-title-booktitle-maintitle-series.md
@@ -0,0 +1,44 @@
+```
+% pandoc -f biblatex -t markdown -s
+@inbook{item1,
+ Author = {Author, Al},
+ Booksubtitle = {Booksubtitle},
+ Booktitle = {Booktitle},
+ Booktitleaddon = {Booktitleaddon},
+ Date = {2011},
+ Hyphenation = {french},
+ Location = {Location},
+ Mainsubtitle = {Mainsubtitle},
+ Maintitle = {Maintitle},
+ Maintitleaddon = {Maintitleaddon},
+ Number = {3},
+ Publisher = {Publisher},
+ Series = {Series},
+ Subtitle = {Subtitle},
+ Title = {Title of the ``inbook'' Entry},
+ Titleaddon = {Titleaddon},
+ Volume = {4}}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Author
+ given: Al
+ collection-number: 3
+ collection-title: Series
+ container-title: 'Maintitle: Mainsubtitle. Maintitleaddon'
+ id: item1
+ issued: 2011
+ language: 'fr-FR'
+ publisher: Publisher
+ publisher-place: Location
+ title: 'Title of the "inbook" Entry: Subtitle. Titleaddon'
+ type: chapter
+ volume: 4
+ volume-title: 'Booktitle: Booksubtitle. Booktitleaddon'
+---
+
+
+```
diff --git a/test/command/biblatex-inbook.md b/test/command/biblatex-inbook.md
new file mode 100644
index 000000000..7d2ee5b47
--- /dev/null
+++ b/test/command/biblatex-inbook.md
@@ -0,0 +1,147 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+adapted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib
+
+TODO / citeproc: in biblatex "inbook" entries, citeproc should suppress bookauthor = CSL container-author if identical with author. -- See annotation in kant:kpv.
+}
+
+@string{dtv = {Deutscher Taschenbuch-Verlag}}
+
+@inbook{kant:kpv,
+ Annotation = {An edition of Kant's \emph{Collected Works}, volume five. This is an inbook entry which explicitly refers to the \emph{Critique of Practical Reason} only, not to the entire fifth volume. Note the author and bookauthor fields in the database file. By default, the bookauthor is omitted if the values of the author and bookauthor fields are identical},
+ Author = {Kant, Immanuel},
+ Bookauthor = {Kant, Immanuel},
+ Booktitle = {Kritik der praktischen Vernunft. Kritik der Urtheilskraft},
+ Date = 1968,
+ Hyphenation = {german},
+ Location = {Berlin},
+ Maintitle = {Kants Werke. Akademie Textausgabe},
+ Pages = {1-163},
+ Publisher = {Walter de Gruyter},
+ Shorthand = {KpV},
+ Shorttitle = {Kritik der praktischen Vernunft},
+ Title = {Kritik der praktischen Vernunft},
+ Volume = 5}
+
+@inbook{kant:ku,
+ Annotation = {An edition of Kant's \emph{Collected Works}, volume five. This is an inbook entry which explicitly refers to the \emph{Critique of Judgment} only, not to the entire fifth volume},
+ Author = {Kant, Immanuel},
+ Bookauthor = {Kant, Immanuel},
+ Booktitle = {Kritik der praktischen Vernunft. Kritik der Urtheilskraft},
+ Date = 1968,
+ Hyphenation = {german},
+ Location = {Berlin},
+ Maintitle = {Kants Werke. Akademie Textausgabe},
+ Pages = {165-485},
+ Publisher = {Walter de Gruyter},
+ Shorthand = {KU},
+ Title = {Kritik der Urtheilskraft},
+ Volume = 5}
+
+@inbook{nietzsche:historie,
+ Annotation = {A single essay from the critical edition of Nietzsche's works. This inbook entry explicitly refers to an essay found in the first volume. Note the title, booktitle, and maintitle fields. Also note the sorttitle and sortyear fields. We want this entry to be listed after the entry referring to the entire first volume},
+ Author = {Nietzsche, Friedrich},
+ Bookauthor = {Nietzsche, Friedrich},
+ Booktitle = {Die Geburt der Tragödie. Unzeitgemäße Betrachtungen I--IV. Nachgelassene Schriften 1870--1973},
+ Date = 1988,
+ Editor = {Colli, Giorgio and Montinari, Mazzino},
+ Hyphenation = {german},
+ Indexsorttitle = {Vom Nutzen und Nachtheil der Historie fur das Leben},
+ Indextitle = {Vom Nutzen und Nachtheil der Historie für das Leben},
+ Location = {München and Berlin and New York},
+ Mainsubtitle = {Kritische Studienausgabe},
+ Maintitle = {Sämtliche Werke},
+ Pages = {243-334},
+ Publisher = dtv # { and Walter de Gruyter},
+ Shorttitle = {Vom Nutzen und Nachtheil der Historie},
+ Sorttitle = {Werke-01-243},
+ Sortyear = {1988-2},
+ Subtitle = {Vom Nutzen und Nachtheil der Historie für das Leben},
+ Title = {Unzeitgemässe Betrachtungen. Zweites Stück},
+ Volume = 1}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An edition of Kant''s *Collected Works*, volume five. This is
+ an inbook entry which explicitly refers to the *Critique of
+ Practical Reason* only, not to the entire fifth volume. Note the
+ author and bookauthor fields in the database file. By default, the
+ bookauthor is omitted if the values of the author and bookauthor
+ fields are identical'
+ author:
+ - family: Kant
+ given: Immanuel
+ container-author:
+ - family: Kant
+ given: Immanuel
+ container-title: Kants Werke. Akademie Textausgabe
+ id: 'kant:kpv'
+ issued: 1968
+ language: 'de-DE'
+ page: '1-163'
+ publisher: Walter de Gruyter
+ publisher-place: Berlin
+ title: Kritik der praktischen Vernunft
+ title-short: Kritik der praktischen Vernunft
+ type: chapter
+ volume: 5
+ volume-title: Kritik der praktischen Vernunft. Kritik der
+ Urtheilskraft
+- annote: 'An edition of Kant''s *Collected Works*, volume five. This is
+ an inbook entry which explicitly refers to the *Critique of
+ Judgment* only, not to the entire fifth volume'
+ author:
+ - family: Kant
+ given: Immanuel
+ container-author:
+ - family: Kant
+ given: Immanuel
+ container-title: Kants Werke. Akademie Textausgabe
+ id: 'kant:ku'
+ issued: 1968
+ language: 'de-DE'
+ page: '165-485'
+ publisher: Walter de Gruyter
+ publisher-place: Berlin
+ title: Kritik der Urtheilskraft
+ type: chapter
+ volume: 5
+ volume-title: Kritik der praktischen Vernunft. Kritik der
+ Urtheilskraft
+- annote: 'A single essay from the critical edition of Nietzsche''s
+ works. This inbook entry explicitly refers to an essay found in the
+ first volume. Note the title, booktitle, and maintitle fields. Also
+ note the sorttitle and sortyear fields. We want this entry to be
+ listed after the entry referring to the entire first volume'
+ author:
+ - family: Nietzsche
+ given: Friedrich
+ container-author:
+ - family: Nietzsche
+ given: Friedrich
+ container-title: 'Sämtliche Werke: Kritische Studienausgabe'
+ editor:
+ - family: Colli
+ given: Giorgio
+ - family: Montinari
+ given: Mazzino
+ id: 'nietzsche:historie'
+ issued: 1988
+ language: 'de-DE'
+ page: '243-334'
+ publisher: 'Deutscher Taschenbuch-Verlag; Walter de Gruyter'
+ publisher-place: München; Berlin; New York
+ title: 'Unzeitgemässe Betrachtungen. Zweites Stück: Vom Nutzen und
+ Nachtheil der Historie für das Leben'
+ title-short: Vom Nutzen und Nachtheil der Historie
+ type: chapter
+ volume: 1
+ volume-title: 'Die Geburt der Tragödie. Unzeitgemäße Betrachtungen
+ I--IV. Nachgelassene Schriften 1870--1973'
+---
+
+
+```
diff --git a/test/command/biblatex-incollection-2.md b/test/command/biblatex-incollection-2.md
new file mode 100644
index 000000000..495541035
--- /dev/null
+++ b/test/command/biblatex-incollection-2.md
@@ -0,0 +1,98 @@
+```
+% pandoc -f biblatex -t markdown -s
+
+@comment{adapted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib}
+
+
+@string{hup = {Harvard University Press}}
+
+
+@incollection{westfahl:space,
+ Annotation = {A cross-referenced article from a collection. This is an incollection entry with a crossref field. Note the subtitle and indextitle fields},
+ Author = {Westfahl, Gary},
+ Crossref = {westfahl:frontier},
+ Hyphenation = {american},
+ Indextitle = {True Frontier, The},
+ Pages = {55-65},
+ Subtitle = {Confronting and Avoiding the Realities of Space in {American} Science Fiction Films},
+ Title = {The True Frontier}}
+
+@incollection{gaonkar:in,
+ Author = {Gaonkar, Dilip Parameshwar},
+ Booktitle = {Alternative Modernities},
+ Date = 2001,
+ Editor = {Gaonkar, Dilip Parameshwar},
+ Isbn = {0-822-32714-7},
+ Location = {Durham and London},
+ Pages = {1-23},
+ Publisher = {Duke University Press},
+ Title = {On Alternative Modernities}}
+
+@collection{westfahl:frontier,
+ Annotation = {This is a collection entry. Note the format of the location field as well as the subtitle and booksubtitle fields},
+ Booksubtitle = {The Frontier Theme in Science Fiction},
+ Booktitle = {Space and Beyond},
+ Date = 2000,
+ Editor = {Westfahl, Gary},
+ Hyphenation = {american},
+ Location = {Westport, Conn. and London},
+ Publisher = {Greenwood},
+ Subtitle = {The Frontier Theme in Science Fiction},
+ Title = {Space and Beyond}}
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A cross-referenced article from a collection. This is an
+ incollection entry with a crossref field. Note the subtitle and
+ indextitle fields'
+ author:
+ - family: Westfahl
+ given: Gary
+ container-title: 'Space and beyond: The frontier theme in science
+ fiction'
+ editor:
+ - family: Westfahl
+ given: Gary
+ id: 'westfahl:space'
+ issued: 2000
+ language: 'en-US'
+ page: '55-65'
+ publisher: Greenwood
+ publisher-place: 'Westport, Conn.; London'
+ title: 'The true frontier: Confronting and avoiding the realities of
+ space in American science fiction films'
+ title-short: The true frontier
+ type: chapter
+- author:
+ - family: Gaonkar
+ given: Dilip Parameshwar
+ container-title: Alternative modernities
+ editor:
+ - family: Gaonkar
+ given: Dilip Parameshwar
+ id: 'gaonkar:in'
+ isbn: '0-822-32714-7'
+ issued: 2001
+ page: '1-23'
+ publisher: Duke University Press
+ publisher-place: Durham; London
+ title: On alternative modernities
+ type: chapter
+- annote: This is a collection entry. Note the format of the location
+ field as well as the subtitle and booksubtitle fields
+ editor:
+ - family: Westfahl
+ given: Gary
+ id: 'westfahl:frontier'
+ issued: 2000
+ language: 'en-US'
+ publisher: Greenwood
+ publisher-place: 'Westport, Conn.; London'
+ title: 'Space and beyond: The frontier theme in science fiction'
+ title-short: Space and beyond
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-incollection.md b/test/command/biblatex-incollection.md
new file mode 100644
index 000000000..128f2d4b4
--- /dev/null
+++ b/test/command/biblatex-incollection.md
@@ -0,0 +1,130 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{adapted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib}
+
+@string{hup = {Harvard University Press}}
+
+@incollection{brandt,
+ Annotation = {An incollection entry with a series and a number. Note the format of the printed name and compare the useprefix option in the options field as well as vangennep. Also note the indextitle, and indexsorttitle fields},
+ Author = {von Brandt, Ahasver and Hoffmann, Erich},
+ Booktitle = {Europa im Hoch- und Spätmittelalter},
+ Date = 1987,
+ Editor = {Seibt, Ferdinand},
+ Hyphenation = {german},
+ Indexsorttitle = {Nordischen Lander von der Mitte des 11. Jahrhunderts bis 1448},
+ Indextitle = {Nordischen Länder von der Mitte des 11.~Jahrhunderts bis 1448, Die},
+ Location = {Stuttgart},
+ Number = 2,
+ Options = {useprefix=false},
+ Pages = {884-917},
+ Publisher = {Klett-Cotta},
+ Series = {Handbuch der europäischen Geschichte},
+ Shorttitle = {Die nordischen Länder},
+ Title = {Die nordischen Länder von der Mitte des 11.~Jahrhunderts bis 1448}}
+
+@incollection{hyman,
+ Annotation = {An incollection entry with a series and number field},
+ Author = {Hyman, Arthur},
+ Booktitle = {Studies in {Aristotle}},
+ Date = 1981,
+ Editor = {O'Meara, Dominic J.},
+ Hyphenation = {american},
+ Indextitle = {Aristotle's Theory of the Intellect},
+ Keywords = {secondary},
+ Location = {Washington, D.C.},
+ Number = 9,
+ Pages = {161-191},
+ Publisher = {The Catholic University of America Press},
+ Series = {Studies in Philosophy and the History of Philosophy},
+ Shorttitle = {Aristotle's Theory of the Intellect},
+ Title = {Aristotle's Theory of the Intellect and its Interpretation by {Averroes}}}
+
+@incollection{pines,
+ Annotation = {A typical incollection entry. Note the indextitle field},
+ Author = {Pines, Shlomo},
+ Booktitle = {Studies in Medieval {Jewish} History and Literature},
+ Date = 1979,
+ Editor = {Twersky, Isadore},
+ Hyphenation = {american},
+ Indextitle = {Limitations of Human Knowledge According to Al-Farabi, ibn Bajja, and Maimonides, The},
+ Keywords = {secondary},
+ Location = {Cambridge, Mass.},
+ Pages = {82-109},
+ Publisher = hup,
+ Shorttitle = {Limitations of Human Knowledge},
+ Title = {The Limitations of Human Knowledge According to {Al-Farabi}, {ibn Bajja}, and {Maimonides}}}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An incollection entry with a series and a number. Note the
+ format of the printed name and compare the useprefix option in the
+ options field as well as vangennep. Also note the indextitle, and
+ indexsorttitle fields'
+ author:
+ - dropping-particle: von
+ family: Brandt
+ given: Ahasver
+ - family: Hoffmann
+ given: Erich
+ collection-number: 2
+ collection-title: Handbuch der europäischen Geschichte
+ container-title: 'Europa im Hoch- und Spätmittelalter'
+ editor:
+ - family: Seibt
+ given: Ferdinand
+ id: brandt
+ issued: 1987
+ language: 'de-DE'
+ page: '884-917'
+ publisher: 'Klett-Cotta'
+ publisher-place: Stuttgart
+ title: Die nordischen Länder von der Mitte des 11. Jahrhunderts bis
+ 1448
+ title-short: Die nordischen Länder
+ type: chapter
+- annote: An incollection entry with a series and number field
+ author:
+ - family: Hyman
+ given: Arthur
+ collection-number: 9
+ collection-title: Studies in philosophy and the history of philosophy
+ container-title: Studies in Aristotle
+ editor:
+ - family: 'O''Meara'
+ given: Dominic J.
+ id: hyman
+ issued: 1981
+ keyword: secondary
+ language: 'en-US'
+ page: '161-191'
+ publisher: The Catholic University of America Press
+ publisher-place: 'Washington, D.C.'
+ title: 'Aristotle''s theory of the intellect and its interpretation by
+ Averroes'
+ title-short: 'Aristotle''s theory of the intellect'
+ type: chapter
+- annote: A typical incollection entry. Note the indextitle field
+ author:
+ - family: Pines
+ given: Shlomo
+ container-title: Studies in medieval Jewish history and literature
+ editor:
+ - family: Twersky
+ given: Isadore
+ id: pines
+ issued: 1979
+ keyword: secondary
+ language: 'en-US'
+ page: '82-109'
+ publisher: Harvard University Press
+ publisher-place: 'Cambridge, Mass.'
+ title: 'The limitations of human knowledge according to Al-Farabi,
+ [ibn Bajja]{.nocase}, and Maimonides'
+ title-short: Limitations of human knowledge
+ type: chapter
+---
+
+
+```
diff --git a/test/command/biblatex-inproceedings.md b/test/command/biblatex-inproceedings.md
new file mode 100644
index 000000000..2c48ab5bf
--- /dev/null
+++ b/test/command/biblatex-inproceedings.md
@@ -0,0 +1,88 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{adapted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib}
+
+@string{cup = {Cambridge University Press}}
+
+@inproceedings{moraux,
+ Annotation = {This is a typical inproceedings entry. Note the booksubtitle, shorttitle, indextitle, and indexsorttitle fields. Also note the eventdate field.},
+ Author = {Moraux, Paul},
+ Booktitle = {Aristotle on Mind and the Senses},
+ Booktitleaddon = {Proceedings of the Seventh Symposium Aristotelicum},
+ Date = 1979,
+ Editor = {Lloyd, G. E. R. and Owen, G. E. L.},
+ Eventdate = 1975,
+ Hyphenation = {french},
+ Indexsorttitle = {De Anima dans la tradition grecque},
+ Indextitle = {\emph{De Anima} dans la tradition grècque, Le},
+ Keywords = {secondary},
+ Location = {Cambridge},
+ Pages = {281-324},
+ Publisher = cup,
+ Shorttitle = {\emph{De Anima} dans la tradition grècque},
+ Subtitle = {Quelques aspects de l'interpretation du traité, de Theophraste à Themistius},
+ Title = {Le \emph{De Anima} dans la tradition grècque}}
+
+@inproceedings{salam,
+ Author = {Salam, Abdus},
+ Booksubtitle = {Relativistic groups and analyticity},
+ Booktitle = {Elementary particle theory},
+ Booktitleaddon = {Proceedings of the Eighth {Nobel} Symposium},
+ Date = 1968,
+ Editor = {Svartholm, Nils},
+ Eventdate = {1968-05-19/1968-05-25},
+ Location = {Stockholm},
+ Pages = {367-377},
+ Publisher = {Almquist \& Wiksell},
+ Title = {Weak and Electromagnetic Interactions},
+ Venue = {Aspenäsgarden, Lerum}}
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'This is a typical inproceedings entry. Note the booksubtitle,
+ shorttitle, indextitle, and indexsorttitle fields. Also note the
+ eventdate field.'
+ author:
+ - family: Moraux
+ given: Paul
+ container-title: Aristotle on Mind and the Senses. Proceedings of the
+ Seventh Symposium Aristotelicum
+ editor:
+ - family: Lloyd
+ given: G. E. R.
+ - family: Owen
+ given: G. E. L.
+ event-date: 1975
+ id: moraux
+ issued: 1979
+ keyword: secondary
+ language: 'fr-FR'
+ page: '281-324'
+ publisher: Cambridge University Press
+ publisher-place: Cambridge
+ title: 'Le *De Anima* dans la tradition grècque: Quelques aspects de
+ l''interpretation du traité, de Theophraste à Themistius'
+ title-short: '*De Anima* dans la tradition grècque'
+ type: 'paper-conference'
+- author:
+ - family: Salam
+ given: Abdus
+ container-title: 'Elementary particle theory: Relativistic groups and
+ analyticity. Proceedings of the eighth Nobel symposium'
+ editor:
+ - family: Svartholm
+ given: Nils
+ event-date: '1968-05-19/1968-05-25'
+ event-place: 'Aspenäsgarden, Lerum'
+ id: salam
+ issued: 1968
+ page: '367-377'
+ publisher: 'Almquist & Wiksell'
+ publisher-place: Stockholm
+ title: Weak and electromagnetic interactions
+ type: 'paper-conference'
+---
+
+
+```
diff --git a/test/command/biblatex-issue288.md b/test/command/biblatex-issue288.md
new file mode 100644
index 000000000..115b0012a
--- /dev/null
+++ b/test/command/biblatex-issue288.md
@@ -0,0 +1,35 @@
+```
+% pandoc -f biblatex -t markdown -s
+@thesis{Leavitt_2016,
+location = {{Los Angeles, CA}},
+title = {Upvoting the News: {{Breaking}} News Aggregation, Crowd Collaboration,
+and Algorithm-Driven Attention on Reddit.Com},
+timestamp = {2017-04-06T14:13:22Z},
+langid = {english},
+institution = {{University of Southern California}},
+type = {Dissertation},
+author = {Leavitt, Alex},
+date = {2016-08},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Leavitt
+ given: Alex
+ genre: Dissertation
+ id: Leavitt_2016
+ issued: '2016-08'
+ language: 'en-US'
+ publisher: University of Southern California
+ publisher-place: 'Los Angeles, CA'
+ title: 'Upvoting the news: Breaking news aggregation, crowd
+ collaboration, and algorithm-driven attention on reddit.com'
+ title-short: Upvoting the news
+ type: thesis
+---
+
+
+```
diff --git a/test/command/biblatex-itzhaki.md b/test/command/biblatex-itzhaki.md
new file mode 100644
index 000000000..29921404c
--- /dev/null
+++ b/test/command/biblatex-itzhaki.md
@@ -0,0 +1,83 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Itzhaki 1996)
+
+Itzhaki, Nissan. 1996. “Some Remarks on ’t Hooft’s S-matrix for Black
+Holes” (version 1). March 11.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Itzhaki, 1996)
+
+Itzhaki, N. (1996, March 11). Some remarks on ’t Hooft’s S-matrix for
+black holes.
+
+
+NOTES:
+
+- biblio2yaml:
+ - eprinttype = {arxiv}, eprint = {hep-th/9603067},
+ should be converted to a url: http://arxiv.org/abs/hep-th/9603067
+ (prefix http://arxiv.org/abs/ seems to work for all arxiv material)
+
+- citeproc:
+ - obtaining correct case of "'t Hooft's" in title is possible but awkward:
+ '{t Hooft's} works; {'t Hooft}'s or '{t Hooft}'s do not
+
+}
+
+@Online{itzhaki,
+ author = {Itzhaki, Nissan},
+ title = {Some remarks on '{t Hooft's} {S}-matrix for black holes},
+ date = {1996-03-11},
+ version = 1,
+ hyphenation = {american},
+ eprinttype = {arxiv},
+ eprint = {hep-th/9603067},
+ annotation = {An online reference from arXiv. Note the
+ eprint and eprinttype fields. Also note that
+ the arXiv reference is transformed into a clickable link if
+ hyperref support has been enabled},
+ abstract = {We discuss the limitations of 't Hooft's proposal for the
+ black hole S-matrix. We find that the validity of the S-matrix
+ implies violation of the semi-classical approximation at
+ scales large compared to the Planck scale. We also show that
+ the effect of the centrifugal barrier on the S-matrix is
+ crucial even for large transverse distances.},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- abstract: 'We discuss the limitations of ''t Hooft''s proposal for the
+ black hole S-matrix. We find that the validity of the S-matrix
+ implies violation of the semi-classical approximation at scales
+ large compared to the Planck scale. We also show that the effect of
+ the centrifugal barrier on the S-matrix is crucial even for large
+ transverse distances.'
+ annote: An online reference from arXiv. Note the eprint and eprinttype
+ fields. Also note that the arXiv reference is transformed into a
+ clickable link if hyperref support has been enabled
+ author:
+ - family: Itzhaki
+ given: Nissan
+ id: itzhaki
+ issued: '1996-03-11'
+ language: 'en-US'
+ title: 'Some remarks on ''[t Hooft''s]{.nocase} S-matrix for black
+ holes'
+ type: webpage
+ url: 'http://arxiv.org/abs/hep-th/9603067'
+ version: 1
+---
+
+
+```
diff --git a/test/command/biblatex-jaffe.md b/test/command/biblatex-jaffe.md
new file mode 100644
index 000000000..cf9bb09bb
--- /dev/null
+++ b/test/command/biblatex-jaffe.md
@@ -0,0 +1,82 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Jaffé 1885–1888)
+
+Jaffé, Philipp, ed. 1885–1888. *Regesta Pontificum Romanorum ab condita
+ecclesia ad annum post Christum natum \<span
+Style="font-variant:small-caps;"\>mcxcviii\</span\>*. 2nd ed. 2.
+Leipzig.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Jaffé, 1885–1888)
+
+Jaffé, P. (Ed.). (1885–1888). *Regesta Pontificum Romanorum ab condita
+ecclesia ad annum post Christum natum \<span
+style="font-variant:small-caps;"\>mcxcviii\</span\>* (2nd ed., 1-2).
+Leipzig.
+
+
+NOTES:
+
+- biblatex conversion:
+ - hyphenation = {latin}
+- citeproc:
+ - "vols." is missing
+ - works in Zotero
+ - This does not show up in the tests from the citeproc test suite that currently fail.
+ - "\<span ...\> needs to be fixed.
+ - maybe add markdown syntax ^^small caps^^ ?
+ - in pandoc "plain" output, small caps could be converted to uppercase chars: "MCXCVIII" would definitely look better here.
+
+}
+
+@Collection{jaffe,
+ editor = {Jaff{\'e}, Philipp},
+ title = {Regesta Pontificum Romanorum ab condita ecclesia ad annum post
+ Christum natum \textsc{mcxcviii}},
+ date = {1885/1888},
+ editora = {Loewenfeld, Samuel and Kaltenbrunner, Ferdinand and Ewald,
+ Paul},
+ edition = 2,
+ volumes = 2,
+ location = {Leipzig},
+ editoratype = {redactor},
+ indextitle = {Regesta Pontificum Romanorum},
+ shorttitle = {Regesta Pontificum Romanorum},
+ annotation = {A collection entry with edition and
+ volumes fields. Note the editora and
+ editoratype fields},
+ hyphenation = {latin},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A collection entry with edition and volumes fields. Note the
+ editora and editoratype fields
+ edition: 2
+ editor:
+ - family: Jaffé
+ given: Philipp
+ id: jaffe
+ issued: 1885/1888
+ language: la
+ number-of-volumes: 2
+ publisher-place: Leipzig
+ title: 'Regesta Pontificum Romanorum ab condita ecclesia ad annum post
+ Christum natum [mcxcviii]{.smallcaps}'
+ title-short: Regesta Pontificum Romanorum
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-jcg.md b/test/command/biblatex-jcg.md
new file mode 100644
index 000000000..509039f98
--- /dev/null
+++ b/test/command/biblatex-jcg.md
@@ -0,0 +1,54 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(“Semantic 3D Media and Content” 2011)
+
+“Semantic 3D Media and Content.” 2011. *Computers and Graphics* 35 (4).
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(“Semantic 3D media and content,” 2011)
+
+Semantic 3D media and content. (2011). *Computers and Graphics*,
+*35*(4).
+
+
+NOTES:
+ - output looks OK even if indistinguishable from article without page numbers
+
+}
+
+@Periodical{jcg,
+ title = {Computers and Graphics},
+ year = 2011,
+ issuetitle = {Semantic {3D} Media and Content},
+ volume = 35,
+ number = 4,
+ issn = {0097-8493},
+ annotation = {This is a periodical entry with an issn
+ field.},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a periodical entry with an issn field.
+ container-title: Computers and Graphics
+ id: jcg
+ issn: '0097-8493'
+ issue: 4
+ issued: 2011
+ title: Semantic 3D media and content
+ type: 'article-journal'
+ volume: 35
+---
+
+
+```
diff --git a/test/command/biblatex-kant-kpv.md b/test/command/biblatex-kant-kpv.md
new file mode 100644
index 000000000..678d656b2
--- /dev/null
+++ b/test/command/biblatex-kant-kpv.md
@@ -0,0 +1,90 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Kant 1968)
+
+Kant, Immanuel. 1968. “Kritik der praktischen Vernunft.” In *Kants
+Werke. Akademie Textausgabe*, by Immanuel Kant, 5:1–163. Berlin: Walter
+de Gruyter.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Kant, 1968)
+
+Kant, I. (1968). Kritik der praktischen Vernunft. In *Kants Werke.
+Akademie Textausgabe* (Vol. 5, pp. 1–163). Berlin: Walter de Gruyter.
+
+
+NOTES:
+
+- citeproc
+ - support for the not yet official "volume-title" is missing
+
+- csl style file
+ - if author and container-author are identical, container-author should be suppressed (apparently csl style file issue; zotero shows same behaviour)
+
+}
+
+@InBook{kant:kpv,
+ title = {Kritik der praktischen Vernunft},
+ date = 1968,
+ author = {Kant, Immanuel},
+ booktitle = {Kritik der praktischen Vernunft. Kritik der Urtheilskraft},
+ bookauthor = {Kant, Immanuel},
+ maintitle = {Kants Werke. Akademie Textausgabe},
+ volume = 5,
+ publisher = {Walter de Gruyter},
+ location = {Berlin},
+ pages = {1-163},
+ shorthand = {KpV},
+ hyphenation = {german},
+ shorttitle = {Kritik der praktischen Vernunft},
+ annotation = {An edition of Kant's \emph{Collected Works}, volume five. This
+ is an inbook entry which explicitly refers to the
+ \emph{Critique of Practical Reason} only, not to the entire
+ fifth volume. Note the author and bookauthor
+ fields in the database file. By default, the
+ bookauthor is omitted if the values of the
+ author and bookauthor fields are identical},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An edition of Kant''s *Collected Works*, volume five. This is
+ an inbook entry which explicitly refers to the *Critique of
+ Practical Reason* only, not to the entire fifth volume. Note the
+ author and bookauthor fields in the database file. By default, the
+ bookauthor is omitted if the values of the author and bookauthor
+ fields are identical'
+ author:
+ - family: Kant
+ given: Immanuel
+ container-author:
+ - family: Kant
+ given: Immanuel
+ container-title: Kants Werke. Akademie Textausgabe
+ id: 'kant:kpv'
+ issued: 1968
+ language: 'de-DE'
+ page: '1-163'
+ publisher: Walter de Gruyter
+ publisher-place: Berlin
+ title: Kritik der praktischen Vernunft
+ title-short: Kritik der praktischen Vernunft
+ type: chapter
+ volume: 5
+ volume-title: Kritik der praktischen Vernunft. Kritik der
+ Urtheilskraft
+---
+
+
+```
diff --git a/test/command/biblatex-kant-ku.md b/test/command/biblatex-kant-ku.md
new file mode 100644
index 000000000..57a023d68
--- /dev/null
+++ b/test/command/biblatex-kant-ku.md
@@ -0,0 +1,82 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Kant 1968)
+
+Kant, Immanuel. 1968. “Kritik der Urtheilskraft.” In *Kants Werke.
+Akademie Textausgabe*, by Immanuel Kant, 5:165–485. Berlin: Walter de
+Gruyter.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Kant, 1968)
+
+Kant, I. (1968). Kritik der Urtheilskraft. In *Kants Werke. Akademie
+Textausgabe* (Vol. 5, pp. 165–485). Berlin: Walter de Gruyter.
+
+
+NOTES:
+
+- citeproc
+ - support for the not yet official "volume-title" is missing
+
+- CSL style file
+ - if author and container-author are identical, container-author should be suppressed (apparently csl style file issue; zotero shows same behaviour)
+
+}
+
+@InBook{kant:ku,
+ title = {Kritik der Urtheilskraft},
+ date = 1968,
+ author = {Kant, Immanuel},
+ booktitle = {Kritik der praktischen Vernunft. Kritik der Urtheilskraft},
+ bookauthor = {Kant, Immanuel},
+ maintitle = {Kants Werke. Akademie Textausgabe},
+ volume = 5,
+ publisher = {Walter de Gruyter},
+ location = {Berlin},
+ pages = {165-485},
+ shorthand = {KU},
+ hyphenation = {german},
+ annotation = {An edition of Kant's \emph{Collected Works}, volume five. This
+ is an inbook entry which explicitly refers to the
+ \emph{Critique of Judgment} only, not to the entire fifth
+ volume},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An edition of Kant''s *Collected Works*, volume five. This is
+ an inbook entry which explicitly refers to the *Critique of
+ Judgment* only, not to the entire fifth volume'
+ author:
+ - family: Kant
+ given: Immanuel
+ container-author:
+ - family: Kant
+ given: Immanuel
+ container-title: Kants Werke. Akademie Textausgabe
+ id: 'kant:ku'
+ issued: 1968
+ language: 'de-DE'
+ page: '165-485'
+ publisher: Walter de Gruyter
+ publisher-place: Berlin
+ title: Kritik der Urtheilskraft
+ type: chapter
+ volume: 5
+ volume-title: Kritik der praktischen Vernunft. Kritik der
+ Urtheilskraft
+---
+
+
+```
diff --git a/test/command/biblatex-kastenholz.md b/test/command/biblatex-kastenholz.md
new file mode 100644
index 000000000..bd3c1463c
--- /dev/null
+++ b/test/command/biblatex-kastenholz.md
@@ -0,0 +1,126 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Kastenholz and Hünenberger 2006)
+
+Kastenholz, M. A., and Philippe H. Hünenberger. 2006. “Computation of
+Methodologyindependent Ionic Solvation Free Energies from Molecular
+Simulations: I. the Electrostatic Potential in Molecular Liquids.”
+*J. Chem. Phys.* 124.
+doi:[10.1063/1.2172593](https://doi.org/10.1063/1.2172593 "10.1063/1.2172593").
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Kastenholz & Hünenberger, 2006)
+
+Kastenholz, M. A., & Hünenberger, P. H. (2006). Computation of
+methodologyindependent ionic solvation free energies from molecular
+simulations: I. the electrostatic potential in molecular liquids.
+*J. Chem. Phys.*, *124*.
+doi:[10.1063/1.2172593](https://doi.org/10.1063/1.2172593 "10.1063/1.2172593")
+
+
+NOTES:
+
+- biblio2xaml
+ - fix conversion of "\hyphen”
+ - the string "doi:" should not appear as part of the content of the "doi" field
+
+}
+
+@string{ jchph = {J.~Chem. Phys.} }
+
+@Article{kastenholz,
+ author = {Kastenholz, M. A. and H{\"u}nenberger, Philippe H.},
+ title = {Computation of methodology\hyphen independent ionic solvation
+ free energies from molecular simulations},
+ journaltitle = jchph,
+ date = 2006,
+ subtitle = {I. {The} electrostatic potential in molecular liquids},
+ volume = 124,
+ eid = 124106,
+ doi = {10.1063/1.2172593},
+ hyphenation = {american},
+ indextitle = {Computation of ionic solvation free energies},
+ annotation = {An article entry with an eid and a
+ doi field. Note that the \textsc{doi} is transformed
+ into a clickable link if hyperref support has been
+ enabled},
+ abstract = {The computation of ionic solvation free energies from
+ atomistic simulations is a surprisingly difficult problem that
+ has found no satisfactory solution for more than 15 years. The
+ reason is that the charging free energies evaluated from such
+ simulations are affected by very large errors. One of these is
+ related to the choice of a specific convention for summing up
+ the contributions of solvent charges to the electrostatic
+ potential in the ionic cavity, namely, on the basis of point
+ charges within entire solvent molecules (M scheme) or on the
+ basis of individual point charges (P scheme). The use of an
+ inappropriate convention may lead to a charge-independent
+ offset in the calculated potential, which depends on the
+ details of the summation scheme, on the quadrupole-moment
+ trace of the solvent molecule, and on the approximate form
+ used to represent electrostatic interactions in the
+ system. However, whether the M or P scheme (if any) represents
+ the appropriate convention is still a matter of on-going
+ debate. The goal of the present article is to settle this
+ long-standing controversy by carefully analyzing (both
+ analytically and numerically) the properties of the
+ electrostatic potential in molecular liquids (and inside
+ cavities within them).},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- abstract: 'The computation of ionic solvation free energies from
+ atomistic simulations is a surprisingly difficult problem that has
+ found no satisfactory solution for more than 15 years. The reason is
+ that the charging free energies evaluated from such simulations are
+ affected by very large errors. One of these is related to the choice
+ of a specific convention for summing up the contributions of solvent
+ charges to the electrostatic potential in the ionic cavity, namely,
+ on the basis of point charges within entire solvent molecules (M
+ scheme) or on the basis of individual point charges (P scheme). The
+ use of an inappropriate convention may lead to a charge-independent
+ offset in the calculated potential, which depends on the details of
+ the summation scheme, on the quadrupole-moment trace of the solvent
+ molecule, and on the approximate form used to represent
+ electrostatic interactions in the system. However, whether the M or
+ P scheme (if any) represents the appropriate convention is still a
+ matter of on-going debate. The goal of the present article is to
+ settle this long-standing controversy by carefully analyzing (both
+ analytically and numerically) the properties of the electrostatic
+ potential in molecular liquids (and inside cavities within them).'
+ annote: 'An article entry with an eid and a doi field. Note that the
+ [doi]{.smallcaps} is transformed into a clickable link if hyperref
+ support has been enabled'
+ author:
+ - family: Kastenholz
+ given: M. A.
+ - family: Hünenberger
+ given: Philippe H.
+ container-title: J. Chem. Phys.
+ doi: 10.1063/1.2172593
+ id: kastenholz
+ issued: 2006
+ language: 'en-US'
+ title: 'Computation of methodology-independent ionic solvation free
+ energies from molecular simulations: I. The electrostatic potential
+ in molecular liquids'
+ title-short: 'Computation of methodology-independent ionic solvation
+ free energies from molecular simulations'
+ type: 'article-journal'
+ volume: 124
+---
+
+
+```
diff --git a/test/command/biblatex-knuth-ct-a.md b/test/command/biblatex-knuth-ct-a.md
new file mode 100644
index 000000000..ffcc09ea6
--- /dev/null
+++ b/test/command/biblatex-knuth-ct-a.md
@@ -0,0 +1,78 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Knuth 1984)
+
+Knuth, Donald E. 1984. *Computers & Typesetting*. Vol. A. Reading,
+Mass.: Addison-Wesley.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Knuth, 1984)
+
+Knuth, D. E. (1984). *Computers & typesetting* (Vol. A). Reading, Mass.:
+Addison-Wesley.
+
+
+NOTES:
+
+- volume-title currently not implemented by chicago-author-date.csl and apa.csl.
+
+}
+
+@Book{knuth:ct:a,
+ author = {Knuth, Donald E.},
+ title = {The {\TeX} book},
+ date = 1984,
+ maintitle = {Computers \& Typesetting},
+ volume = {A},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ hyphenation = {american},
+ sortyear = {1984-1},
+ sorttitle = {Computers & Typesetting A},
+ indexsorttitle= {The TeXbook},
+ indextitle = {\protect\TeX book, The},
+ shorttitle = {\TeX book},
+ annotation = {The first volume of a five-volume book. Note the
+ sorttitle and sortyear fields. We want this
+ volume to be listed after the entry referring to the entire
+ five-volume set. Also note the indextitle and
+ indexsorttitle fields. Indexing packages that don't
+ generate robust index entries require some control sequences
+ to be protected from expansion},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'The first volume of a five-volume book. Note the sorttitle
+ and sortyear fields. We want this volume to be listed after the
+ entry referring to the entire five-volume set. Also note the
+ indextitle and indexsorttitle fields. Indexing packages that don''t
+ generate robust index entries require some control sequences to be
+ protected from expansion'
+ author:
+ - family: Knuth
+ given: Donald E.
+ id: 'knuth:ct:a'
+ issued: 1984
+ language: 'en-US'
+ publisher: 'Addison-Wesley'
+ publisher-place: 'Reading, Mass.'
+ title: 'Computers & typesetting'
+ type: book
+ volume: A
+ volume-title: The TeX book
+---
+
+
+```
diff --git a/test/command/biblatex-knuth-ct-b.md b/test/command/biblatex-knuth-ct-b.md
new file mode 100644
index 000000000..59b50b580
--- /dev/null
+++ b/test/command/biblatex-knuth-ct-b.md
@@ -0,0 +1,70 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2015-03-08:
+
+(Knuth 1986)
+
+Knuth, Donald E. 1986. *Computers & Typesetting*. Vol. B. Reading,
+Mass.: Addison-Wesley.
+
+
+Formatted with pandoc and apa.csl, 2015-03-08:
+
+(Knuth, 1986)
+
+Knuth, D. E. (1986). *Computers & typesetting* (Vol. B). Reading, Mass.:
+Addison-Wesley.
+
+
+NOTES:
+
+- volume-title currently not implemented by chicago-author-date.csl and apa.csl.
+
+}
+
+@Book{knuth:ct:b,
+ author = {Knuth, Donald E.},
+ title = {\TeX: {T}he Program},
+ date = 1986,
+ maintitle = {Computers \& Typesetting},
+ volume = {B},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ hyphenation = {american},
+ sortyear = {1986-1},
+ sorttitle = {Computers & Typesetting B},
+ indexsorttitle= {TeX: The Program},
+ shorttitle = {\TeX},
+ annotation = {The second volume of a five-volume book. Note the
+ sorttitle and sortyear fields. Also note the
+ indexsorttitle field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'The second volume of a five-volume book. Note the sorttitle
+ and sortyear fields. Also note the indexsorttitle field'
+ author:
+ - family: Knuth
+ given: Donald E.
+ id: 'knuth:ct:b'
+ issued: 1986
+ language: 'en-US'
+ publisher: 'Addison-Wesley'
+ publisher-place: 'Reading, Mass.'
+ title: 'Computers & typesetting'
+ title-short: TeX
+ type: book
+ volume: B
+ volume-title: 'TeX: The program'
+---
+
+
+```
diff --git a/test/command/biblatex-knuth-ct-c.md b/test/command/biblatex-knuth-ct-c.md
new file mode 100644
index 000000000..181076b5f
--- /dev/null
+++ b/test/command/biblatex-knuth-ct-c.md
@@ -0,0 +1,69 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2015-03-08:
+
+(Knuth 1986)
+
+Knuth, Donald E. 1986. *Computers & Typesetting*. Vol. C. Reading,
+Mass.: Addison-Wesley.
+
+
+Formatted with pandoc and apa.csl, 2015-03-08:
+
+(Knuth, 1986)
+
+Knuth, D. E. (1986). *Computers & typesetting* (Vol. C). Reading, Mass.:
+Addison-Wesley.
+
+
+NOTES:
+
+- volume-title currently not implemented by chicago-author-date.csl and apa.csl.
+
+}
+
+@Book{knuth:ct:c,
+ author = {Knuth, Donald E.},
+ title = {The {METAFONTbook}},
+ date = 1986,
+ maintitle = {Computers \& Typesetting},
+ volume = {C},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ hyphenation = {american},
+ sortyear = {1986-2},
+ sorttitle = {Computers & Typesetting C},
+ indextitle = {METAFONTbook, The},
+ shorttitle = {{METAFONTbook}},
+ annotation = {The third volume of a five-volume book. Note the
+ sorttitle and sortyear fields as well as the
+ indextitle field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'The third volume of a five-volume book. Note the sorttitle
+ and sortyear fields as well as the indextitle field'
+ author:
+ - family: Knuth
+ given: Donald E.
+ id: 'knuth:ct:c'
+ issued: 1986
+ language: 'en-US'
+ publisher: 'Addison-Wesley'
+ publisher-place: 'Reading, Mass.'
+ title: 'Computers & typesetting'
+ type: book
+ volume: C
+ volume-title: The METAFONTbook
+---
+
+
+```
diff --git a/test/command/biblatex-knuth-ct-d.md b/test/command/biblatex-knuth-ct-d.md
new file mode 100644
index 000000000..b8e297162
--- /dev/null
+++ b/test/command/biblatex-knuth-ct-d.md
@@ -0,0 +1,71 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2015-03-08:
+
+(Knuth 1986)
+
+Knuth, Donald E. 1986. *Computers & Typesetting*. Vol. D. Reading,
+Mass.: Addison-Wesley.
+
+
+Formatted with pandoc and apa.csl, 2015-03-08:
+
+(Knuth, 1986)
+
+Knuth, D. E. (1986). *Computers & typesetting* (Vol. D). Reading, Mass.:
+Addison-Wesley.
+
+
+NOTES:
+
+- biblio2yaml
+ - Should letters following a colon, such as the "T" in "{{METAFONT}: {T}he Program}" be protected by default? -- I'm not sure ...
+
+- volume-title currently not implemented by chicago-author-date.csl and apa.csl.
+
+}
+
+@Book{knuth:ct:d,
+ author = {Knuth, Donald E.},
+ title = {{METAFONT}: {T}he Program},
+ date = 1986,
+ maintitle = {Computers \& Typesetting},
+ volume = {D},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ hyphenation = {american},
+ sortyear = {1986-3},
+ sorttitle = {Computers & Typesetting D},
+ shorttitle = {{METAFONT}},
+ annotation = {The fourth volume of a five-volume book. Note the
+ sorttitle and sortyear fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'The fourth volume of a five-volume book. Note the sorttitle
+ and sortyear fields'
+ author:
+ - family: Knuth
+ given: Donald E.
+ id: 'knuth:ct:d'
+ issued: 1986
+ language: 'en-US'
+ publisher: 'Addison-Wesley'
+ publisher-place: 'Reading, Mass.'
+ title: 'Computers & typesetting'
+ title-short: METAFONT
+ type: book
+ volume: D
+ volume-title: 'METAFONT: The program'
+---
+
+
+```
diff --git a/test/command/biblatex-knuth-ct-e.md b/test/command/biblatex-knuth-ct-e.md
new file mode 100644
index 000000000..26c156375
--- /dev/null
+++ b/test/command/biblatex-knuth-ct-e.md
@@ -0,0 +1,66 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2015-03-08:
+
+(Knuth 1986)
+
+Knuth, Donald E. 1986. *Computers & Typesetting*. Vol. E. Reading,
+Mass.: Addison-Wesley.
+
+
+Formatted with pandoc and apa.csl, 2015-03-08:
+
+(Knuth, 1986)
+
+Knuth, D. E. (1986). *Computers & typesetting* (Vol. E). Reading, Mass.:
+Addison-Wesley.
+
+
+NOTES:
+
+- volume-title currently not implemented by chicago-author-date.csl and apa.csl.
+
+}
+
+@Book{knuth:ct:e,
+ author = {Knuth, Donald E.},
+ title = {Computer Modern Typefaces},
+ date = 1986,
+ maintitle = {Computers \& Typesetting},
+ volume = {E},
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ hyphenation = {american},
+ sortyear = {1986-4},
+ sorttitle = {Computers & Typesetting E},
+ annotation = {The fifth volume of a five-volume book. Note the
+ sorttitle and sortyear fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'The fifth volume of a five-volume book. Note the sorttitle
+ and sortyear fields'
+ author:
+ - family: Knuth
+ given: Donald E.
+ id: 'knuth:ct:e'
+ issued: 1986
+ language: 'en-US'
+ publisher: 'Addison-Wesley'
+ publisher-place: 'Reading, Mass.'
+ title: 'Computers & typesetting'
+ type: book
+ volume: E
+ volume-title: Computer modern typefaces
+---
+
+
+```
diff --git a/test/command/biblatex-knuth-ct-related.md b/test/command/biblatex-knuth-ct-related.md
new file mode 100644
index 000000000..4c5ce19f9
--- /dev/null
+++ b/test/command/biblatex-knuth-ct-related.md
@@ -0,0 +1,72 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Knuth 1984–1986)
+
+Knuth, Donald E. 1984–1986. *Computers & Typesetting*. 5. Reading,
+Mass.: Addison-Wesley.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Knuth, 1984–1986)
+
+Knuth, D. E. (1984–1986). *Computers & typesetting* (1-5). Reading,
+Mass.: Addison-Wesley.
+
+
+NOTES:
+
+- biblio2yaml
+ - related = {...}, relatedtype = {multivolume}, -- no counterpart in CSL
+
+- citeproc
+ - term "vols." missing
+
+}
+
+@Book{knuth:ct:related,
+ author = {Knuth, Donald E.},
+ title = {Computers \& Typesetting},
+ date = {1984/1986},
+ volumes = 5,
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ hyphenation = {american},
+ sortyear = {1984-0},
+ sorttitle = {Computers & Typesetting},
+ indexsorttitle= {Computers & Typesetting},
+ related = {knuth:ct:a,knuth:ct:b,knuth:ct:c,knuth:ct:d,knuth:ct:e},
+ relatedtype = {multivolume},
+ annotation = {A five-volume book cited as a whole and related to its
+ individual volumes. Note the related and
+ relatedtype fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A five-volume book cited as a whole and related to its
+ individual volumes. Note the related and relatedtype fields'
+ author:
+ - family: Knuth
+ given: Donald E.
+ id: 'knuth:ct:related'
+ issued: 1984/1986
+ language: 'en-US'
+ number-of-volumes: 5
+ publisher: 'Addison-Wesley'
+ publisher-place: 'Reading, Mass.'
+ title: 'Computers & typesetting'
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-knuth-ct.md b/test/command/biblatex-knuth-ct.md
new file mode 100644
index 000000000..856fe54f7
--- /dev/null
+++ b/test/command/biblatex-knuth-ct.md
@@ -0,0 +1,66 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Knuth 1984–1986)
+
+Knuth, Donald E. 1984–1986. *Computers & Typesetting*. 5. Reading,
+Mass.: Addison-Wesley.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Knuth, 1984–1986)
+
+Knuth, D. E. (1984–1986). *Computers & typesetting* (1-5). Reading,
+Mass.: Addison-Wesley.
+
+
+NOTES:
+
+- citeproc
+ - term "vols." is missing
+
+}
+
+@Book{knuth:ct,
+ author = {Knuth, Donald E.},
+ title = {Computers \& Typesetting},
+ date = {1984/1986},
+ volumes = 5,
+ publisher = {Addison-Wesley},
+ location = {Reading, Mass.},
+ hyphenation = {american},
+ sortyear = {1984-0},
+ sorttitle = {Computers & Typesetting},
+ indexsorttitle= {Computers & Typesetting},
+ annotation = {A five-volume book cited as a whole. This is a book
+ entry, note the volumes field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A five-volume book cited as a whole. This is a book entry,
+ note the volumes field'
+ author:
+ - family: Knuth
+ given: Donald E.
+ id: 'knuth:ct'
+ issued: 1984/1986
+ language: 'en-US'
+ number-of-volumes: 5
+ publisher: 'Addison-Wesley'
+ publisher-place: 'Reading, Mass.'
+ title: 'Computers & typesetting'
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-kowalik.md b/test/command/biblatex-kowalik.md
new file mode 100644
index 000000000..605d03a1c
--- /dev/null
+++ b/test/command/biblatex-kowalik.md
@@ -0,0 +1,68 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Kowalik and Isard 1995)
+
+Kowalik, F., and M. Isard. 1995. “Estimateur d’un défaut de
+fonctionnement d’un modulateur en quadrature et étage de modulation
+l’utilisant.” French patent request.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Kowalik & Isard, 1995)
+
+Kowalik, F., & Isard, M. (1995, January 11). Estimateur d’un défaut de
+fonctionnement d’un modulateur en quadrature et étage de modulation
+l’utilisant. French patent request.
+
+
+}
+
+@Patent{kowalik,
+ author = {Kowalik, F. and Isard, M.},
+ title = {Estimateur d'un d{\'e}faut de fonctionnement d'un modulateur
+ en quadrature et {\'e}tage de modulation l'utilisant},
+ number = 9500261,
+ date = {1995-01-11},
+ type = {patreqfr},
+ hyphenation = {french},
+ indextitle = {Estimateur d'un d{\'e}faut de fonctionnement},
+ annotation = {This is a patent entry for a French patent request
+ with a full date. The number is given in the number
+ field. Note the format of the type and date
+ fields in the database file. Compare almendro,
+ laufenberg, and sorace},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'This is a patent entry for a French patent request with a
+ full date. The number is given in the number field. Note the format
+ of the type and date fields in the database file. Compare almendro,
+ laufenberg, and sorace'
+ author:
+ - family: Kowalik
+ given: F.
+ - family: Isard
+ given: M.
+ genre: French patent request
+ id: kowalik
+ issued: '1995-01-11'
+ language: 'fr-FR'
+ number: 9500261
+ title: 'Estimateur d''un défaut de fonctionnement d''un modulateur en
+ quadrature et étage de modulation l''utilisant'
+ type: patent
+---
+
+
+```
diff --git a/test/command/biblatex-kullback-related.md b/test/command/biblatex-kullback-related.md
new file mode 100644
index 000000000..f7cffa7e5
--- /dev/null
+++ b/test/command/biblatex-kullback-related.md
@@ -0,0 +1,62 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Kullback 1997)
+
+Kullback, Solomon. 1997. *Information Theory and Statistics*. New York:
+Dover Publications.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Kullback, 1997)
+
+Kullback, S. (1997). *Information theory and statistics*. New York:
+Dover Publications.
+
+
+NOTES:
+
+- related = {kullback}, relatedtype = {origpubin}, -- not possible in CSL
+
+}
+
+@Book{kullback:related,
+ author = {Kullback, Solomon},
+ title = {Information Theory and Statistics},
+ year = 1997,
+ publisher = {Dover Publications},
+ location = {New York},
+ hyphenation = {american},
+ related = {kullback},
+ relatedtype = {origpubin},
+ annotation = {A reprint of the kullback entry. Note the format of
+ the related and relatedtype fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A reprint of the kullback entry. Note the format of the
+ related and relatedtype fields
+ author:
+ - family: Kullback
+ given: Solomon
+ id: 'kullback:related'
+ issued: 1997
+ language: 'en-US'
+ publisher: Dover Publications
+ publisher-place: New York
+ title: Information theory and statistics
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-kullback-reprint.md b/test/command/biblatex-kullback-reprint.md
new file mode 100644
index 000000000..e158868f5
--- /dev/null
+++ b/test/command/biblatex-kullback-reprint.md
@@ -0,0 +1,71 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Kullback 1997)
+
+Kullback, Solomon. 1997. *Information Theory and Statistics*. New York:
+Dover Publications.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Kullback, 1997)
+
+Kullback, S. (1997). *Information theory and statistics*. New York:
+Dover Publications.
+
+
+NOTES:
+
+Formatted with chicago-author-date-TEST-20131018.csl
+
+(Kullback [1959] 1997)
+
+Kullback, Solomon. (1959) 1997. *Information Theory and Statistics*. New
+York: Dover Publications.
+
+}
+
+@Book{kullback:reprint,
+ author = {Kullback, Solomon},
+ title = {Information Theory and Statistics},
+ year = 1997,
+ publisher = {Dover Publications},
+ location = {New York},
+ origyear = 1959,
+ origpublisher= {John Wiley \& Sons},
+ hyphenation = {american},
+ annotation = {A reprint of the kullback entry. Note the format of
+ origyear and origpublisher. These fields are
+ not used by the standard bibliography styles},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A reprint of the kullback entry. Note the format of origyear
+ and origpublisher. These fields are not used by the standard
+ bibliography styles
+ author:
+ - family: Kullback
+ given: Solomon
+ id: 'kullback:reprint'
+ issued: 1997
+ language: 'en-US'
+ original-date: 1959
+ original-publisher: 'John Wiley & Sons'
+ publisher: Dover Publications
+ publisher-place: New York
+ title: Information theory and statistics
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-kullback.md b/test/command/biblatex-kullback.md
new file mode 100644
index 000000000..333128acf
--- /dev/null
+++ b/test/command/biblatex-kullback.md
@@ -0,0 +1,52 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Kullback 1959)
+
+Kullback, Solomon. 1959. *Information Theory and Statistics*. New York:
+John Wiley & Sons.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Kullback, 1959)
+
+Kullback, S. (1959). *Information theory and statistics*. New York: John
+Wiley & Sons.
+
+
+}
+
+@Book{kullback,
+ author = {Kullback, Solomon},
+ title = {Information Theory and Statistics},
+ year = 1959,
+ publisher = {John Wiley \& Sons},
+ location = {New York},
+ hyphenation = {american},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Kullback
+ given: Solomon
+ id: kullback
+ issued: 1959
+ language: 'en-US'
+ publisher: 'John Wiley & Sons'
+ publisher-place: New York
+ title: Information theory and statistics
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-laufenberg.md b/test/command/biblatex-laufenberg.md
new file mode 100644
index 000000000..4c7442c78
--- /dev/null
+++ b/test/command/biblatex-laufenberg.md
@@ -0,0 +1,109 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Laufenberg et al. 2006)
+
+Laufenberg, Xaver, Dominique Eynius, Helmut Suelzle, Stephan Usbeck,
+Matthias Spaeth, Miriam Neuser-Hoffmann, Christian Myrzik, et al. 2006.
+“Elektrische Einrichtung und Betriebsverfahren.” European patent.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Laufenberg et al., 2006)
+
+Laufenberg, X., Eynius, D., Suelzle, H., Usbeck, S., Spaeth, M.,
+Neuser-Hoffmann, M., … Ebner, N. (2006, September 13). Elektrische
+Einrichtung und Betriebsverfahren. European patent.
+
+
+NOTES:
+
+- biblio2yaml
+ - Is there any equivalent of "holder" in CSL?
+
+}
+
+@Patent{laufenberg,
+ author = {Laufenberg, Xaver and Eynius, Dominique and Suelzle, Helmut
+ and Usbeck, Stephan and Spaeth, Matthias and Neuser-Hoffmann,
+ Miriam and Myrzik, Christian and Schmid, Manfred and Nietfeld,
+ Franz and Thiel, Alexander and Braun, Harald and Ebner,
+ Norbert},
+ title = {Elektrische Einrichtung und Betriebsverfahren},
+ number = 1700367,
+ date = {2006-09-13},
+ holder = {{Robert Bosch GmbH} and {Daimler Chrysler AG} and {Bayerische
+ Motoren Werke AG}},
+ type = {patenteu},
+ hyphenation = {german},
+ annotation = {This is a patent entry with a holder field.
+ Note the format of the type and location
+ fields in the database file. Compare almendro,
+ sorace, and kowalik},
+ abstract = {The invention relates to an electric device comprising a
+ generator, in particular for use in the vehicle electric
+ system of a motor vehicle and a controller for controlling the
+ generator voltage. The device is equipped with a control zone,
+ in which the voltage is controlled and zones, in which the
+ torque is controlled. The invention also relates to methods
+ for operating a device of this type.},
+ file = {http://v3.espacenet.com/textdoc?IDX=EP1700367},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- abstract: 'The invention relates to an electric device comprising a
+ generator, in particular for use in the vehicle electric system of a
+ motor vehicle and a controller for controlling the generator
+ voltage. The device is equipped with a control zone, in which the
+ voltage is controlled and zones, in which the torque is controlled.
+ The invention also relates to methods for operating a device of this
+ type.'
+ annote: 'This is a patent entry with a holder field. Note the format
+ of the type and location fields in the database file. Compare
+ almendro, sorace, and kowalik'
+ author:
+ - family: Laufenberg
+ given: Xaver
+ - family: Eynius
+ given: Dominique
+ - family: Suelzle
+ given: Helmut
+ - family: Usbeck
+ given: Stephan
+ - family: Spaeth
+ given: Matthias
+ - family: 'Neuser-Hoffmann'
+ given: Miriam
+ - family: Myrzik
+ given: Christian
+ - family: Schmid
+ given: Manfred
+ - family: Nietfeld
+ given: Franz
+ - family: Thiel
+ given: Alexander
+ - family: Braun
+ given: Harald
+ - family: Ebner
+ given: Norbert
+ genre: European patent
+ id: laufenberg
+ issued: '2006-09-13'
+ language: 'de-DE'
+ number: 1700367
+ title: Elektrische Einrichtung und Betriebsverfahren
+ type: patent
+---
+
+
+```
diff --git a/test/command/biblatex-loh.md b/test/command/biblatex-loh.md
new file mode 100644
index 000000000..df56ac27d
--- /dev/null
+++ b/test/command/biblatex-loh.md
@@ -0,0 +1,65 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Loh 1992)
+
+Loh, Nin C. 1992. “High-resolution Micromachined Interferometric
+Accelerometer.” Master’s thesis, Cambridge, Mass.: Massachusetts
+Institute of Technology.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Loh, 1992)
+
+Loh, N. C. (1992). *High-resolution micromachined interferometric
+accelerometer* (Master’s thesis). Massachusetts Institute of Technology,
+Cambridge, Mass.
+
+
+NOTES:
+
+- biblio2yaml
+ - At some point, actual localization of "localization keys" will have to be implemented
+
+}
+
+@Thesis{loh,
+ author = {Loh, Nin C.},
+ title = {High-Resolution Micromachined Interferometric Accelerometer},
+ type = {mathesis},
+ institution = {Massachusetts Institute of Technology},
+ date = 1992,
+ location = {Cambridge, Mass.},
+ hyphenation = {american},
+ annotation = {This is a typical thesis entry for an MA thesis. Note
+ the type field in the database file which uses a
+ localization key},
+}
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a typical thesis entry for an MA thesis. Note the type
+ field in the database file which uses a localization key
+ author:
+ - family: Loh
+ given: Nin C.
+ genre: 'Master''s thesis'
+ id: loh
+ issued: 1992
+ language: 'en-US'
+ publisher: Massachusetts Institute of Technology
+ publisher-place: 'Cambridge, Mass.'
+ title: 'High-resolution micromachined interferometric accelerometer'
+ type: thesis
+---
+
+
+```
diff --git a/test/command/biblatex-malinowski.md b/test/command/biblatex-malinowski.md
new file mode 100644
index 000000000..56afc0b79
--- /dev/null
+++ b/test/command/biblatex-malinowski.md
@@ -0,0 +1,67 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Malinowski 1972)
+
+Malinowski, Bronisław. 1972. *Argonauts of the Western Pacific: An
+Account of Native Enterprise and Adventure in the Archipelagoes of
+Melanesian New Guinea*. 8th ed. London: Routledge and Kegan Paul.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Malinowski, 1972)
+
+Malinowski, B. (1972). *Argonauts of the Western Pacific: An account of
+native enterprise and adventure in the Archipelagoes of Melanesian New
+Guinea* (8th ed.). London: Routledge and Kegan Paul.
+
+
+}
+
+@Book{malinowski,
+ author = {Malinowski, Bronis{\l}aw},
+ title = {Argonauts of the {Western Pacific}},
+ date = 1972,
+ edition = 8,
+ publisher = {Routledge {and} Kegan Paul},
+ location = {London},
+ hyphenation = {british},
+ subtitle = {An account of native enterprise and adventure in the
+ {Archipelagoes of Melanesian New Guinea}},
+ shorttitle = {Argonauts},
+ annotation = {This is a book entry. Note the format of the
+ publisher and edition fields as well as the
+ subtitle field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a book entry. Note the format of the publisher and
+ edition fields as well as the subtitle field
+ author:
+ - family: Malinowski
+ given: Bronisław
+ edition: 8
+ id: malinowski
+ issued: 1972
+ language: 'en-GB'
+ publisher: Routledge and Kegan Paul
+ publisher-place: London
+ title: 'Argonauts of the Western Pacific: An account of native
+ enterprise and adventure in the [Archipelagoes of Melanesian New
+ Guinea]{.nocase}'
+ title-short: Argonauts
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-manual.md b/test/command/biblatex-manual.md
new file mode 100644
index 000000000..2d4f3596c
--- /dev/null
+++ b/test/command/biblatex-manual.md
@@ -0,0 +1,51 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{adapted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib}
+
+@Manual{cms,
+ title = {The {Chicago} Manual of Style},
+ date = 2003,
+ subtitle = {The Essential Guide for Writers, Editors, and Publishers},
+ edition = 15,
+ publisher = {University of Chicago Press},
+ location = {Chicago, Ill.},
+ isbn = {0-226-10403-6},
+ label = {CMS},
+ hyphenation = {american},
+ sorttitle = {Chicago Manual of Style},
+ indextitle = {Chicago Manual of Style, The},
+ shorttitle = {Chicago Manual of Style},
+ annotation = {This is a manual entry without an author or
+ editor. Note the label field in the database
+ file which is provided for author-year citation styles. Also
+ note the sorttitle and indextitle fields. By
+ default, all entries without an author or
+ editor are alphabetized by title but we want
+ this entry to be alphabetized under \enquote*{C} rather than
+ \enquote*{T}. There's also an isbn field},
+}
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'This is a manual entry without an author or editor. Note the
+ label field in the database file which is provided for author-year
+ citation styles. Also note the sorttitle and indextitle fields. By
+ default, all entries without an author or editor are alphabetized by
+ title but we want this entry to be alphabetized under ''C'' rather
+ than ''T''. There''s also an isbn field'
+ edition: 15
+ id: cms
+ isbn: '0-226-10403-6'
+ issued: 2003
+ language: 'en-US'
+ publisher: University of Chicago Press
+ publisher-place: 'Chicago, Ill.'
+ title: 'The Chicago manual of style: The essential guide for writers,
+ editors, and publishers'
+ title-short: Chicago manual of style
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-markey.md b/test/command/biblatex-markey.md
new file mode 100644
index 000000000..8e8c39dab
--- /dev/null
+++ b/test/command/biblatex-markey.md
@@ -0,0 +1,65 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Markey 2005)
+
+Markey, Nicolas. 2005. “Tame the BeaST: The B to X of BibTeX” (version
+1.3). October 16.
+<http://tug.ctan.org/tex-archive/info/bibtex/tamethebeast/ttb_en.pdf>.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Markey, 2005)
+
+Markey, N. (2005, October 16). Tame the BeaST: The B to X of BibTeX.
+Retrieved October 01, 2006, from
+<http://tug.ctan.org/tex-archive/info/bibtex/tamethebeast/ttb_en.pdf>
+
+
+}
+
+@Online{markey,
+ author = {Markey, Nicolas},
+ title = {Tame the {BeaST}},
+ date = {2005-10-16},
+ url =
+ {http://tug.ctan.org/tex-archive/info/bibtex/tamethebeast/ttb_en.pdf},
+ subtitle = {The {B} to {X} of {BibTeX}},
+ version = {1.3},
+ urldate = {2006-10-01},
+ hyphenation = {american},
+ sorttitle = {Tame the Beast},
+ annotation = {An online entry for a tutorial. Note the format of
+ the date field (yyyy-mm-dd) in the database
+ file.},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- accessed: '2006-10-01'
+ annote: 'An online entry for a tutorial. Note the format of the date
+ field (yyyy-mm-dd) in the database file.'
+ author:
+ - family: Markey
+ given: Nicolas
+ id: markey
+ issued: '2005-10-16'
+ language: 'en-US'
+ title: 'Tame the BeaST: The B to X of BibTeX'
+ title-short: Tame the BeaST
+ type: webpage
+ url: 'http://tug.ctan.org/tex-archive/info/bibtex/tamethebeast/ttb_en.pdf'
+ version: 1.3
+---
+
+
+```
diff --git a/test/command/biblatex-maron.md b/test/command/biblatex-maron.md
new file mode 100644
index 000000000..fbc965064
--- /dev/null
+++ b/test/command/biblatex-maron.md
@@ -0,0 +1,70 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Maron 2000)
+
+Maron, Monika. 2000. *Animal Triste*. Translated by Brigitte Goldstein.
+Lincoln: University of Nebraska Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Maron, 2000)
+
+Maron, M. (2000). *Animal triste*. (B. Goldstein, Trans.). Lincoln:
+University of Nebraska Press.
+
+
+NOTES:
+
+- origlanguage concatenated with translator, e.g. “translated from the German by …” not possible in CSL
+
+}
+
+@Book{maron,
+ author = {Maron, Monika},
+ title = {Animal Triste},
+ date = 2000,
+ translator = {Brigitte Goldstein},
+ origlanguage = {german},
+ publisher = {University of Nebraska Press},
+ location = {Lincoln},
+ hyphenation = {american},
+ shorttitle = {Animal Triste},
+ annotation = {An English translation of a German novel with a French title.
+ In other words: a book entry with a
+ translator field. Note the origlanguage
+ field which is concatenated with the translator},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An English translation of a German novel with a French title.
+ In other words: a book entry with a translator field. Note the
+ origlanguage field which is concatenated with the translator'
+ author:
+ - family: Maron
+ given: Monika
+ id: maron
+ issued: 2000
+ language: 'en-US'
+ publisher: University of Nebraska Press
+ publisher-place: Lincoln
+ title: Animal triste
+ title-short: Animal triste
+ translator:
+ - family: Goldstein
+ given: Brigitte
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-massa.md b/test/command/biblatex-massa.md
new file mode 100644
index 000000000..6561a9cb5
--- /dev/null
+++ b/test/command/biblatex-massa.md
@@ -0,0 +1,56 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Massa 2004)
+
+Massa, Werner. 2004. *Crystal Structure Determination*. 2nd ed. Berlin:
+Spinger.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Massa, 2004)
+
+Massa, W. (2004). *Crystal structure determination* (2nd ed.). Berlin:
+Spinger.
+
+
+}
+
+@Book{massa,
+ author = {Werner Massa},
+ title = {Crystal structure determination},
+ date = 2004,
+ edition = 2,
+ publisher = {Spinger},
+ location = {Berlin},
+ hyphenation = {british},
+ annotation = {A book entry with an edition field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry with an edition field
+ author:
+ - family: Massa
+ given: Werner
+ edition: 2
+ id: massa
+ issued: 2004
+ language: 'en-GB'
+ publisher: Spinger
+ publisher-place: Berlin
+ title: Crystal structure determination
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-moore-related.md b/test/command/biblatex-moore-related.md
new file mode 100644
index 000000000..2146206d4
--- /dev/null
+++ b/test/command/biblatex-moore-related.md
@@ -0,0 +1,66 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Moore 1998)
+
+Moore, Gordon E. 1998. “Cramming More Components onto Integrated
+Circuits.” *Proceedings of the IEEE* 86 (1): 82–85.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Moore, 1998)
+
+Moore, G. E. (1998). Cramming more components onto integrated circuits.
+*Proceedings of the IEEE*, *86*(1), 82–85.
+
+
+NOTES:
+
+- "related = {moore}, relatedtype = {reprintfrom}," – no equivalent implemented in CSL
+
+}
+
+@Article{moore:related,
+ author = {Moore, Gordon E.},
+ title = {Cramming more components onto integrated circuits},
+ journaltitle = {Proceedings of the {IEEE}},
+ year = 1998,
+ volume = 86,
+ number = 1,
+ pages = {82-85},
+ hyphenation = {american},
+ related = {moore},
+ relatedtype = {reprintfrom},
+ annotation = {A reprint of Moore's law. Note the related and
+ relatedtype fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A reprint of Moore''s law. Note the related and relatedtype
+ fields'
+ author:
+ - family: Moore
+ given: Gordon E.
+ container-title: Proceedings of the IEEE
+ id: 'moore:related'
+ issue: 1
+ issued: 1998
+ language: 'en-US'
+ page: '82-85'
+ title: Cramming more components onto integrated circuits
+ type: 'article-journal'
+ volume: 86
+---
+
+
+```
diff --git a/test/command/biblatex-moore.md b/test/command/biblatex-moore.md
new file mode 100644
index 000000000..1e169c9f4
--- /dev/null
+++ b/test/command/biblatex-moore.md
@@ -0,0 +1,56 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Moore 1965)
+
+Moore, Gordon E. 1965. “Cramming More Components onto Integrated
+Circuits.” *Electronics* 38 (8): 114–117.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Moore, 1965)
+
+Moore, G. E. (1965). Cramming more components onto integrated circuits.
+*Electronics*, *38*(8), 114–117.
+
+
+}
+
+@Article{moore,
+ author = {Moore, Gordon E.},
+ title = {Cramming more components onto integrated circuits},
+ journaltitle = {Electronics},
+ year = 1965,
+ volume = 38,
+ number = 8,
+ pages = {114-117},
+ hyphenation = {american},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Moore
+ given: Gordon E.
+ container-title: Electronics
+ id: moore
+ issue: 8
+ issued: 1965
+ language: 'en-US'
+ page: '114-117'
+ title: Cramming more components onto integrated circuits
+ type: 'article-journal'
+ volume: 38
+---
+
+
+```
diff --git a/test/command/biblatex-moraux.md b/test/command/biblatex-moraux.md
new file mode 100644
index 000000000..9e07c3974
--- /dev/null
+++ b/test/command/biblatex-moraux.md
@@ -0,0 +1,94 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Moraux 1979)
+
+Moraux, Paul. 1979. “Le *De Anima* dans la tradition grècque: Quelques
+aspects de l’interpretation du traité, de Theophraste à Themistius.” In
+*Aristotle on Mind and the Senses. Proceedings of the Seventh Symposium
+Aristotelicum*, edited by G. E. R. Lloyd and G. E. L. Owen, 281–324.
+Cambridge: Cambridge University Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Moraux, 1979)
+
+Moraux, P. (1979). Le *De Anima* dans la tradition grècque: Quelques
+aspects de l’interpretation du traité, de Theophraste à Themistius. In
+G. E. R. Lloyd & G. E. L. Owen (eds.), *Aristotle on Mind and the
+Senses. Proceedings of the Seventh Symposium Aristotelicum* (pp.
+281–324). Cambridge: Cambridge University Press.
+
+
+NOTES:
+
+- Since case (conversion) can only be specified per entry, not per field, for apa.csl the case of container-title would have to be adjusted manually.
+
+}
+
+@string{ cup = {Cambridge University Press} }
+
+@InProceedings{moraux,
+ author = {Moraux, Paul},
+ editor = {Lloyd, G. E. R. and Owen, G. E. L.},
+ title = {Le \emph{De Anima} dans la tradition gr{\`e}cque},
+ date = 1979,
+ booktitle = {Aristotle on Mind and the Senses},
+ subtitle = {Quelques aspects de l'interpretation du trait{\'e}, de
+ Theophraste {\`a} Themistius},
+ booktitleaddon= {Proceedings of the Seventh Symposium Aristotelicum},
+ eventdate = 1975,
+ publisher = cup,
+ location = {Cambridge},
+ pages = {281-324},
+ keywords = {secondary},
+ hyphenation = {french},
+ indexsorttitle= {De Anima dans la tradition grecque},
+ indextitle = {\emph{De Anima} dans la tradition gr{\`e}cque, Le},
+ shorttitle = {\emph{De Anima} dans la tradition gr{\`e}cque},
+ annotation = {This is a typical inproceedings entry. Note the
+ booksubtitle, shorttitle,
+ indextitle, and indexsorttitle fields. Also
+ note the eventdate field.},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'This is a typical inproceedings entry. Note the booksubtitle,
+ shorttitle, indextitle, and indexsorttitle fields. Also note the
+ eventdate field.'
+ author:
+ - family: Moraux
+ given: Paul
+ container-title: Aristotle on Mind and the Senses. Proceedings of the
+ Seventh Symposium Aristotelicum
+ editor:
+ - family: Lloyd
+ given: G. E. R.
+ - family: Owen
+ given: G. E. L.
+ event-date: 1975
+ id: moraux
+ issued: 1979
+ keyword: secondary
+ language: 'fr-FR'
+ page: '281-324'
+ publisher: Cambridge University Press
+ publisher-place: Cambridge
+ title: 'Le *De Anima* dans la tradition grècque: Quelques aspects de
+ l''interpretation du traité, de Theophraste à Themistius'
+ title-short: '*De Anima* dans la tradition grècque'
+ type: 'paper-conference'
+---
+
+
+```
diff --git a/test/command/biblatex-murray.md b/test/command/biblatex-murray.md
new file mode 100644
index 000000000..297b27aa4
--- /dev/null
+++ b/test/command/biblatex-murray.md
@@ -0,0 +1,104 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Hostetler et al. 1998)
+
+Hostetler, Michael J., Julia E. Wingate, Chuan-Jian Zhong, Jay E.
+Harris, Richard W. Vachet, Michael R. Clark, J. David Londono, et al.
+1998. “Alkanethiolate Gold Cluster Molecules with Core Diameters from
+1.5 to 5.2 nm: Core and Monolayer Properties as a Function of Core
+Size.” *Langmuir* 14 (1): 17–30.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Hostetler et al., 1998)
+
+Hostetler, M. J., Wingate, J. E., Zhong, C.-J., Harris, J. E., Vachet,
+R. W., Clark, M. R., … Murray, R. W. (1998). Alkanethiolate gold cluster
+molecules with core diameters from 1.5 to 5.2 nm: Core and monolayer
+properties as a function of core size. *Langmuir*, *14*(1), 17–30.
+
+
+}
+
+@Article{murray,
+ author = {Hostetler, Michael J. and Wingate, Julia E. and Zhong,
+ Chuan-Jian and Harris, Jay E. and Vachet, Richard W. and
+ Clark, Michael R. and Londono, J. David and Green, Stephen
+ J. and Stokes, Jennifer J. and Wignall, George D. and Glish,
+ Gary L. and Porter, Marc D. and Evans, Neal D. and Murray,
+ Royce W.},
+ title = {Alkanethiolate gold cluster molecules with core diameters from
+ 1.5 to 5.2~{nm}},
+ journaltitle = {Langmuir},
+ date = 1998,
+ subtitle = {Core and monolayer properties as a function of core size},
+ volume = 14,
+ number = 1,
+ pages = {17-30},
+ hyphenation = {american},
+ indextitle = {Alkanethiolate gold cluster molecules},
+ shorttitle = {Alkanethiolate gold cluster molecules},
+ annotation = {An article entry with \arabic{author} authors. By
+ default, long author and editor lists are automatically
+ truncated. This is configurable},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An article entry with author authors. By default, long author
+ and editor lists are automatically truncated. This is configurable'
+ author:
+ - family: Hostetler
+ given: Michael J.
+ - family: Wingate
+ given: Julia E.
+ - family: Zhong
+ given: 'Chuan-Jian'
+ - family: Harris
+ given: Jay E.
+ - family: Vachet
+ given: Richard W.
+ - family: Clark
+ given: Michael R.
+ - family: Londono
+ given: J. David
+ - family: Green
+ given: Stephen J.
+ - family: Stokes
+ given: Jennifer J.
+ - family: Wignall
+ given: George D.
+ - family: Glish
+ given: Gary L.
+ - family: Porter
+ given: Marc D.
+ - family: Evans
+ given: Neal D.
+ - family: Murray
+ given: Royce W.
+ container-title: Langmuir
+ id: murray
+ issue: 1
+ issued: 1998
+ language: 'en-US'
+ page: '17-30'
+ title: 'Alkanethiolate gold cluster molecules with core diameters from
+ 1.5 to 5.2 [nm]{.nocase}: Core and monolayer properties as a
+ function of core size'
+ title-short: Alkanethiolate gold cluster molecules
+ type: 'article-journal'
+ volume: 14
+---
+
+
+```
diff --git a/test/command/biblatex-nietzsche-historie.md b/test/command/biblatex-nietzsche-historie.md
new file mode 100644
index 000000000..dabcfb83a
--- /dev/null
+++ b/test/command/biblatex-nietzsche-historie.md
@@ -0,0 +1,100 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Nietzsche 1988)
+
+Nietzsche, Friedrich. 1988. “Unzeitgemässe Betrachtungen. Zweites Stück:
+Vom Nutzen und Nachtheil der Historie für das Leben.” In *Sämtliche
+Werke: Kritische Studienausgabe*, by Friedrich Nietzsche, edited by
+Giorgio Colli and Mazzino Montinari, 1:243–334. München; Berlin; New
+York: Deutscher Taschenbuch-Verlag; Walter de Gruyter.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Nietzsche, 1988)
+
+Nietzsche, F. (1988). Unzeitgemässe Betrachtungen. Zweites Stück: Vom
+Nutzen und Nachtheil der Historie für das Leben. In G. Colli & M.
+Montinari (eds.), *Sämtliche Werke: Kritische Studienausgabe* (Vol. 1,
+pp. 243–334). München; Berlin; New York: Deutscher Taschenbuch-Verlag;
+Walter de Gruyter.
+
+
+}
+
+@string{ dtv = {Deutscher Taschenbuch-Verlag} }
+
+@InBook{nietzsche:historie,
+ title = {Unzeitgem{\"a}sse Betrachtungen. Zweites St{\"u}ck},
+ date = 1988,
+ author = {Nietzsche, Friedrich},
+ booktitle = {Die Geburt der Trag{\"o}die. Unzeitgem{\"a}{\ss}e
+ Betrachtungen I--IV. Nachgelassene Schriften 1870--1973},
+ bookauthor = {Nietzsche, Friedrich},
+ editor = {Colli, Giorgio and Montinari, Mazzino},
+ subtitle = {Vom Nutzen und Nachtheil der Historie f{\"u}r das Leben},
+ maintitle = {S{\"a}mtliche Werke},
+ mainsubtitle = {Kritische Studienausgabe},
+ volume = 1,
+ publisher = dtv # { and Walter de Gruyter},
+ location = {M{\"u}nchen and Berlin and New York},
+ pages = {243-334},
+ hyphenation = {german},
+ sortyear = {1988-2},
+ sorttitle = {Werke-01-243},
+ indexsorttitle= {Vom Nutzen und Nachtheil der Historie fur das Leben},
+ indextitle = {Vom Nutzen und Nachtheil der Historie f{\"u}r das Leben},
+ shorttitle = {Vom Nutzen und Nachtheil der Historie},
+ annotation = {A single essay from the critical edition of Nietzsche's works.
+ This inbook entry explicitly refers to an essay found
+ in the first volume. Note the title,
+ booktitle, and maintitle fields. Also note
+ the sorttitle and sortyear fields. We want
+ this entry to be listed after the entry referring to the
+ entire first volume},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A single essay from the critical edition of Nietzsche''s
+ works. This inbook entry explicitly refers to an essay found in the
+ first volume. Note the title, booktitle, and maintitle fields. Also
+ note the sorttitle and sortyear fields. We want this entry to be
+ listed after the entry referring to the entire first volume'
+ author:
+ - family: Nietzsche
+ given: Friedrich
+ container-author:
+ - family: Nietzsche
+ given: Friedrich
+ container-title: 'Sämtliche Werke: Kritische Studienausgabe'
+ editor:
+ - family: Colli
+ given: Giorgio
+ - family: Montinari
+ given: Mazzino
+ id: 'nietzsche:historie'
+ issued: 1988
+ language: 'de-DE'
+ page: '243-334'
+ publisher: 'Deutscher Taschenbuch-Verlag; Walter de Gruyter'
+ publisher-place: München; Berlin; New York
+ title: 'Unzeitgemässe Betrachtungen. Zweites Stück: Vom Nutzen und
+ Nachtheil der Historie für das Leben'
+ title-short: Vom Nutzen und Nachtheil der Historie
+ type: chapter
+ volume: 1
+ volume-title: 'Die Geburt der Tragödie. Unzeitgemäße Betrachtungen
+ I--IV. Nachgelassene Schriften 1870--1973'
+---
+
+
+```
diff --git a/test/command/biblatex-nietzsche-ksa.md b/test/command/biblatex-nietzsche-ksa.md
new file mode 100644
index 000000000..7dbc92b45
--- /dev/null
+++ b/test/command/biblatex-nietzsche-ksa.md
@@ -0,0 +1,89 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Nietzsche 1988)
+
+Nietzsche, Friedrich. 1988. *Sämtliche Werke: Kritische Studienausgabe*.
+Edited by Giorgio Colli and Mazzino Montinari. 2nd ed. 15. München;
+Berlin; New York: Deutscher Taschenbuch-Verlag; Walter de Gruyter.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Nietzsche, 1988)
+
+Nietzsche, F. (1988). *Sämtliche Werke: Kritische Studienausgabe*. (G.
+Colli & M. Montinari, eds.) (2nd ed., 1-15). München; Berlin; New York:
+Deutscher Taschenbuch-Verlag; Walter de Gruyter.
+
+
+NOTES:
+
+- biblio2yaml
+ - term "vols." missing
+
+}
+
+@string{ dtv = {Deutscher Taschenbuch-Verlag} }
+
+@Book{nietzsche:ksa,
+ author = {Nietzsche, Friedrich},
+ title = {S{\"a}mtliche Werke},
+ date = 1988,
+ editor = {Colli, Giorgio and Montinari, Mazzino},
+ edition = 2,
+ volumes = 15,
+ publisher = dtv # { and Walter de Gruyter},
+ location = {M{\"u}nchen and Berlin and New York},
+ hyphenation = {german},
+ sortyear = {1988-0},
+ sorttitle = {Werke-00-000},
+ indexsorttitle= {Samtliche Werke},
+ subtitle = {Kritische Studienausgabe},
+ annotation = {The critical edition of Nietzsche's works. This is a
+ book entry referring to a 15-volume work as a
+ whole. Note the volumes field and the format of the
+ publisher and location fields in the
+ database file. Also note the sorttitle and
+ sortyear fields which are used to fine-tune the
+ sorting order of the bibliography. We want this item listed
+ first in the bibliography},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'The critical edition of Nietzsche''s works. This is a book
+ entry referring to a 15-volume work as a whole. Note the volumes
+ field and the format of the publisher and location fields in the
+ database file. Also note the sorttitle and sortyear fields which are
+ used to fine-tune the sorting order of the bibliography. We want
+ this item listed first in the bibliography'
+ author:
+ - family: Nietzsche
+ given: Friedrich
+ edition: 2
+ editor:
+ - family: Colli
+ given: Giorgio
+ - family: Montinari
+ given: Mazzino
+ id: 'nietzsche:ksa'
+ issued: 1988
+ language: 'de-DE'
+ number-of-volumes: 15
+ publisher: 'Deutscher Taschenbuch-Verlag; Walter de Gruyter'
+ publisher-place: München; Berlin; New York
+ title: 'Sämtliche Werke: Kritische Studienausgabe'
+ title-short: Sämtliche Werke
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-nietzsche-ksa1.md b/test/command/biblatex-nietzsche-ksa1.md
new file mode 100644
index 000000000..51b4a1f5a
--- /dev/null
+++ b/test/command/biblatex-nietzsche-ksa1.md
@@ -0,0 +1,95 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2015-03-08:
+
+(Nietzsche 1988)
+
+Nietzsche, Friedrich. 1988. *Sämtliche Werke: Kritische Studienausgabe*.
+Edited by Giorgio Colli and Mazzino Montinari. 2nd ed. Vol. 1. München;
+Berlin; New York: Deutscher Taschenbuch-Verlag; Walter de Gruyter.
+
+
+Formatted with pandoc and apa.csl, 2015-03-08:
+
+(Nietzsche, 1988)
+
+Nietzsche, F. (1988). *Sämtliche Werke: Kritische Studienausgabe*. (G.
+Colli & M. Montinari, eds., F. Nietzsche) (2nd ed., Vol. 1). München;
+Berlin; New York: Deutscher Taschenbuch-Verlag; Walter de Gruyter.
+
+
+NOTES:
+
+- volume-title currently not implemented by chicago-author-date.csl and apa.csl.
+
+}
+
+@string{ dtv = {Deutscher Taschenbuch-Verlag} }
+
+@Book{nietzsche:ksa1,
+ author = {Nietzsche, Friedrich},
+ title = {Die Geburt der Trag{\"o}die. Unzeitgem{\"a}{\ss}e
+ Betrachtungen I--IV. Nachgelassene Schriften 1870--1973},
+ date = 1988,
+ editor = {Colli, Giorgio and Montinari, Mazzino},
+ maintitle = {S{\"a}mtliche Werke},
+ mainsubtitle = {Kritische Studienausgabe},
+ volume = 1,
+ edition = 2,
+ publisher = dtv # { and Walter de Gruyter},
+ location = {M{\"u}nchen and Berlin and New York},
+ hyphenation = {german},
+ sortyear = {1988-1},
+ sorttitle = {Werke-01-000},
+ indexsorttitle= {Samtliche Werke I},
+ bookauthor = {Nietzsche, Friedrich},
+ indextitle = {S{\"a}mtliche Werke I},
+ shorttitle = {S{\"a}mtliche Werke I},
+ annotation = {A single volume from the critical edition of Nietzsche's
+ works. This book entry explicitly refers to the first
+ volume only. Note the title and maintitle
+ fields. Also note the sorttitle and sortyear
+ fields. We want this entry to be listed after the entry
+ referring to the entire edition},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A single volume from the critical edition of Nietzsche''s
+ works. This book entry explicitly refers to the first volume only.
+ Note the title and maintitle fields. Also note the sorttitle and
+ sortyear fields. We want this entry to be listed after the entry
+ referring to the entire edition'
+ author:
+ - family: Nietzsche
+ given: Friedrich
+ container-author:
+ - family: Nietzsche
+ given: Friedrich
+ edition: 2
+ editor:
+ - family: Colli
+ given: Giorgio
+ - family: Montinari
+ given: Mazzino
+ id: 'nietzsche:ksa1'
+ issued: 1988
+ language: 'de-DE'
+ publisher: 'Deutscher Taschenbuch-Verlag; Walter de Gruyter'
+ publisher-place: München; Berlin; New York
+ title: 'Sämtliche Werke: Kritische Studienausgabe'
+ type: book
+ volume: 1
+ volume-title: 'Die Geburt der Tragödie. Unzeitgemäße Betrachtungen
+ I--IV. Nachgelassene Schriften 1870--1973'
+---
+
+
+```
diff --git a/test/command/biblatex-nussbaum.md b/test/command/biblatex-nussbaum.md
new file mode 100644
index 000000000..6e356d3da
--- /dev/null
+++ b/test/command/biblatex-nussbaum.md
@@ -0,0 +1,63 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Nussbaum 1978)
+
+Nussbaum, Martha. 1978. *Aristotle’s “De Motu Animalium”*. Princeton:
+Princeton University Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Nussbaum, 1978)
+
+Nussbaum, M. (1978). *Aristotle’s “De Motu Animalium”*. Princeton:
+Princeton University Press.
+
+
+}
+
+@string{ pup = {Princeton University Press} }
+
+@Book{nussbaum,
+ author = {Nussbaum, Martha},
+ title = {Aristotle's \mkbibquote{De Motu Animalium}},
+ date = 1978,
+ publisher = pup,
+ location = {Princeton},
+ keywords = {secondary},
+ hyphenation = {american},
+ sorttitle = {Aristotle's De Motu Animalium},
+ indexsorttitle= {Aristotle's De Motu Animalium},
+ annotation = {A book entry. Note the sorttitle and
+ indexsorttitle fields and the markup of the quotes in
+ the database file},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry. Note the sorttitle and indexsorttitle fields and
+ the markup of the quotes in the database file
+ author:
+ - family: Nussbaum
+ given: Martha
+ id: nussbaum
+ issued: 1978
+ keyword: secondary
+ language: 'en-US'
+ publisher: Princeton University Press
+ publisher-place: Princeton
+ title: 'Aristotle''s "De Motu Animalium"'
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-online.md b/test/command/biblatex-online.md
new file mode 100644
index 000000000..97706c890
--- /dev/null
+++ b/test/command/biblatex-online.md
@@ -0,0 +1,64 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{adapted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib}
+
+@online{markey,
+ Annotation = {An online entry for a tutorial. Note the format of the date field (yyyy-mm-dd) in the database file.},
+ Author = {Markey, Nicolas},
+ Date = {2005-10-16},
+ Hyphenation = {american},
+ Sorttitle = {Tame the Beast},
+ Subtitle = {The {B} to {X} of {BibTeX}},
+ Title = {Tame the {BeaST}},
+ Url = {http://tug.ctan.org/tex-archive/info/bibtex/tamethebeast/ttb_en.pdf},
+ Urldate = {2006-10-01},
+ Version = {1.3},
+}
+
+@online{CTAN,
+ Annotation = {This is an online entry. The \textsc{url}, which is given in the url field, is transformed into a clickable link if hyperref support has been enabled. Note the format of the urldate field (yyyy-mm-dd) in the database file. Also note the label field which may be used as a fallback by citation styles which need an author and\slash or a year},
+ Date = 2006,
+ Hyphenation = {american},
+ Label = {CTAN},
+ Subtitle = {The {Comprehensive TeX Archive Network}},
+ Title = {{CTAN}},
+ Url = {http://www.ctan.org},
+ Urldate = {2006-10-01},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- accessed: '2006-10-01'
+ annote: 'An online entry for a tutorial. Note the format of the date
+ field (yyyy-mm-dd) in the database file.'
+ author:
+ - family: Markey
+ given: Nicolas
+ id: markey
+ issued: '2005-10-16'
+ language: 'en-US'
+ title: 'Tame the BeaST: The B to X of BibTeX'
+ title-short: Tame the BeaST
+ type: webpage
+ url: 'http://tug.ctan.org/tex-archive/info/bibtex/tamethebeast/ttb_en.pdf'
+ version: 1.3
+- accessed: '2006-10-01'
+ annote: 'This is an online entry. The [url]{.smallcaps}, which is
+ given in the url field, is transformed into a clickable link if
+ hyperref support has been enabled. Note the format of the urldate
+ field (yyyy-mm-dd) in the database file. Also note the label field
+ which may be used as a fallback by citation styles which need an
+ author and/or a year'
+ id: CTAN
+ issued: 2006
+ language: 'en-US'
+ title: 'CTAN: The Comprehensive TeX Archive Network'
+ title-short: CTAN
+ type: webpage
+ url: 'http://www.ctan.org'
+---
+
+
+```
diff --git a/test/command/biblatex-options-url-false-doi-false.md b/test/command/biblatex-options-url-false-doi-false.md
new file mode 100644
index 000000000..259665e87
--- /dev/null
+++ b/test/command/biblatex-options-url-false-doi-false.md
@@ -0,0 +1,57 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Entry contains url and doi fields; these should be discarded since the
+options field specifies url=false, doi=false.
+
+Exception: As in standard biblatex, in online entries url should never be
+discarded, even if options contains url=false.
+
+}
+
+@article{item1,
+ Author = {Author, Andy},
+ Date = {2012},
+ Doi = {1234/5678.90},
+ Journal = {Journal},
+ Options = {url=false, doi=false},
+ Title = {Title, Any Entry Type Except online},
+ Url = {http://foo.bar}
+}
+
+@online{item2,
+ Author = {Author, Andy},
+ Date = {2012},
+ Doi = {1234/5678.90},
+ Journal = {Journal},
+ Options = {url=false, doi=false},
+ Title = {Title, Entry Type online},
+ Url = {http://foo.bar}
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Author
+ given: Andy
+ container-title: Journal
+ id: item1
+ issued: 2012
+ title: 'Title, any entry type except online'
+ type: 'article-journal'
+- author:
+ - family: Author
+ given: Andy
+ container-title: Journal
+ id: item2
+ issued: 2012
+ title: 'Title, entry type online'
+ type: webpage
+ url: 'http://foo.bar'
+---
+
+
+```
diff --git a/test/command/biblatex-padhye.md b/test/command/biblatex-padhye.md
new file mode 100644
index 000000000..6afc5e5ef
--- /dev/null
+++ b/test/command/biblatex-padhye.md
@@ -0,0 +1,117 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Padhye, Firoiu, and Towsley 1999)
+
+Padhye, Jitendra, Victor Firoiu, and Don Towsley. 1999. “A Stochastic
+Model of TCP Reno Congestion Avoidance and Control.” Technical report
+99-02. Amherst, Mass.: University of Massachusetts.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Padhye, Firoiu, & Towsley, 1999)
+
+Padhye, J., Firoiu, V., & Towsley, D. (1999). *A stochastic model of TCP
+Reno congestion avoidance and control* (technical report No. 99-02).
+Amherst, Mass.: University of Massachusetts.
+
+}
+
+@Report{padhye,
+ author = {Padhye, Jitendra and Firoiu, Victor and Towsley, Don},
+ title = {A Stochastic Model of {TCP Reno} Congestion Avoidance and
+ Control},
+ type = {techreport},
+ institution = {University of Massachusetts},
+ date = 1999,
+ number = {99-02},
+ location = {Amherst, Mass.},
+ hyphenation = {american},
+ sorttitle = {A Stochastic Model of TCP Reno Congestion Avoidance and
+ Control},
+ indextitle = {Stochastic Model of {TCP Reno} Congestion Avoidance and Control,
+ A},
+ annotation = {This is a report entry for a technical report. Note
+ the format of the type field in the database file
+ which uses a localization key. The number of the report is
+ given in the number field. Also note the
+ sorttitle and indextitle fields},
+ abstract = {The steady state performance of a bulk transfer TCP flow
+ (i.e., a flow with a large amount of data to send, such as FTP
+ transfers) may be characterized by three quantities. The first
+ is the send rate, which is the amount of data sent by the
+ sender in unit time. The second is the throughput, which is
+ the amount of data received by the receiver in unit time. Note
+ that the throughput will always be less than or equal to the
+ send rate due to losses. Finally, the number of non-duplicate
+ packets received by the receiver in unit time gives us the
+ goodput of the connection. The goodput is always less than or
+ equal to the throughput, since the receiver may receive two
+ copies of the same packet due to retransmissions by the
+ sender. In a previous paper, we presented a simple model for
+ predicting the steady state send rate of a bulk transfer TCP
+ flow as a function of loss rate and round trip time. In this
+ paper, we extend that work in two ways. First, we analyze the
+ performance of bulk transfer TCP flows using more precise,
+ stochastic analysis. Second, we build upon the previous
+ analysis to provide both an approximate formula as well as a
+ more accurate stochastic model for the steady state throughput
+ of a bulk transfer TCP flow.},
+ file = {ftp://gaia.cs.umass.edu/pub/Padhey99-markov.ps},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- abstract: 'The steady state performance of a bulk transfer TCP flow
+ (i.e., a flow with a large amount of data to send, such as FTP
+ transfers) may be characterized by three quantities. The first is
+ the send rate, which is the amount of data sent by the sender in
+ unit time. The second is the throughput, which is the amount of data
+ received by the receiver in unit time. Note that the throughput will
+ always be less than or equal to the send rate due to losses.
+ Finally, the number of non-duplicate packets received by the
+ receiver in unit time gives us the goodput of the connection. The
+ goodput is always less than or equal to the throughput, since the
+ receiver may receive two copies of the same packet due to
+ retransmissions by the sender. In a previous paper, we presented a
+ simple model for predicting the steady state send rate of a bulk
+ transfer TCP flow as a function of loss rate and round trip time. In
+ this paper, we extend that work in two ways. First, we analyze the
+ performance of bulk transfer TCP flows using more precise,
+ stochastic analysis. Second, we build upon the previous analysis to
+ provide both an approximate formula as well as a more accurate
+ stochastic model for the steady state throughput of a bulk transfer
+ TCP flow.'
+ annote: This is a report entry for a technical report. Note the format
+ of the type field in the database file which uses a localization
+ key. The number of the report is given in the number field. Also
+ note the sorttitle and indextitle fields
+ author:
+ - family: Padhye
+ given: Jitendra
+ - family: Firoiu
+ given: Victor
+ - family: Towsley
+ given: Don
+ genre: technical report
+ id: padhye
+ issued: 1999
+ language: 'en-US'
+ number: '99-02'
+ publisher: University of Massachusetts
+ publisher-place: 'Amherst, Mass.'
+ title: A stochastic model of TCP Reno congestion avoidance and control
+ type: report
+---
+
+
+```
diff --git a/test/command/biblatex-patent.md b/test/command/biblatex-patent.md
new file mode 100644
index 000000000..c351e61cb
--- /dev/null
+++ b/test/command/biblatex-patent.md
@@ -0,0 +1,158 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{adapted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib
+
+TODO: Is there a CSL counterpart for the biblatex field "holder"?}
+
+
+@patent{almendro,
+ Annotation = {This is a patent entry with a location field. The number is given in the number field. Note the format of the location field in the database file. Compare laufenberg, sorace, and kowalik},
+ Author = {Almendro, José L. and Martín, Jacinto and Sánchez, Alberto and Nozal, Fernando},
+ Date = 1998,
+ Hyphenation = {german},
+ Location = {countryfr and countryuk and countryde},
+ Number = {EU-29702195U},
+ Title = {Elektromagnetisches Signalhorn}}
+
+@patent{kowalik,
+ Annotation = {This is a patent entry for a French patent request with a full date. The number is given in the number field. Note the format of the type and date fields in the database file. Compare almendro, laufenberg, and sorace},
+ Author = {Kowalik, F. and Isard, M.},
+ Date = {1995-01-11},
+ Hyphenation = {french},
+ Indextitle = {Estimateur d'un défaut de fonctionnement},
+ Number = 9500261,
+ Title = {Estimateur d'un défaut de fonctionnement d'un modulateur en quadrature et étage de modulation l'utilisant},
+ Type = {patreqfr}}
+
+@patent{laufenberg,
+ Annotation = {This is a patent entry with a holder field. Note the format of the type and location fields in the database file. Compare almendro, sorace, and kowalik},
+ Author = {Laufenberg, Xaver and Eynius, Dominique and Suelzle, Helmut and Usbeck, Stephan and Spaeth, Matthias and Neuser-Hoffmann, Miriam and Myrzik, Christian and Schmid, Manfred and Nietfeld, Franz and Thiel, Alexander and Braun, Harald and Ebner, Norbert},
+ Date = {2006-09-13},
+ File = {http://v3.espacenet.com/textdoc?IDX=EP1700367},
+ Holder = {{Robert Bosch GmbH} and {Daimler Chrysler AG} and {Bayerische Motoren Werke AG}},
+ Hyphenation = {german},
+ Number = 1700367,
+ Title = {Elektrische Einrichtung und Betriebsverfahren},
+ Type = {patenteu},
+ Abstract = {The invention relates to an electric device comprising a
+ generator, in particular for use in the vehicle electric
+ system of a motor vehicle and a controller for controlling the
+ generator voltage. The device is equipped with a control zone,
+ in which the voltage is controlled and zones, in which the
+ torque is controlled. The invention also relates to methods
+ for operating a device of this type.}}
+
+@patent{sorace,
+ Annotation = {This is a patent entry with a holder field. Note the format of the type and date fields in the database file. Compare almendro, laufenberg, and kowalik},
+ Author = {Sorace, Ronald E. and Reinhardt, Victor S. and Vaughn, Steven A.},
+ Date = {1997-09-16},
+ Date-Modified = {2013-10-16 13:44:15 +0000},
+ Holder = {{Hughes Aircraft Company}},
+ Hyphenation = {american},
+ Number = 5668842,
+ Title = {High-Speed Digital-to-{RF} Converter},
+ Type = {patentus}}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'This is a patent entry with a location field. The number is
+ given in the number field. Note the format of the location field in
+ the database file. Compare laufenberg, sorace, and kowalik'
+ author:
+ - family: Almendro
+ given: José L.
+ - family: Martín
+ given: Jacinto
+ - family: Sánchez
+ given: Alberto
+ - family: Nozal
+ given: Fernando
+ id: almendro
+ issued: 1998
+ jurisdiction: France; United Kingdom; Germany
+ language: 'de-DE'
+ number: 'EU-29702195U'
+ title: Elektromagnetisches Signalhorn
+ type: patent
+- annote: 'This is a patent entry for a French patent request with a
+ full date. The number is given in the number field. Note the format
+ of the type and date fields in the database file. Compare almendro,
+ laufenberg, and sorace'
+ author:
+ - family: Kowalik
+ given: F.
+ - family: Isard
+ given: M.
+ genre: French patent request
+ id: kowalik
+ issued: '1995-01-11'
+ language: 'fr-FR'
+ number: 9500261
+ title: 'Estimateur d''un défaut de fonctionnement d''un modulateur en
+ quadrature et étage de modulation l''utilisant'
+ type: patent
+- abstract: 'The invention relates to an electric device comprising a
+ generator, in particular for use in the vehicle electric system of a
+ motor vehicle and a controller for controlling the generator
+ voltage. The device is equipped with a control zone, in which the
+ voltage is controlled and zones, in which the torque is controlled.
+ The invention also relates to methods for operating a device of this
+ type.'
+ annote: 'This is a patent entry with a holder field. Note the format
+ of the type and location fields in the database file. Compare
+ almendro, sorace, and kowalik'
+ author:
+ - family: Laufenberg
+ given: Xaver
+ - family: Eynius
+ given: Dominique
+ - family: Suelzle
+ given: Helmut
+ - family: Usbeck
+ given: Stephan
+ - family: Spaeth
+ given: Matthias
+ - family: 'Neuser-Hoffmann'
+ given: Miriam
+ - family: Myrzik
+ given: Christian
+ - family: Schmid
+ given: Manfred
+ - family: Nietfeld
+ given: Franz
+ - family: Thiel
+ given: Alexander
+ - family: Braun
+ given: Harald
+ - family: Ebner
+ given: Norbert
+ genre: European patent
+ id: laufenberg
+ issued: '2006-09-13'
+ language: 'de-DE'
+ number: 1700367
+ title: Elektrische Einrichtung und Betriebsverfahren
+ type: patent
+- annote: 'This is a patent entry with a holder field. Note the format
+ of the type and date fields in the database file. Compare almendro,
+ laufenberg, and kowalik'
+ author:
+ - family: Sorace
+ given: Ronald E.
+ - family: Reinhardt
+ given: Victor S.
+ - family: Vaughn
+ given: Steven A.
+ genre: U.S. patent
+ id: sorace
+ issued: '1997-09-16'
+ language: 'en-US'
+ number: 5668842
+ title: 'High-speed digital-to-RF converter'
+ type: patent
+---
+
+
+```
diff --git a/test/command/biblatex-periodical.md b/test/command/biblatex-periodical.md
new file mode 100644
index 000000000..938e29666
--- /dev/null
+++ b/test/command/biblatex-periodical.md
@@ -0,0 +1,30 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{excerpt from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib
+
+@periodical{jcg,
+ Annotation = {This is a periodical entry with an issn field.},
+ Issn = {0097-8493},
+ Issuetitle = {Semantic {3D} Media and Content},
+ Number = 4,
+ Title = {Computers and Graphics},
+ Volume = 35,
+ Year = 2011}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a periodical entry with an issn field.
+ container-title: Computers and Graphics
+ id: jcg
+ issn: '0097-8493'
+ issue: 4
+ issued: 2011
+ title: Semantic 3D media and content
+ type: 'article-journal'
+ volume: 35
+---
+
+
+```
diff --git a/test/command/biblatex-piccato.md b/test/command/biblatex-piccato.md
new file mode 100644
index 000000000..4f4efcedf
--- /dev/null
+++ b/test/command/biblatex-piccato.md
@@ -0,0 +1,59 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Piccato 2001)
+
+Piccato, Pablo. 2001. *City of Suspects: Crime in Mexico City,
+1900–1931*. Durham; London: Duke University Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Piccato, 2001)
+
+Piccato, P. (2001). *City of suspects: Crime in Mexico City, 1900–1931*.
+Durham; London: Duke University Press.
+
+
+}
+
+@Book{piccato,
+ author = {Piccato, Pablo},
+ title = {City of Suspects},
+ date = 2001,
+ publisher = {Duke University Press},
+ location = {Durham and London},
+ hyphenation = {american},
+ subtitle = {Crime in {Mexico City}, 1900--1931},
+ shorttitle = {City of Suspects},
+ annotation = {This is a book entry. Note the format of the
+ location field in the database file},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a book entry. Note the format of the location field in
+ the database file
+ author:
+ - family: Piccato
+ given: Pablo
+ id: piccato
+ issued: 2001
+ language: 'en-US'
+ publisher: Duke University Press
+ publisher-place: Durham; London
+ title: 'City of suspects: Crime in Mexico City, 1900--1931'
+ title-short: City of suspects
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-pines.md b/test/command/biblatex-pines.md
new file mode 100644
index 000000000..80802fec6
--- /dev/null
+++ b/test/command/biblatex-pines.md
@@ -0,0 +1,77 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Pines 1979)
+
+Pines, Shlomo. 1979. “The Limitations of Human Knowledge According to
+Al-Farabi, ibn Bajja, and Maimonides.” In *Studies in Medieval Jewish
+History and Literature*, edited by Isadore Twersky, 82–109. Cambridge,
+Mass.: Harvard University Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Pines, 1979)
+
+Pines, S. (1979). The limitations of human knowledge according to
+Al-Farabi, ibn Bajja, and Maimonides. In I. Twersky (Ed.), *Studies in
+medieval Jewish history and literature* (pp. 82–109). Cambridge, Mass.:
+Harvard University Press.
+
+
+}
+
+@string{ hup = {Harvard University Press} }
+
+@InCollection{pines,
+ author = {Pines, Shlomo},
+ editor = {Twersky, Isadore},
+ title = {The Limitations of Human Knowledge According to {Al-Farabi}, {ibn
+ Bajja}, and {Maimonides}},
+ date = 1979,
+ booktitle = {Studies in Medieval {Jewish} History and Literature},
+ publisher = hup,
+ location = {Cambridge, Mass.},
+ pages = {82-109},
+ keywords = {secondary},
+ hyphenation = {american},
+ indextitle = {Limitations of Human Knowledge According to {Al-Farabi}, {ibn
+ Bajja}, and {Maimonides}, The},
+ shorttitle = {Limitations of Human Knowledge},
+ annotation = {A typical incollection entry. Note the
+ indextitle field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A typical incollection entry. Note the indextitle field
+ author:
+ - family: Pines
+ given: Shlomo
+ container-title: Studies in medieval Jewish history and literature
+ editor:
+ - family: Twersky
+ given: Isadore
+ id: pines
+ issued: 1979
+ keyword: secondary
+ language: 'en-US'
+ page: '82-109'
+ publisher: Harvard University Press
+ publisher-place: 'Cambridge, Mass.'
+ title: 'The limitations of human knowledge according to Al-Farabi,
+ [ibn Bajja]{.nocase}, and Maimonides'
+ title-short: Limitations of human knowledge
+ type: chapter
+---
+
+
+```
diff --git a/test/command/biblatex-quotes.md b/test/command/biblatex-quotes.md
new file mode 100644
index 000000000..5fb6a9078
--- /dev/null
+++ b/test/command/biblatex-quotes.md
@@ -0,0 +1,44 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{excerpt from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib
+
+\mkbibquote{} should be replaced by a matching set of quotation marks that can be used by citeproc for quote substitution and flipflopping. English smart double quotation marks seem best, as they cannot be confused with apostrophes.
+
+\enquote{}, \enquote*{} should be replaced by a matching set of quotation marks, too: “foo”, ‘bar’.
+}
+
+@string{pup = {Princeton University Press}}
+
+@book{nussbaum,
+ Annotation = {A book entry. Note the sorttitle and indexsorttitle fields and the markup of the quotes in the database file},
+ Author = {Nussbaum, Martha},
+ Date = 1978,
+ Hyphenation = {american},
+ Indexsorttitle = {Aristotle's De Motu Animalium},
+ Keywords = {secondary},
+ Location = {Princeton},
+ Publisher = pup,
+ Sorttitle = {Aristotle's De Motu Animalium},
+ Title = {Aristotle's \mkbibquote{De Motu Animalium}}}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry. Note the sorttitle and indexsorttitle fields and
+ the markup of the quotes in the database file
+ author:
+ - family: Nussbaum
+ given: Martha
+ id: nussbaum
+ issued: 1978
+ keyword: secondary
+ language: 'en-US'
+ publisher: Princeton University Press
+ publisher-place: Princeton
+ title: 'Aristotle''s "De Motu Animalium"'
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-reese.md b/test/command/biblatex-reese.md
new file mode 100644
index 000000000..884b32905
--- /dev/null
+++ b/test/command/biblatex-reese.md
@@ -0,0 +1,71 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Reese 1958)
+
+Reese, Trevor R. 1958. “Georgia in Anglo-Spanish Diplomacy, 1736-1739.”
+*William and Mary Quarterly, 3* 15: 168–190.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Reese, 1958)
+
+Reese, T. R. (1958). Georgia in Anglo-Spanish diplomacy, 1736-1739.
+*William and Mary Quarterly, 3*, *15*, 168–190.
+
+
+NOTES:
+
+- biblio2yaml
+ - series field: still not entirely satisfactory.
+ Could we map this to some existing CSL variable, and have the CSL styles handle this? "edition", maybe ??
+
+}
+
+@Article{reese,
+ author = {Reese, Trevor R.},
+ title = {Georgia in {Anglo-Spanish} Diplomacy, 1736-1739},
+ journaltitle = {William and Mary Quarterly},
+ date = 1958,
+ series = 3,
+ volume = 15,
+ pages = {168-190},
+ hyphenation = {american},
+ annotation = {An article entry with a series and a
+ volume field. Note the format of the series. If the
+ value of the series field is an integer, this number
+ is printed as an ordinal and the string \enquote*{series} is
+ appended automatically},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An article entry with a series and a volume field. Note the
+ format of the series. If the value of the series field is an
+ integer, this number is printed as an ordinal and the string
+ ''series'' is appended automatically'
+ author:
+ - family: Reese
+ given: Trevor R.
+ collection-title: 3rd series
+ container-title: William and Mary Quarterly
+ id: reese
+ issued: 1958
+ language: 'en-US'
+ page: '168-190'
+ title: 'Georgia in Anglo-Spanish diplomacy, 1736-1739'
+ type: 'article-journal'
+ volume: 15
+---
+
+
+```
diff --git a/test/command/biblatex-report.md b/test/command/biblatex-report.md
new file mode 100644
index 000000000..ab1a652b2
--- /dev/null
+++ b/test/command/biblatex-report.md
@@ -0,0 +1,119 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{excerpt from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib
+
+TODO: Where to map "file" field?
+}
+
+@report{chiu,
+ Annotation = {This is a report entry for a research report. Note the format of the type field in the database file which uses a localization key. The number of the report is given in the number field. Also note the sorttitle and indextitle fields},
+ Author = {Chiu, Willy W. and Chow, We Min},
+ Date = 1978,
+ Hyphenation = {american},
+ Indextitle = {Hybrid Hierarchical Model, A},
+ Institution = {IBM},
+ Number = {RC-6947},
+ Sorttitle = {Hybrid Hierarchical Model of a Multiple Virtual Storage (MVS) Operating System},
+ Title = {A Hybrid Hierarchical Model of a {Multiple Virtual Storage} ({MVS}) Operating System},
+ Type = {resreport}}
+
+@report{padhye,
+ Annotation = {This is a report entry for a technical report. Note the format of the type field in the database file which uses a localization key. The number of the report is given in the number field. Also note the sorttitle and indextitle fields},
+ Author = {Padhye, Jitendra and Firoiu, Victor and Towsley, Don},
+ Date = 1999,
+ File = {ftp://gaia.cs.umass.edu/pub/Padhey99-markov.ps},
+ Hyphenation = {american},
+ Indextitle = {Stochastic Model of TCP Reno Congestion Avoidance and Control, A},
+ Institution = {University of Massachusetts},
+ Location = {Amherst, Mass.},
+ Number = {99-02},
+ Sorttitle = {A Stochastic Model of TCP Reno Congestion Avoidance and Control},
+ Title = {A Stochastic Model of {TCP Reno} Congestion Avoidance and Control},
+ Type = {techreport},
+ Abstract = {The steady state performance of a bulk transfer TCP flow
+ (i.e., a flow with a large amount of data to send, such as FTP
+ transfers) may be characterized by three quantities. The first
+ is the send rate, which is the amount of data sent by the
+ sender in unit time. The second is the throughput, which is
+ the amount of data received by the receiver in unit time. Note
+ that the throughput will always be less than or equal to the
+ send rate due to losses. Finally, the number of non-duplicate
+ packets received by the receiver in unit time gives us the
+ goodput of the connection. The goodput is always less than or
+ equal to the throughput, since the receiver may receive two
+ copies of the same packet due to retransmissions by the
+ sender. In a previous paper, we presented a simple model for
+ predicting the steady state send rate of a bulk transfer TCP
+ flow as a function of loss rate and round trip time. In this
+ paper, we extend that work in two ways. First, we analyze the
+ performance of bulk transfer TCP flows using more precise,
+ stochastic analysis. Second, we build upon the previous
+ analysis to provide both an approximate formula as well as a
+ more accurate stochastic model for the steady state throughput
+ of a bulk transfer TCP flow.}}
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a report entry for a research report. Note the format
+ of the type field in the database file which uses a localization
+ key. The number of the report is given in the number field. Also
+ note the sorttitle and indextitle fields
+ author:
+ - family: Chiu
+ given: Willy W.
+ - family: Chow
+ given: We Min
+ genre: research report
+ id: chiu
+ issued: 1978
+ language: 'en-US'
+ number: 'RC-6947'
+ publisher: IBM
+ title: A hybrid hierarchical model of a Multiple Virtual Storage (MVS)
+ operating system
+ type: report
+- abstract: 'The steady state performance of a bulk transfer TCP flow
+ (i.e., a flow with a large amount of data to send, such as FTP
+ transfers) may be characterized by three quantities. The first is
+ the send rate, which is the amount of data sent by the sender in
+ unit time. The second is the throughput, which is the amount of data
+ received by the receiver in unit time. Note that the throughput will
+ always be less than or equal to the send rate due to losses.
+ Finally, the number of non-duplicate packets received by the
+ receiver in unit time gives us the goodput of the connection. The
+ goodput is always less than or equal to the throughput, since the
+ receiver may receive two copies of the same packet due to
+ retransmissions by the sender. In a previous paper, we presented a
+ simple model for predicting the steady state send rate of a bulk
+ transfer TCP flow as a function of loss rate and round trip time. In
+ this paper, we extend that work in two ways. First, we analyze the
+ performance of bulk transfer TCP flows using more precise,
+ stochastic analysis. Second, we build upon the previous analysis to
+ provide both an approximate formula as well as a more accurate
+ stochastic model for the steady state throughput of a bulk transfer
+ TCP flow.'
+ annote: This is a report entry for a technical report. Note the format
+ of the type field in the database file which uses a localization
+ key. The number of the report is given in the number field. Also
+ note the sorttitle and indextitle fields
+ author:
+ - family: Padhye
+ given: Jitendra
+ - family: Firoiu
+ given: Victor
+ - family: Towsley
+ given: Don
+ genre: technical report
+ id: padhye
+ issued: 1999
+ language: 'en-US'
+ number: '99-02'
+ publisher: University of Massachusetts
+ publisher-place: 'Amherst, Mass.'
+ title: A stochastic model of TCP Reno congestion avoidance and control
+ type: report
+---
+
+
+```
diff --git a/test/command/biblatex-salam.md b/test/command/biblatex-salam.md
new file mode 100644
index 000000000..7da076ca3
--- /dev/null
+++ b/test/command/biblatex-salam.md
@@ -0,0 +1,69 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Salam 1968)
+
+Salam, Abdus. 1968. “Weak and Electromagnetic Interactions.” In
+*Elementary Particle Theory: Relativistic Groups and Analyticity.
+Proceedings of the Eighth Nobel Symposium*, edited by Nils Svartholm,
+367–377. Stockholm: Almquist & Wiksell.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Salam, 1968)
+
+Salam, A. (1968). Weak and electromagnetic interactions. In N. Svartholm
+(Ed.), *Elementary particle theory: Relativistic groups and analyticity.
+Proceedings of the eighth Nobel symposium* (pp. 367–377). Stockholm:
+Almquist & Wiksell.
+
+
+}
+
+@InProceedings{salam,
+ author = {Salam, Abdus},
+ editor = {Svartholm, Nils},
+ title = {Weak and Electromagnetic Interactions},
+ date = 1968,
+ booktitle = {Elementary particle theory},
+ booksubtitle = {Relativistic groups and analyticity},
+ booktitleaddon= {Proceedings of the Eighth {Nobel} Symposium},
+ eventdate = {1968-05-19/1968-05-25},
+ venue = {Aspen{\"a}sgarden, Lerum},
+ publisher = {Almquist \& Wiksell},
+ location = {Stockholm},
+ pages = {367-377},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Salam
+ given: Abdus
+ container-title: 'Elementary particle theory: Relativistic groups and
+ analyticity. Proceedings of the eighth Nobel symposium'
+ editor:
+ - family: Svartholm
+ given: Nils
+ event-date: '1968-05-19/1968-05-25'
+ event-place: 'Aspenäsgarden, Lerum'
+ id: salam
+ issued: 1968
+ page: '367-377'
+ publisher: 'Almquist & Wiksell'
+ publisher-place: Stockholm
+ title: Weak and electromagnetic interactions
+ type: 'paper-conference'
+---
+
+
+```
diff --git a/test/command/biblatex-sarfraz.md b/test/command/biblatex-sarfraz.md
new file mode 100644
index 000000000..7484df833
--- /dev/null
+++ b/test/command/biblatex-sarfraz.md
@@ -0,0 +1,65 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Sarfraz and Razzak 2002)
+
+Sarfraz, M., and M. F. A. Razzak. 2002. “Technical Section: An Algorithm
+for Automatic Capturing of the Font Outlines.” *Computers and Graphics*
+26 (5): 795–804.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Sarfraz & Razzak, 2002)
+
+Sarfraz, M., & Razzak, M. F. A. (2002). Technical section: An algorithm
+for automatic capturing of the font outlines. *Computers and Graphics*,
+*26*(5), 795–804.
+
+
+}
+
+@Article{sarfraz,
+ author = {M. Sarfraz and M. F. A. Razzak},
+ title = {Technical section: {An} algorithm for automatic capturing of
+ the font outlines},
+ year = 2002,
+ volume = 26,
+ number = 5,
+ pages = {795-804},
+ issn = {0097-8493},
+ journal = {Computers and Graphics},
+ annotation = {An article entry with an issn field},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: An article entry with an issn field
+ author:
+ - family: Sarfraz
+ given: M.
+ - family: Razzak
+ given: M. F. A.
+ container-title: Computers and Graphics
+ id: sarfraz
+ issn: '0097-8493'
+ issue: 5
+ issued: 2002
+ page: '795-804'
+ title: 'Technical section: An algorithm for automatic capturing of the
+ font outlines'
+ title-short: Technical section
+ type: 'article-journal'
+ volume: 26
+---
+
+
+```
diff --git a/test/command/biblatex-shore.md b/test/command/biblatex-shore.md
new file mode 100644
index 000000000..19321ca75
--- /dev/null
+++ b/test/command/biblatex-shore.md
@@ -0,0 +1,66 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Shore 1991)
+
+Shore, Bradd. 1991. “Twice-born, Once Conceived: Meaning Construction
+and Cultural Cognition.” *American Anthropologist, New Series* 93 (1)
+(March): 9–27.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Shore, 1991)
+
+Shore, B. (1991). Twice-born, once conceived: Meaning construction and
+cultural cognition. *American Anthropologist, new series*, *93*(1),
+9–27.
+
+
+}
+
+@Article{shore,
+ author = {Shore, Bradd},
+ title = {Twice-Born, Once Conceived},
+ journaltitle = {American Anthropologist},
+ date = {1991-03},
+ subtitle = {Meaning Construction and Cultural Cognition},
+ series = {newseries},
+ volume = 93,
+ number = 1,
+ pages = {9-27},
+ annotation = {An article entry with series,
+ volume, and number fields. Note the format
+ of the series which is a localization key},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'An article entry with series, volume, and number fields. Note
+ the format of the series which is a localization key'
+ author:
+ - family: Shore
+ given: Bradd
+ collection-title: new series
+ container-title: American Anthropologist
+ id: shore
+ issue: 1
+ issued: '1991-03'
+ page: '9-27'
+ title: 'Twice-born, once conceived: Meaning construction and cultural
+ cognition'
+ title-short: 'Twice-born, once conceived'
+ type: 'article-journal'
+ volume: 93
+---
+
+
+```
diff --git a/test/command/biblatex-sigfridsson.md b/test/command/biblatex-sigfridsson.md
new file mode 100644
index 000000000..47e674f5c
--- /dev/null
+++ b/test/command/biblatex-sigfridsson.md
@@ -0,0 +1,106 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Sigfridsson and Ryde 1998)
+
+Sigfridsson, Emma, and Ulf Ryde. 1998. “Comparison of Methods for
+Deriving Atomic Charges from the Electrostatic Potential and Moments.”
+*Journal of Computational Chemistry* 19 (4): 377–395.
+doi:[10.1002/(SICI)1096-987X(199803)19:4\<377::AID-JCC1\>3.0.CO;2-P](https://doi.org/10.1002/(SICI)1096-987X(199803)19:4<377::AID-JCC1>3.0.CO;2-P "10.1002/(SICI)1096-987X(199803)19:4<377::AID-JCC1>3.0.CO;2-P").
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Sigfridsson & Ryde, 1998)
+
+Sigfridsson, E., & Ryde, U. (1998). Comparison of methods for deriving
+atomic charges from the electrostatic potential and moments. *Journal of
+Computational Chemistry*, *19*(4), 377–395.
+doi:[10.1002/(SICI)1096-987X(199803)19:4\<377::AID-JCC1\>3.0.CO;2-P](https://doi.org/10.1002/(SICI)1096-987X(199803)19:4<377::AID-JCC1>3.0.CO;2-P "10.1002/(SICI)1096-987X(199803)19:4<377::AID-JCC1>3.0.CO;2-P")
+
+
+NOTES:
+
+- biblio2xaml
+ - the string "doi:" should not appear as part of the content of the "doi" field
+
+}
+
+@Article{sigfridsson,
+ author = {Sigfridsson, Emma and Ryde, Ulf},
+ title = {Comparison of methods for deriving atomic charges from the
+ electrostatic potential and moments},
+ journaltitle = {Journal of Computational Chemistry},
+ date = 1998,
+ volume = 19,
+ number = 4,
+ pages = {377-395},
+ doi = {10.1002/(SICI)1096-987X(199803)19:4<377::AID-JCC1>3.0.CO;2-P},
+ hyphenation = {american},
+ indextitle = {Methods for deriving atomic charges},
+ annotation = {An article entry with volume,
+ number, and doi fields. Note that the
+ \textsc{doi} is transformed into a clickable link if
+ hyperref support has been enabled},
+ abstract = {Four methods for deriving partial atomic charges from the
+ quantum chemical electrostatic potential (CHELP, CHELPG,
+ Merz-Kollman, and RESP) have been compared and critically
+ evaluated. It is shown that charges strongly depend on how and
+ where the potential points are selected. Two alternative
+ methods are suggested to avoid the arbitrariness in the
+ point-selection schemes and van der Waals exclusion radii:
+ CHELP-BOW, which also estimates the charges from the
+ electrostatic potential, but with potential points that are
+ Boltzmann-weighted after their occurrence in actual
+ simulations using the energy function of the program in which
+ the charges will be used, and CHELMO, which estimates the
+ charges directly from the electrostatic multipole
+ moments. Different criteria for the quality of the charges are
+ discussed.},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- abstract: 'Four methods for deriving partial atomic charges from the
+ quantum chemical electrostatic potential (CHELP, CHELPG,
+ Merz-Kollman, and RESP) have been compared and critically evaluated.
+ It is shown that charges strongly depend on how and where the
+ potential points are selected. Two alternative methods are suggested
+ to avoid the arbitrariness in the point-selection schemes and van
+ der Waals exclusion radii: CHELP-BOW, which also estimates the
+ charges from the electrostatic potential, but with potential points
+ that are Boltzmann-weighted after their occurrence in actual
+ simulations using the energy function of the program in which the
+ charges will be used, and CHELMO, which estimates the charges
+ directly from the electrostatic multipole moments. Different
+ criteria for the quality of the charges are discussed.'
+ annote: 'An article entry with volume, number, and doi fields. Note
+ that the [doi]{.smallcaps} is transformed into a clickable link if
+ hyperref support has been enabled'
+ author:
+ - family: Sigfridsson
+ given: Emma
+ - family: Ryde
+ given: Ulf
+ container-title: Journal of Computational Chemistry
+ doi: '10.1002/(SICI)1096-987X(199803)19:4\<377::AID-JCC1\>3.0.CO;2-P'
+ id: sigfridsson
+ issue: 4
+ issued: 1998
+ language: 'en-US'
+ page: '377-395'
+ title: Comparison of methods for deriving atomic charges from the
+ electrostatic potential and moments
+ type: 'article-journal'
+ volume: 19
+---
+
+
+```
diff --git a/test/command/biblatex-sorace.md b/test/command/biblatex-sorace.md
new file mode 100644
index 000000000..2f003c063
--- /dev/null
+++ b/test/command/biblatex-sorace.md
@@ -0,0 +1,65 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Sorace, Reinhardt, and Vaughn 1997)
+
+Sorace, Ronald E., Victor S. Reinhardt, and Steven A. Vaughn. 1997.
+“High-speed Digital-to-RF Converter.” U.S. patent.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Sorace, Reinhardt, & Vaughn, 1997)
+
+Sorace, R. E., Reinhardt, V. S., & Vaughn, S. A. (1997, September 16).
+High-speed digital-to-RF converter. U.S. patent.
+
+
+}
+
+@Patent{sorace,
+ author = {Sorace, Ronald E. and Reinhardt, Victor S. and Vaughn, Steven
+ A.},
+ title = {High-Speed Digital-to-{RF} Converter},
+ number = 5668842,
+ date = {1997-09-16},
+ holder = {{Hughes Aircraft Company}},
+ type = {patentus},
+ hyphenation = {american},
+ annotation = {This is a patent entry with a holder field.
+ Note the format of the type and date fields
+ in the database file. Compare almendro,
+ laufenberg, and kowalik},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'This is a patent entry with a holder field. Note the format
+ of the type and date fields in the database file. Compare almendro,
+ laufenberg, and kowalik'
+ author:
+ - family: Sorace
+ given: Ronald E.
+ - family: Reinhardt
+ given: Victor S.
+ - family: Vaughn
+ given: Steven A.
+ genre: U.S. patent
+ id: sorace
+ issued: '1997-09-16'
+ language: 'en-US'
+ number: 5668842
+ title: 'High-speed digital-to-RF converter'
+ type: patent
+---
+
+
+```
diff --git a/test/command/biblatex-spiegelberg.md b/test/command/biblatex-spiegelberg.md
new file mode 100644
index 000000000..d17c30eab
--- /dev/null
+++ b/test/command/biblatex-spiegelberg.md
@@ -0,0 +1,74 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Spiegelberg 1969)
+
+Spiegelberg, Herbert. 1969. ““Intention” und “Intentionalität” in der
+Scholastik, bei Brentano und Husserl.” *Studia Philosophica* 29:
+189–216.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Spiegelberg, 1969)
+
+Spiegelberg, H. (1969). “Intention” und “Intentionalität” in der
+Scholastik, bei Brentano und Husserl. *Studia Philosophica*, *29*,
+189–216.
+
+
+NOTES:
+
+- citeproc
+ - flipflopping of quotes incorrect
+
+}
+
+@Article{spiegelberg,
+ author = {Spiegelberg, Herbert},
+ title = {\mkbibquote{Intention} und \mkbibquote{Intentionalit{\"a}t} in
+ der Scholastik, bei Brentano und Husserl},
+ journaltitle = {Studia Philosophica},
+ date = 1969,
+ volume = 29,
+ pages = {189-216},
+ hyphenation = {german},
+ sorttitle = {Intention und Intentionalitat in der Scholastik, bei Brentano
+ und Husserl},
+ indexsorttitle= {Intention und Intentionalitat in der Scholastik, bei Brentano
+ und Husserl},
+ shorttitle = {Intention und Intentionalit{\"a}t},
+ annotation = {An article entry. Note the sorttitle and
+ indexsorttitle fields and the markup of the quotes in
+ the database file},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: An article entry. Note the sorttitle and indexsorttitle fields
+ and the markup of the quotes in the database file
+ author:
+ - family: Spiegelberg
+ given: Herbert
+ container-title: Studia Philosophica
+ id: spiegelberg
+ issued: 1969
+ language: 'de-DE'
+ page: '189-216'
+ title: '"Intention" und "Intentionalität" in der Scholastik, bei
+ Brentano und Husserl'
+ title-short: Intention und Intentionalität
+ type: 'article-journal'
+ volume: 29
+---
+
+
+```
diff --git a/test/command/biblatex-springer.md b/test/command/biblatex-springer.md
new file mode 100644
index 000000000..9ee1f684a
--- /dev/null
+++ b/test/command/biblatex-springer.md
@@ -0,0 +1,58 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Springer 1950)
+
+Springer, Otto. 1950. “Mediaeval Pilgrim Routes from Scandinavia to
+Rome.” *Mediaeval Studies* 12: 92–122.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Springer, 1950)
+
+Springer, O. (1950). Mediaeval pilgrim routes from Scandinavia to Rome.
+*Mediaeval Studies*, *12*, 92–122.
+
+
+}
+
+@Article{springer,
+ author = {Springer, Otto},
+ title = {Mediaeval Pilgrim Routes from {Scandinavia} to {Rome}},
+ journaltitle = {Mediaeval Studies},
+ date = 1950,
+ volume = 12,
+ pages = {92-122},
+ hyphenation = {british},
+ shorttitle = {Mediaeval Pilgrim Routes},
+ annotation = {A plain article entry},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A plain article entry
+ author:
+ - family: Springer
+ given: Otto
+ container-title: Mediaeval Studies
+ id: springer
+ issued: 1950
+ language: 'en-GB'
+ page: '92-122'
+ title: Mediaeval pilgrim routes from Scandinavia to Rome
+ title-short: Mediaeval pilgrim routes
+ type: 'article-journal'
+ volume: 12
+---
+
+
+```
diff --git a/test/command/biblatex-strings.md b/test/command/biblatex-strings.md
new file mode 100644
index 000000000..d8748334c
--- /dev/null
+++ b/test/command/biblatex-strings.md
@@ -0,0 +1,46 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{excerpt from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib}
+
+@string{anch-ie = {Angew.~Chem. Int.~Ed.}}
+
+@article{herrmann,
+ Author = {Herrmann, Wolfgang A. and Öfele, Karl and Schneider, Sabine K. and Herdtweck, Eberhardt and Hoffmann, Stephan D.},
+ Date = 2006,
+ Hyphenation = {english},
+ Indextitle = {Carbocyclic carbene as an efficient catalyst, A},
+ Journaltitle = anch-ie,
+ Number = 23,
+ Pages = {3859-3862},
+ Title = {A Carbocyclic Carbene as an Efficient Catalyst Ligand for {C--C} Coupling Reactions},
+ Volume = 45}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Herrmann
+ given: Wolfgang A.
+ - family: Öfele
+ given: Karl
+ - family: Schneider
+ given: Sabine K.
+ - family: Herdtweck
+ given: Eberhardt
+ - family: Hoffmann
+ given: Stephan D.
+ container-title: Angew. Chem. Int. Ed.
+ id: herrmann
+ issue: 23
+ issued: 2006
+ language: 'en-US'
+ page: '3859-3862'
+ title: 'A carbocyclic carbene as an efficient catalyst ligand for C--C
+ coupling reactions'
+ type: 'article-journal'
+ volume: 45
+---
+
+
+```
diff --git a/test/command/biblatex-test-case-conversion.md b/test/command/biblatex-test-case-conversion.md
new file mode 100644
index 000000000..7e10ebf60
--- /dev/null
+++ b/test/command/biblatex-test-case-conversion.md
@@ -0,0 +1,73 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+ - bibtex and biblatex
+ - expect titles in title case
+ - styles use titles as is, or convert them to sentence case
+ - strings wrapped {} are not converted
+ - all CSL styles at <http://github.com/citation-style-language/styles>
+ and <https://www.zotero.org/styles/>
+ - expect titles in sentence case
+ - styles use titles as is, or convert them to title case
+ - except for (hardcoded) list of stop words, see
+ <http://citationstyles.org/downloads/specification.html#title-case-conversion>
+ - citeproc-js (MLZ only?) also recognizes a markup syntax for
+ suppressing title-case changes on a range of text (see
+ <https://forums.zotero.org/discussion/21991/excessive-capitalization-of-citation-titles/#Item_22>):
+ - `<span class="nocase"/>lowercase</span>`
+ - Proposal:
+ - When converting to yaml, convert English titles to sentence case,
+ - for all strings wrapped in {} where {} is not part of a latex
+ command, ...
+ - ... when starting with an uppercase letter: suppress
+conversion, remove the {}
+ - ... when starting with a lowercase letter ("nm", "iPod"):
+ suppress conversion, replace the {} with
+ <span class="nocase"/></span>
+ - Note: Camel case ("iPod") needs to be protected in
+ bibtex/biblatex anyway; the only "extension" (wrt bibtex/biblatex
+ specs) we'd be introducing is wrapping lowercase-only strings in
+ {}, something that is never necessary on the latex side but
+ won't break anything there either.
+ - citeproc-hs/pandoc-citeproc should be modified to honour this new
+ syntax and suppress conversion to title case for strings wrapped
+ in `<span class="nocase"/></span>`.
+ - Expected output, using one of the title-case CSL styles, here
+ chicago-author-date.csl:
+
+ Author, Ann. 2013. “A Title, in English, with a Proper Name and
+an
+ ACRONYM and a camelCase Word and Some Units, 400 nm, 3 cm, and
+a Quote,
+ *Alea iacta est*.” *Journal*.
+ }
+
+@article{item1,
+ Author = {Author, Ann},
+ Date = {2013},
+ Hyphenation = {english},
+ Journaltitle = {Journal},
+ Title = {A Title, in {English}, with a {Proper Name} and an {ACRONYM}
+and a {camelCase} Word and Some Units, 400~{nm}, 3~{cm}, and a Quote,
+\textit{{Alea} {iacta est}}}
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Author
+ given: Ann
+ container-title: Journal
+ id: item1
+ issued: 2013
+ language: 'en-US'
+ title: 'A title, in English, with a Proper Name and an ACRONYM and a
+ [camelCase]{.nocase} word and some units, 400 [nm]{.nocase},
+ 3 [cm]{.nocase}, and a quote, *Alea [iacta est]{.nocase}*'
+ type: 'article-journal'
+---
+
+
+```
diff --git a/test/command/biblatex-textnormal.md b/test/command/biblatex-textnormal.md
new file mode 100644
index 000000000..c70e9d6d4
--- /dev/null
+++ b/test/command/biblatex-textnormal.md
@@ -0,0 +1,17 @@
+```
+% pandoc -f biblatex -t markdown -s
+@book{item1,
+ Title = {The Title \textnormal{of this book}},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- id: item1
+ title: 'The title [of this book]{.nodecor}'
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-thesis.md b/test/command/biblatex-thesis.md
new file mode 100644
index 000000000..e4ee0cf13
--- /dev/null
+++ b/test/command/biblatex-thesis.md
@@ -0,0 +1,68 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{excerpted from http://mirrors.ctan.org/macros/latex/contrib/biblatex/doc/examples/biblatex-examples.bib
+
+TODO: Uppercase letters follwing hyphens need to be converted to lowercase, too (e.g., "r" in "High-Resolution". -- Same for citeproc when doing title-case conversion!)
+}
+
+@thesis{geer,
+ Annotation = {This is a typical thesis entry for a PhD thesis. Note the type field in the database file which uses a localization key. Also note the format of the printed name and compare the useprefix option in the options field as well as vangennep},
+ Author = {de Geer, Ingrid},
+ Date = 1985,
+ Hyphenation = {british},
+ Institution = {Uppsala Universitet},
+ Location = {Uppsala},
+ Options = {useprefix=false},
+ Subtitle = {The {Orkney} Earldom of the Twelfth Century. {A} Musicological Study},
+ Title = {Earl, Saint, Bishop, Skald~-- and Music},
+ Type = {phdthesis}}
+
+@thesis{loh,
+ Annotation = {This is a typical thesis entry for an MA thesis. Note the type field in the database file which uses a localization key},
+ Author = {Loh, Nin C.},
+ Date = 1992,
+ Hyphenation = {american},
+ Institution = {Massachusetts Institute of Technology},
+ Location = {Cambridge, Mass.},
+ Title = {High-Resolution Micromachined Interferometric Accelerometer},
+ Type = {mathesis}}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a typical thesis entry for a PhD thesis. Note the type
+ field in the database file which uses a localization key. Also note
+ the format of the printed name and compare the useprefix option in
+ the options field as well as vangennep
+ author:
+ - dropping-particle: de
+ family: Geer
+ given: Ingrid
+ genre: PhD thesis
+ id: geer
+ issued: 1985
+ language: 'en-GB'
+ publisher: Uppsala Universitet
+ publisher-place: Uppsala
+ title: 'Earl, saint, bishop, skald -- and music: The Orkney earldom of
+ the twelfth century. A musicological study'
+ title-short: 'Earl, saint, bishop, skald -- and music'
+ type: thesis
+- annote: This is a typical thesis entry for an MA thesis. Note the type
+ field in the database file which uses a localization key
+ author:
+ - family: Loh
+ given: Nin C.
+ genre: 'Master''s thesis'
+ id: loh
+ issued: 1992
+ language: 'en-US'
+ publisher: Massachusetts Institute of Technology
+ publisher-place: 'Cambridge, Mass.'
+ title: 'High-resolution micromachined interferometric accelerometer'
+ type: thesis
+---
+
+
+```
diff --git a/test/command/biblatex-title-and-shorttitle.md b/test/command/biblatex-title-and-shorttitle.md
new file mode 100644
index 000000000..7daa44134
--- /dev/null
+++ b/test/command/biblatex-title-and-shorttitle.md
@@ -0,0 +1,76 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+TODO:
+Slight inconsistency:
+When a biblatex “title” field contains a colon, the part before the colon is mapped to CSL “title-short”.
+When there’s a biblatex “title” and a “subtitle” field, CSL “title-short” is not set, though it would make at least as much sense to map “title” (without “subtitle”) to CSL “title-short” in this case.
+
+CSL “container-title-short” could also be set
+- from biblatex “shortjournal”
+- for inbook, incollection etc. from the “shorttitle” field of the crossreferenced book, collection etc. entry (see item5, item6)
+... but it might not really be worth it, “container-title-short” not being used once in my sample of 70+ CSL styles.
+
+}
+
+@book{item4,
+ Shorttitle = {The Shorttitle},
+ Subtitle = {And a Subtitle, in Two Separate Fields; plus a Separate “Shorttitle” Field},
+ Title = {The Title: With a Colon in the “Title” Field}}
+
+@book{item3,
+ Subtitle = {And a Subtitle, in two separate fields},
+ Title = {The Title: With a Colon in the “title” field}}
+
+@book{item2,
+ Subtitle = {The Subtitle, In Two Separate fields},
+ Title = {The Title}}
+
+@book{item1,
+ Title = {The Title: And the Subtitle, all in the “title” Field}}
+
+@inbook{item5,
+ Title = {The inbook Title: And the Subtitle, all in the “title” Field},
+ Crossref = {item6}}
+
+@book{item6,
+ Title = {The Title: And the Subtitle, all in the “title” Field},
+ Shorttitle = {The Shorttitle},
+}
+^D
+---
+nocite: '[@*]'
+references:
+- id: item4
+ title: 'The title: With a colon in the "title" field: And a subtitle,
+ in two separate fields; plus a separate "shorttitle" field'
+ title-short: The shorttitle
+ type: book
+- id: item3
+ title: 'The title: With a colon in the "title" field: And a subtitle,
+ in two separate fields'
+ title-short: The title
+ type: book
+- id: item2
+ title: 'The title: The subtitle, in two separate fields'
+ title-short: The title
+ type: book
+- id: item1
+ title: 'The title: And the subtitle, all in the "title" field'
+ title-short: The title
+ type: book
+- container-title: 'The title: And the subtitle, all in the "title"
+ field'
+ id: item5
+ title: 'The inbook title: And the subtitle, all in the "title" field'
+ title-short: The inbook title
+ type: chapter
+- id: item6
+ title: 'The title: And the subtitle, all in the "title" field'
+ title-short: The shorttitle
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-vangennep-related.md b/test/command/biblatex-vangennep-related.md
new file mode 100644
index 000000000..d23698d0b
--- /dev/null
+++ b/test/command/biblatex-vangennep-related.md
@@ -0,0 +1,69 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(van Gennep 1909)
+
+van Gennep, Arnold. 1909. *Les rites de passage*. Paris: Nourry.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(van Gennep, 1909)
+
+van Gennep, A. (1909). *Les rites de passage*. Paris: Nourry.
+
+NOTES:
+
+- biblio2yaml
+ - "related = {vizedom:related}, relatedtype = {bytranslator}": no equivalent implemented in CSL
+ - "options = {useprefix}," is shorthand for "options = {useprefix=true},"
+
+
+}
+
+@Book{vangennep:related,
+ author = {van Gennep, Arnold},
+ title = {Les rites de passage},
+ date = 1909,
+ publisher = {Nourry},
+ location = {Paris},
+ options = {useprefix},
+ hyphenation = {french},
+ related = {vizedom:related},
+ relatedtype = {bytranslator},
+ sorttitle = {Rites de passage},
+ indextitle = {Rites de passage, Les},
+ shorttitle = {Rites de passage},
+ annotation = {A variant of the vangennep entry related to its
+ translation. Note the format of the related and
+ relatedtype fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A variant of the vangennep entry related to its translation.
+ Note the format of the related and relatedtype fields
+ author:
+ - family: Gennep
+ given: Arnold
+ non-dropping-particle: van
+ id: 'vangennep:related'
+ issued: 1909
+ language: 'fr-FR'
+ publisher: Nourry
+ publisher-place: Paris
+ title: Les rites de passage
+ title-short: Rites de passage
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-vangennep-trans.md b/test/command/biblatex-vangennep-trans.md
new file mode 100644
index 000000000..21fe69d1f
--- /dev/null
+++ b/test/command/biblatex-vangennep-trans.md
@@ -0,0 +1,69 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(van Gennep 1960)
+
+van Gennep, Arnold. 1960. *The Rites of Passage*. Translated by Monika
+B. Vizedom and Gabrielle L. Caffee. University of Chicago Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(van Gennep, 1960)
+
+van Gennep, A. (1960). *The rites of passage*. (M. B. Vizedom & G. L.
+Caffee, Trans.). University of Chicago Press.
+
+
+}
+
+@Book{vangennep:trans,
+ author = {van Gennep, Arnold},
+ title = {The Rites of Passage},
+ year = 1960,
+ translator = {Vizedom, Monika B. and Caffee, Gabrielle L.},
+ language = {english},
+ origlanguage = {french},
+ publisher = {University of Chicago Press},
+ options = {useprefix},
+ indextitle = {Rites of Passage, The},
+ sorttitle = {Rites of Passage},
+ shorttitle = {Rites of Passage},
+ hyphenation = {american},
+ annotation = {A translation of the vangennep entry. Note the
+ translator and origlanguage fields. Compare
+ with the vangennep:related entry.},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A translation of the vangennep entry. Note the translator and
+ origlanguage fields. Compare with the vangennep:related entry.'
+ author:
+ - family: Gennep
+ given: Arnold
+ non-dropping-particle: van
+ id: 'vangennep:trans'
+ issued: 1960
+ language: 'en-US'
+ publisher: University of Chicago Press
+ title: The rites of passage
+ title-short: Rites of passage
+ translator:
+ - family: Vizedom
+ given: Monika B.
+ - family: Caffee
+ given: Gabrielle L.
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-vangennep.md b/test/command/biblatex-vangennep.md
new file mode 100644
index 000000000..4470d21fc
--- /dev/null
+++ b/test/command/biblatex-vangennep.md
@@ -0,0 +1,61 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(van Gennep 1909)
+
+van Gennep, Arnold. 1909. *Les rites de passage*. Paris: Nourry.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(van Gennep, 1909)
+
+van Gennep, A. (1909). *Les rites de passage*. Paris: Nourry.
+
+
+}
+
+@Book{vangennep,
+ author = {van Gennep, Arnold},
+ title = {Les rites de passage},
+ date = 1909,
+ publisher = {Nourry},
+ location = {Paris},
+ options = {useprefix},
+ hyphenation = {french},
+ sorttitle = {Rites de passage},
+ indextitle = {Rites de passage, Les},
+ shorttitle = {Rites de passage},
+ annotation = {A book entry. Note the format of the printed name and
+ compare the useprefix option in the options
+ field as well as brandt and geer},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry. Note the format of the printed name and compare
+ the useprefix option in the options field as well as brandt and geer
+ author:
+ - family: Gennep
+ given: Arnold
+ non-dropping-particle: van
+ id: vangennep
+ issued: 1909
+ language: 'fr-FR'
+ publisher: Nourry
+ publisher-place: Paris
+ title: Les rites de passage
+ title-short: Rites de passage
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-vazques-de-parga-mvbook.md b/test/command/biblatex-vazques-de-parga-mvbook.md
new file mode 100644
index 000000000..54e4f68e0
--- /dev/null
+++ b/test/command/biblatex-vazques-de-parga-mvbook.md
@@ -0,0 +1,75 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Vázques de Parga, Lacarra, and Uría Ríu 1993)
+
+Vázques de Parga, Luis, José María Lacarra, and Juan Uría Ríu. 1993.
+*Las Peregrinaciones a Santiago de Compostela*. 3. Pamplona: Iberdrola.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Vázques de Parga, Lacarra, & Uría Ríu, 1993)
+
+Vázques de Parga, L., Lacarra, J. M., & Uría Ríu, J. (1993). *Las
+Peregrinaciones a Santiago de Compostela* (1-3). Pamplona: Iberdrola.
+
+
+NOTES:
+
+- citeproc
+ - term "vols." missing
+
+}
+
+@mvbook{vazques-de-parga,
+ author = {V{\'a}zques{ de }Parga, Luis and Lacarra, Jos{\'e} Mar{\'i}a
+ and Ur{\'i}a R{\'i}u, Juan},
+ title = {Las Peregrinaciones a Santiago de Compostela},
+ date = 1993,
+ volumes = 3,
+ note = {Ed. facs. de la realizada en 1948--49},
+ publisher = {Iberdrola},
+ location = {Pamplona},
+ hyphenation = {spanish},
+ sorttitle = {Peregrinaciones a Santiago de Compostela},
+ indextitle = {Peregrinaciones a Santiago de Compostela, Las},
+ shorttitle = {Peregrinaciones},
+ annotation = {A multivolume book cited as a whole. This is a book
+ entry with volumes, note,
+ sorttitle, and indextitle fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A multivolume book cited as a whole. This is a book entry
+ with volumes, note, sorttitle, and indextitle fields'
+ author:
+ - family: Vázques de Parga
+ given: Luis
+ - family: Lacarra
+ given: José María
+ - family: Uría Ríu
+ given: Juan
+ id: 'vazques-de-parga'
+ issued: 1993
+ language: 'es-ES'
+ note: 'Ed. facs. de la realizada en 1948--49'
+ number-of-volumes: 3
+ publisher: Iberdrola
+ publisher-place: Pamplona
+ title: Las Peregrinaciones a Santiago de Compostela
+ title-short: Peregrinaciones
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-vazques-de-parga.md b/test/command/biblatex-vazques-de-parga.md
new file mode 100644
index 000000000..49cccd2ef
--- /dev/null
+++ b/test/command/biblatex-vazques-de-parga.md
@@ -0,0 +1,74 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Vázques de Parga, Lacarra, and Uría Ríu 1993)
+
+Vázques de Parga, Luis, José María Lacarra, and Juan Uría Ríu. 1993.
+*Las Peregrinaciones a Santiago de Compostela*. 3. Pamplona: Iberdrola.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Vázques de Parga, Lacarra, & Uría Ríu, 1993)
+
+Vázques de Parga, L., Lacarra, J. M., & Uría Ríu, J. (1993). *Las
+Peregrinaciones a Santiago de Compostela* (1-3). Pamplona: Iberdrola.
+
+
+NOTES:
+
+- citeproc
+ - term "vols." missing
+
+}
+
+@Book{vazques-de-parga,
+ author = {V{\'a}zques{ de }Parga, Luis and Lacarra, Jos{\'e} Mar{\'i}a
+ and Ur{\'i}a R{\'i}u, Juan},
+ title = {Las Peregrinaciones a Santiago de Compostela},
+ date = 1993,
+ volumes = 3,
+ note = {Ed. facs. de la realizada en 1948--49},
+ publisher = {Iberdrola},
+ location = {Pamplona},
+ hyphenation = {spanish},
+ sorttitle = {Peregrinaciones a Santiago de Compostela},
+ indextitle = {Peregrinaciones a Santiago de Compostela, Las},
+ shorttitle = {Peregrinaciones},
+ annotation = {A multivolume book cited as a whole. This is a book
+ entry with volumes, note,
+ sorttitle, and indextitle fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A multivolume book cited as a whole. This is a book entry
+ with volumes, note, sorttitle, and indextitle fields'
+ author:
+ - family: Vázques de Parga
+ given: Luis
+ - family: Lacarra
+ given: José María
+ - family: Uría Ríu
+ given: Juan
+ id: 'vazques-de-parga'
+ issued: 1993
+ language: 'es-ES'
+ note: 'Ed. facs. de la realizada en 1948--49'
+ number-of-volumes: 3
+ publisher: Iberdrola
+ publisher-place: Pamplona
+ title: Las Peregrinaciones a Santiago de Compostela
+ title-short: Peregrinaciones
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-video.md b/test/command/biblatex-video.md
new file mode 100644
index 000000000..e4dd251ca
--- /dev/null
+++ b/test/command/biblatex-video.md
@@ -0,0 +1,19 @@
+```
+% pandoc -f biblatex -t markdown -s
+@video{x1,title={blah}}
+@movie{x2,title={blah}}
+
+^D
+---
+nocite: '[@*]'
+references:
+- id: x1
+ title: Blah
+ type: motion_picture
+- id: x2
+ title: Blah
+ type: motion_picture
+---
+
+
+```
diff --git a/test/command/biblatex-vizedom-related.md b/test/command/biblatex-vizedom-related.md
new file mode 100644
index 000000000..105a1e84d
--- /dev/null
+++ b/test/command/biblatex-vizedom-related.md
@@ -0,0 +1,68 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Vizedom and Caffee 1960)
+
+Vizedom, Monika B., and Gabrielle L. Caffee, trans. 1960. *The Rites of
+Passage*. University of Chicago Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Vizedom & Caffee, 1960)
+
+Vizedom, M. B., & Caffee, G. L. (Trans.). (1960). *The rites of
+passage*. University of Chicago Press.
+
+
+NOTES:
+
+- biblio2yaml
+ - "related = {vangennep}, relatedtype = {translationof}": no equivalent implemented in CSL
+
+}
+
+@Book{vizedom:related,
+ title = {The Rites of Passage},
+ year = 1960,
+ translator = {Vizedom, Monika B. and Caffee, Gabrielle L.},
+ language = {english},
+ publisher = {University of Chicago Press},
+ hyphenation = {american},
+ options = {usetranslator},
+ related = {vangennep},
+ relatedtype = {translationof},
+ indextitle = {Rites of Passage, The},
+ sorttitle = {Rites of Passage},
+ shorttitle = {Rites of Passage},
+ annotation = {A translated work from vangennep. Note the format of
+ the related and relatedtype fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A translated work from vangennep. Note the format of the
+ related and relatedtype fields
+ id: 'vizedom:related'
+ issued: 1960
+ language: 'en-US'
+ publisher: University of Chicago Press
+ title: The rites of passage
+ title-short: Rites of passage
+ translator:
+ - family: Vizedom
+ given: Monika B.
+ - family: Caffee
+ given: Gabrielle L.
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-wassenberg.md b/test/command/biblatex-wassenberg.md
new file mode 100644
index 000000000..26ceb218f
--- /dev/null
+++ b/test/command/biblatex-wassenberg.md
@@ -0,0 +1,83 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Wassenberg and Sanders 2010)
+
+Wassenberg, Jan, and Peter Sanders. 2010. “Faster Radix Sort via Virtual
+Memory and Write-combining” (version 1). August 17.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Wassenberg & Sanders, 2010)
+
+Wassenberg, J., & Sanders, P. (2010, August 17). Faster radix sort via
+virtual memory and write-combining.
+
+
+NOTES:
+
+- biblio2yaml
+ - "eprinttype = {arxiv}, eprintclass = {cs.DS}, eprint = {1008.2849v1}" should be used to reconstruct a Url: http://arxiv.org/abs/1008.2849v1 ("cs.DS" does not seem to be essential)
+
+}
+
+@Online{wassenberg,
+ author = {Wassenberg, Jan and Sanders, Peter},
+ title = {Faster Radix Sort via Virtual Memory and Write-Combining},
+ date = {2010-08-17},
+ version = 1,
+ hyphenation = {american},
+ eprinttype = {arxiv},
+ eprintclass = {cs.DS},
+ eprint = {1008.2849v1},
+ annotation = {A recent online reference from arXiv using the new
+ (April 2007 onward) identifier format. Note the
+ eprint, eprinttype, and eprintclass
+ fields. Also note that the arXiv reference is transformed into
+ a clickable link if hyperref support has been
+ enabled},
+ abstract = {Sorting algorithms are the deciding factor for the performance
+ of common operations such as removal of duplicates or database
+ sort-merge joins. This work focuses on 32-bit integer keys,
+ optionally paired with a 32-bit value. We present a fast radix
+ sorting algorithm that builds upon a microarchitecture-aware
+ variant of counting sort},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- abstract: 'Sorting algorithms are the deciding factor for the
+ performance of common operations such as removal of duplicates or
+ database sort-merge joins. This work focuses on 32-bit integer keys,
+ optionally paired with a 32-bit value. We present a fast radix
+ sorting algorithm that builds upon a microarchitecture-aware variant
+ of counting sort'
+ annote: 'A recent online reference from arXiv using the new (April
+ 2007 onward) identifier format. Note the eprint, eprinttype, and
+ eprintclass fields. Also note that the arXiv reference is
+ transformed into a clickable link if hyperref support has been
+ enabled'
+ author:
+ - family: Wassenberg
+ given: Jan
+ - family: Sanders
+ given: Peter
+ id: wassenberg
+ issued: '2010-08-17'
+ language: 'en-US'
+ title: 'Faster radix sort via virtual memory and write-combining'
+ type: webpage
+ url: 'http://arxiv.org/abs/1008.2849v1'
+ version: 1
+---
+
+
+```
diff --git a/test/command/biblatex-weinberg.md b/test/command/biblatex-weinberg.md
new file mode 100644
index 000000000..5048122ed
--- /dev/null
+++ b/test/command/biblatex-weinberg.md
@@ -0,0 +1,52 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Weinberg 1967)
+
+Weinberg, Steven. 1967. “A Model of Leptons.” *Phys. Rev. Lett.* 19:
+1264–1266.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Weinberg, 1967)
+
+Weinberg, S. (1967). A model of leptons. *Phys. Rev. Lett.*, *19*,
+1264–1266.
+
+
+}
+
+@Article{weinberg,
+ author = {Weinberg, Steven},
+ title = {A Model of Leptons},
+ journaltitle = {Phys.~Rev.~Lett.},
+ date = 1967,
+ volume = 19,
+ pages = {1264-1266},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Weinberg
+ given: Steven
+ container-title: Phys. Rev. Lett.
+ id: weinberg
+ issued: 1967
+ page: '1264-1266'
+ title: A model of leptons
+ type: 'article-journal'
+ volume: 19
+---
+
+
+```
diff --git a/test/command/biblatex-westfahl-frontier.md b/test/command/biblatex-westfahl-frontier.md
new file mode 100644
index 000000000..46db9a8a3
--- /dev/null
+++ b/test/command/biblatex-westfahl-frontier.md
@@ -0,0 +1,60 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Westfahl 2000)
+
+Westfahl, Gary, ed. 2000. *Space and Beyond: The Frontier Theme in
+Science Fiction*. Westport, Conn.; London: Greenwood.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Westfahl, 2000)
+
+Westfahl, G. (Ed.). (2000). *Space and beyond: The frontier theme in
+science fiction*. Westport, Conn.; London: Greenwood.
+
+
+}
+
+@Collection{westfahl:frontier,
+ editor = {Westfahl, Gary},
+ title = {Space and Beyond},
+ date = 2000,
+ subtitle = {The Frontier Theme in Science Fiction},
+ publisher = {Greenwood},
+ location = {Westport, Conn. and London},
+ hyphenation = {american},
+ booktitle = {Space and Beyond},
+ booksubtitle = {The Frontier Theme in Science Fiction},
+ annotation = {This is a collection entry. Note the format of the
+ location field as well as the subtitle and
+ booksubtitle fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: This is a collection entry. Note the format of the location
+ field as well as the subtitle and booksubtitle fields
+ editor:
+ - family: Westfahl
+ given: Gary
+ id: 'westfahl:frontier'
+ issued: 2000
+ language: 'en-US'
+ publisher: Greenwood
+ publisher-place: 'Westport, Conn.; London'
+ title: 'Space and beyond: The frontier theme in science fiction'
+ title-short: Space and beyond
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-westfahl-space.md b/test/command/biblatex-westfahl-space.md
new file mode 100644
index 000000000..d50ed1448
--- /dev/null
+++ b/test/command/biblatex-westfahl-space.md
@@ -0,0 +1,106 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Westfahl 2000a) (Westfahl 2000b)
+
+Westfahl, Gary. 2000a. “The True Frontier: Confronting and Avoiding the
+Realities of Space in American Science Fiction Films.” In *Space and
+Beyond: The Frontier Theme in Science Fiction*, edited by Gary Westfahl,
+55–65. Westport, Conn.; London: Greenwood.
+
+———, ed. 2000b. *Space and Beyond: The Frontier Theme in Science
+Fiction*. Westport, Conn.; London: Greenwood.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Westfahl, 2000) (Westfahl, 2000)
+
+Westfahl, G. (2000). The true frontier: Confronting and avoiding the
+realities of space in American science fiction films. In G. Westfahl
+(Ed.), *Space and beyond: The frontier theme in science fiction* (pp.
+55–65). Westport, Conn.; London: Greenwood.
+
+Westfahl, G. (Ed.). (2000). *Space and beyond: The frontier theme in
+science fiction*. Westport, Conn.; London: Greenwood.
+
+
+}
+
+@InCollection{westfahl:space,
+ author = {Westfahl, Gary},
+ title = {The True Frontier},
+ subtitle = {Confronting and Avoiding the Realities of Space in {American}
+ Science Fiction Films},
+ pages = {55-65},
+ crossref = {westfahl:frontier},
+ hyphenation = {american},
+ indextitle = {True Frontier, The},
+ annotation = {A cross-referenced article from a collection. This is
+ an incollection entry with a crossref
+ field. Note the subtitle and indextitle
+ fields},
+}
+
+@Collection{westfahl:frontier,
+ editor = {Westfahl, Gary},
+ title = {Space and Beyond},
+ date = 2000,
+ subtitle = {The Frontier Theme in Science Fiction},
+ publisher = {Greenwood},
+ location = {Westport, Conn. and London},
+ hyphenation = {american},
+ booktitle = {Space and Beyond},
+ booksubtitle = {The Frontier Theme in Science Fiction},
+ annotation = {This is a collection entry. Note the format of the
+ location field as well as the subtitle and
+ booksubtitle fields},
+}
+^D
+---
+nocite: '[@*]'
+references:
+- annote: 'A cross-referenced article from a collection. This is an
+ incollection entry with a crossref field. Note the subtitle and
+ indextitle fields'
+ author:
+ - family: Westfahl
+ given: Gary
+ container-title: 'Space and beyond: The frontier theme in science
+ fiction'
+ editor:
+ - family: Westfahl
+ given: Gary
+ id: 'westfahl:space'
+ issued: 2000
+ language: 'en-US'
+ page: '55-65'
+ publisher: Greenwood
+ publisher-place: 'Westport, Conn.; London'
+ title: 'The true frontier: Confronting and avoiding the realities of
+ space in American science fiction films'
+ title-short: The true frontier
+ type: chapter
+- annote: This is a collection entry. Note the format of the location
+ field as well as the subtitle and booksubtitle fields
+ editor:
+ - family: Westfahl
+ given: Gary
+ id: 'westfahl:frontier'
+ issued: 2000
+ language: 'en-US'
+ publisher: Greenwood
+ publisher-place: 'Westport, Conn.; London'
+ title: 'Space and beyond: The frontier theme in science fiction'
+ title-short: Space and beyond
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-wilde.md b/test/command/biblatex-wilde.md
new file mode 100644
index 000000000..f83b11681
--- /dev/null
+++ b/test/command/biblatex-wilde.md
@@ -0,0 +1,65 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Wilde 1899)
+
+Wilde, Oscar. 1899. *The Importance of Being Earnest: A Trivial Comedy
+for Serious People*. English and American Drama of the Nineteenth
+Century. Leonard Smithers and Company.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Wilde, 1899)
+
+Wilde, O. (1899). *The importance of being earnest: A trivial comedy for
+serious people*. Leonard Smithers and Company.
+
+
+NOTES:
+
+- biblio2yaml
+ - From "eprint = {4HIWAAAAYAAJ}, eprinttype = {googlebooks}", a url could be reconstructed, shortest form: http://books.google.com?id=4HIWAAAAYAAJ
+
+}
+
+@Book{wilde,
+ author = {Wilde, Oscar},
+ title = {The Importance of Being Earnest: {A} Trivial Comedy for Serious
+ People},
+ year = 1899,
+ series = {English and American drama of the Nineteenth Century},
+ publisher = {Leonard Smithers {and} Company},
+ eprint = {4HIWAAAAYAAJ},
+ eprinttype = {googlebooks},
+ annotation = {A book with eprint and eprinttype
+ fields.},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book with eprint and eprinttype fields.
+ author:
+ - family: Wilde
+ given: Oscar
+ collection-title: English and american drama of the nineteenth century
+ id: wilde
+ issued: 1899
+ publisher: Leonard Smithers and Company
+ title: 'The importance of being earnest: A trivial comedy for serious
+ people'
+ title-short: The importance of being earnest
+ type: book
+ url: 'http://books.google.com?id=4HIWAAAAYAAJ'
+---
+
+
+```
diff --git a/test/command/biblatex-worman.md b/test/command/biblatex-worman.md
new file mode 100644
index 000000000..8e1bb8360
--- /dev/null
+++ b/test/command/biblatex-worman.md
@@ -0,0 +1,60 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Worman 2002)
+
+Worman, Nancy. 2002. *The Cast of Character: Style in Greek Literature*.
+Austin: University of Texas Press.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Worman, 2002)
+
+Worman, N. (2002). *The cast of character: Style in Greek literature*.
+Austin: University of Texas Press.
+
+
+}
+
+@Book{worman,
+ author = {Worman, Nancy},
+ title = {The Cast of Character},
+ date = 2002,
+ publisher = {University of Texas Press},
+ location = {Austin},
+ hyphenation = {american},
+ sorttitle = {Cast of Character},
+ indextitle = {Cast of Character, The},
+ subtitle = {Style in {Greek} Literature},
+ shorttitle = {Cast of Character},
+ annotation = {A book entry. Note the sorttitle and
+ indextitle fields},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- annote: A book entry. Note the sorttitle and indextitle fields
+ author:
+ - family: Worman
+ given: Nancy
+ id: worman
+ issued: 2002
+ language: 'en-US'
+ publisher: University of Texas Press
+ publisher-place: Austin
+ title: 'The cast of character: Style in Greek literature'
+ title-short: Cast of character
+ type: book
+---
+
+
+```
diff --git a/test/command/biblatex-yoon.md b/test/command/biblatex-yoon.md
new file mode 100644
index 000000000..0a4648126
--- /dev/null
+++ b/test/command/biblatex-yoon.md
@@ -0,0 +1,67 @@
+```
+% pandoc -f biblatex -t markdown -s
+@comment{
+
+Adapted from biblatex-example.bib
+
+
+Formatted with pandoc and chicago-author-date.csl, 2013-10-23:
+
+(Yoon et al. 2006)
+
+Yoon, Myeong S., Dowook Ryu, Jeongryul Kim, and Kyo Han Ahn. 2006.
+“Palladium Pincer Complexes with Reduced Bond Angle Strain: Efficient
+Catalysts for the Heck Reaction.” *Organometallics* 25 (10): 2409–2411.
+
+
+Formatted with pandoc and apa.csl, 2013-10-23:
+
+(Yoon, Ryu, Kim, & Ahn, 2006)
+
+Yoon, M. S., Ryu, D., Kim, J., & Ahn, K. H. (2006). Palladium pincer
+complexes with reduced bond angle strain: Efficient catalysts for the
+Heck reaction. *Organometallics*, *25*(10), 2409–2411.
+
+
+}
+
+@Article{yoon,
+ author = {Yoon, Myeong S. and Ryu, Dowook and Kim, Jeongryul and Ahn,
+ Kyo Han},
+ title = {Palladium pincer complexes with reduced bond angle strain:
+ efficient catalysts for the {Heck} reaction},
+ journaltitle = {Organometallics},
+ date = 2006,
+ volume = 25,
+ number = 10,
+ pages = {2409-2411},
+ indextitle = {Palladium pincer complexes},
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Yoon
+ given: Myeong S.
+ - family: Ryu
+ given: Dowook
+ - family: Kim
+ given: Jeongryul
+ - family: Ahn
+ given: Kyo Han
+ container-title: Organometallics
+ id: yoon
+ issue: 10
+ issued: 2006
+ page: '2409-2411'
+ title: 'Palladium pincer complexes with reduced bond angle strain:
+ Efficient catalysts for the Heck reaction'
+ title-short: Palladium pincer complexes with reduced bond angle strain
+ type: 'article-journal'
+ volume: 25
+---
+
+
+```
diff --git a/test/command/biblio.bib b/test/command/biblio.bib
new file mode 100644
index 000000000..4eb2ba0d0
--- /dev/null
+++ b/test/command/biblio.bib
@@ -0,0 +1,26 @@
+@Book{item1,
+author="John Doe",
+title="First Book",
+year="2005",
+address="Cambridge",
+publisher="Cambridge University Press"
+}
+
+@Article{item2,
+author="John Doe",
+title="Article",
+year="2006",
+journal="Journal of Generic Studies",
+volume="6",
+pages="33-34"
+}
+
+@InCollection{пункт3,
+author="John Doe and Jenny Roe",
+title="Why Water Is Wet",
+booktitle="Third Book",
+editor="Sam Smith",
+publisher="Oxford University Press",
+address="Oxford",
+year="2007"
+}
diff --git a/test/command/bibtex-basic.md b/test/command/bibtex-basic.md
new file mode 100644
index 000000000..7872d9489
--- /dev/null
+++ b/test/command/bibtex-basic.md
@@ -0,0 +1,71 @@
+```
+% pandoc -f biblatex -t markdown -s
+@Book{item1,
+author="John Doe",
+title="First Book",
+year="2005",
+address="Cambridge",
+publisher="Cambridge University Press"
+}
+
+@Article{item2,
+author="John Doe",
+title="Article",
+year="2006",
+journal="Journal of Generic Studies",
+volume="6",
+pages="33-34"
+}
+
+@InCollection{пункт3,
+author="John Doe and Jenny Roe",
+title="Why Water Is Wet",
+booktitle="Third Book",
+editor="Sam Smith",
+publisher="Oxford University Press",
+address="Oxford",
+year="2007"
+}
+
+^D
+---
+nocite: '[@*]'
+references:
+- author:
+ - family: Doe
+ given: John
+ id: item1
+ issued: 2005
+ publisher: Cambridge University Press
+ publisher-place: Cambridge
+ title: First book
+ type: book
+- author:
+ - family: Doe
+ given: John
+ container-title: Journal of Generic Studies
+ id: item2
+ issued: 2006
+ page: '33-34'
+ title: Article
+ type: 'article-journal'
+ volume: 6
+- author:
+ - family: Doe
+ given: John
+ - family: Roe
+ given: Jenny
+ container-title: Third book
+ editor:
+ - family: Smith
+ given: Sam
+ id: пункт3
+ issued: 2007
+ publisher: Oxford University Press
+ publisher-place: Oxford
+ title: Why water is wet
+ type: chapter
+---
+
+
+```
diff --git a/test/command/bioethics.csl b/test/command/bioethics.csl
new file mode 100644
index 000000000..d5cc0774d
--- /dev/null
+++ b/test/command/bioethics.csl
@@ -0,0 +1,226 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" version="1.0" page-range-format="minimal-two" demote-non-dropping-particle="never" default-locale="en-GB">
+ <info>
+ <title>Bioethics</title>
+ <id>http://www.zotero.org/styles/bioethics</id>
+ <link href="http://www.zotero.org/styles/bioethics" rel="self"/>
+ <link href="http://www.zotero.org/styles/journal-of-roman-archaeology-b" rel="template"/>
+ <link href="http://onlinelibrary.wiley.com/journal/10.1111/(ISSN)1467-8519/homepage/ForAuthors.html" rel="documentation"/>
+ <author>
+ <name>Patrick O'Brien</name>
+ </author>
+ <category citation-format="note"/>
+ <category field="anthropology"/>
+ <issn>0269-9702</issn>
+ <eissn>1467-8519</eissn>
+ <updated>2017-07-12T11:26:44+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <macro name="editor">
+ <names variable="editor">
+ <name sort-separator=", " initialize-with="." delimiter=", "/>
+ <label form="short" prefix=", "/>
+ <substitute>
+ <text macro="container-author"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="container-author">
+ <names variable="container-author" delimiter=", ">
+ <name sort-separator=", " initialize-with="." delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="author">
+ <names variable="author">
+ <name initialize-with="."/>
+ <substitute>
+ <text macro="editor"/>
+ <text variable="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="editor-short">
+ <names variable="editor">
+ <name form="short" sort-separator=", " delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="container-author-short">
+ <names variable="container-author" delimiter=", ">
+ <name form="short" sort-separator=", " delimiter=", "/>
+ <et-al font-style="italic"/>
+ </names>
+ </macro>
+ <macro name="author-short">
+ <names variable="author">
+ <name form="short" sort-separator=", " delimiter=", "/>
+ <et-al font-style="italic"/>
+ <substitute>
+ <text macro="editor-short"/>
+ <text macro="container-author-short"/>
+ <text variable="title-short" font-style="italic"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="collection">
+ <group delimiter=" " suffix=", ">
+ <text variable="collection-title"/>
+ <text variable="collection-number"/>
+ </group>
+ </macro>
+ <macro name="encyclopedia">
+ <group delimiter=" ">
+ <choose>
+ <if variable="title-short" match="any">
+ <text variable="title" form="short" font-style="italic"/>
+ </if>
+ <else>
+ <text variable="container-title" font-style="italic"/>
+ </else>
+ </choose>
+ <text variable="volume"/>
+ <date variable="issued" prefix="(" suffix=")">
+ <date-part name="year"/>
+ </date>
+ <text variable="page" suffix=","/>
+ <text variable="title" prefix="s.v. " quotes="true"/>
+ <text macro="author" prefix="(" suffix=")"/>
+ </group>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="book thesis" match="any">
+ <text variable="title" font-style="italic"/>
+ </if>
+ <else-if type="webpage post-weblog" match="any">
+ <date form="text" variable="issued" suffix=". "/>
+ <text variable="title" font-style="italic" suffix=". "/>
+ <text variable="container-title" font-style="italic"/>
+ </else-if>
+ <else-if type="article-journal article-magazine article-newspaper" match="any">
+ <group delimiter=". ">
+ <text variable="title" quotes="false"/>
+ <group delimiter=" ">
+ <text variable="container-title" form="short" strip-periods="true" font-style="italic"/>
+ <group delimiter="; ">
+ <text macro="year-date"/>
+ <group delimiter=": ">
+ <group>
+ <text variable="volume"/>
+ <text variable="issue" prefix="(" suffix=")"/>
+ </group>
+ <text variable="page"/>
+ </group>
+ </group>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="chapter paper-conference" match="any">
+ <group delimiter=". " suffix=". ">
+ <text macro="year-date"/>
+ <text variable="title" quotes="false"/>
+ </group>
+ <group delimiter=". ">
+ <group delimiter=" ">
+ <text term="in" text-case="capitalize-first"/>
+ <text macro="editor"/>
+ </group>
+ <text variable="container-title"/>
+ </group>
+ </else-if>
+ <else>
+ <text variable="title" font-style="italic" font-weight="bold"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if variable="collection-title" match="any">
+ <text macro="collection"/>
+ </if>
+ <else-if type="thesis">
+ <text variable="genre" suffix=","/>
+ <text variable="publisher"/>
+ </else-if>
+ <else>
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="year-date">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else>
+ <text term="no date" form="short"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="locator">
+ <choose>
+ <if locator="page">
+ <text variable="locator" prefix=": "/>
+ </if>
+ <else-if locator="paragraph">
+ <text variable="locator" prefix="§"/>
+ </else-if>
+ <else-if type="webpage post-weblog" match="any">
+ <group delimiter=" " prefix=". ">
+ <group delimiter=": ">
+ <text term="available at" text-case="capitalize-first"/>
+ <text variable="URL"/>
+ </group>
+ <group delimiter=" " prefix="[" suffix="]">
+ <text term="accessed" text-case="capitalize-first"/>
+ <date form="text" variable="accessed"/>
+ </group>
+ </group>
+ </else-if>
+ <else>
+ <text variable="page" prefix=": "/>
+ </else>
+ </choose>
+ </macro>
+ <citation and="symbol" delimiter-precedes-et-al="always" delimiter-precedes-last="always" et-al-min="3" et-al-use-first="1">
+ <layout delimiter="; " suffix=".">
+ <choose>
+ <if type="entry-dictionary entry-encyclopedia" match="any">
+ <text macro="encyclopedia"/>
+ </if>
+ <else-if position="ibid-with-locator">
+ <group delimiter=" ">
+ <text term="ibid" suffix="."/>
+ <text macro="locator"/>
+ </group>
+ </else-if>
+ <else-if position="ibid">
+ <text term="ibid" suffix="."/>
+ </else-if>
+ <else-if position="subsequent">
+ <group delimiter=" ">
+ <text macro="author-short"/>
+ <group prefix="(" suffix=")" delimiter=" ">
+ <text term="cited"/>
+ <group delimiter="&#160;">
+ <text term="note" form="short"/>
+ <text variable="first-reference-note-number"/>
+ </group>
+ </group>
+ <text macro="locator"/>
+ </group>
+ </else-if>
+ <else>
+ <text macro="author" suffix=". "/>
+ <text macro="title"/>
+ <text macro="publisher" prefix=". "/>
+ <text macro="locator"/>
+ </else>
+ </choose>
+ </layout>
+ </citation>
+</style>
diff --git a/test/command/chicago-annotated-bibliography.csl b/test/command/chicago-annotated-bibliography.csl
new file mode 100644
index 000000000..5e891c09e
--- /dev/null
+++ b/test/command/chicago-annotated-bibliography.csl
@@ -0,0 +1,1207 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" version="1.0" demote-non-dropping-particle="never" page-range-format="chicago">
+ <info>
+ <title>Chicago Manual of Style 16th edition (note, annotated bibliography)</title>
+ <id>http://www.zotero.org/styles/chicago-annotated-bibliography</id>
+ <link href="http://www.zotero.org/styles/chicago-annotated-bibliography" rel="self"/>
+ <link href="http://www.chicagomanualofstyle.org/tools_citationguide.html" rel="documentation"/>
+ <author>
+ <name>Julian Onions</name>
+ <email>julian.onions@gmail.com</email>
+ </author>
+ <contributor>
+ <name>Simon Kornblith</name>
+ <email>simon@simonster.com</email>
+ </contributor>
+ <contributor>
+ <name>Elena Razlogova</name>
+ <email>elena.razlogova@gmail.com</email>
+ </contributor>
+ <contributor>
+ <name>Frank Bennett</name>
+ <email>biercenator@gmail.com</email>
+ </contributor>
+ <contributor>
+ <name>Andrew Dunning</name>
+ <email>andrew.dunning@utoronto.ca</email>
+ </contributor>
+ <category citation-format="note"/>
+ <category field="generic-base"/>
+ <summary>Chicago format with short notes and annotated bibliography</summary>
+ <updated>2012-10-25T21:15:26+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en">
+ <terms>
+ <term name="editor" form="verb-short">ed.</term>
+ <term name="translator" form="verb-short">trans.</term>
+ <term name="editortranslator" form="verb-short">
+ <single>ed. and trans.</single>
+ <multiple>ed. and trans.</multiple>
+ </term>
+ <term name="editortranslator" form="verb">
+ <single>Edited and translated by</single>
+ <multiple>Edited and translated by</multiple>
+ </term>
+ <term name="translator" form="short">trans.</term>
+ </terms>
+ </locale>
+ <macro name="editor-translator">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <choose>
+ <if variable="container-author reviewed-author" match="any">
+ <group>
+ <names variable="container-author reviewed-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </if>
+ </choose>
+ </group>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </macro>
+ <macro name="secondary-contributors-note">
+ <choose>
+ <if type="chapter paper-conference" match="none">
+ <text macro="editor-translator"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-contributors-note">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text macro="editor-translator"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="secondary-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="none">
+ <names variable="editor translator" delimiter=". ">
+ <label form="verb" text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <group delimiter=", ">
+ <choose>
+ <if variable="author">
+ <choose>
+ <if variable="container-author" match="any">
+ <names variable="container-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ <!--This includes page numers after the container author, e.g. for Introductions -->
+ <choose>
+ <if variable="container-author author" match="all">
+ <group delimiter=". ">
+ <text variable="page"/>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </if>
+ <else>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="recipient-note">
+ <names variable="recipient" delimiter=", ">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="contributors-note">
+ <group delimiter=" ">
+ <names variable="author">
+ <name and="text" sort-separator=", " delimiter=", "/>
+ <label form="short" prefix=", "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ </substitute>
+ </names>
+ <text macro="recipient-note"/>
+ </group>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="translator">
+ <names variable="translator">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="verb-short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="recipient">
+ <group delimiter=" ">
+ <choose>
+ <if type="personal_communication">
+ <choose>
+ <if variable="genre">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ <else>
+ <text term="letter" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ <text macro="recipient-note"/>
+ </group>
+ </macro>
+ <macro name="contributors">
+ <group delimiter=". ">
+ <names variable="author">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <substitute>
+ <text macro="editor"/>
+ <text macro="translator"/>
+ </substitute>
+ </names>
+ <text macro="recipient"/>
+ </group>
+ </macro>
+ <macro name="recipient-short">
+ <names variable="recipient">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name form="short" and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="contributors-short">
+ <group delimiter=" ">
+ <names variable="author">
+ <name form="short" and="text" delimiter=", "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ </substitute>
+ </names>
+ <text macro="recipient-short"/>
+ </group>
+ </macro>
+ <macro name="contributors-sort">
+ <names variable="author">
+ <name name-as-sort-order="all" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="interviewer-note">
+ <names variable="interviewer" delimiter=", ">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="interviewer">
+ <names variable="interviewer" delimiter=", ">
+ <label form="verb" text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="title-note">
+ <choose>
+ <if variable="title" match="none">
+ <text variable="genre"/>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" font-style="italic"/>
+ <group delimiter=" " prefix=", ">
+ <text term="version"/>
+ <text variable="version"/>
+ </group>
+ </else-if>
+ <else-if type="legal_case interview" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else-if variable="reviewed-author">
+ <text variable="title" font-style="italic" prefix="review of "/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if variable="title" match="none">
+ <choose>
+ <if type="personal_communication" match="none">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" font-style="italic"/>
+ <group prefix=" (" suffix=")" delimiter=" ">
+ <text term="version"/>
+ <text variable="version"/>
+ </group>
+ </else-if>
+ <else-if variable="reviewed-author">
+ <group delimiter=", ">
+ <text variable="title" font-style="italic" prefix="Review of "/>
+ <names variable="reviewed-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </else-if>
+ <else-if type="legal_case interview" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title-short">
+ <choose>
+ <if variable="title" match="none">
+ <choose>
+ <if type="interview">
+ <text term="interview"/>
+ </if>
+ <else-if type="manuscript speech" match="any">
+ <text variable="genre" form="short"/>
+ </else-if>
+ <else-if type="personal_communication">
+ <text macro="issued"/>
+ </else-if>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" form="short" font-style="italic"/>
+ </else-if>
+ <else-if type="legal_case interview" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" form="short" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="date-disambiguate">
+ <choose>
+ <if disambiguate="true">
+ <text macro="issued"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="description-note">
+ <group delimiter=", ">
+ <text macro="interviewer-note"/>
+ <text variable="medium"/>
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="manuscript thesis speech" match="any"/>
+ <else>
+ <text variable="genre"/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <macro name="description">
+ <group delimiter=", ">
+ <group delimiter=". ">
+ <text macro="interviewer"/>
+ <text variable="medium" text-case="capitalize-first"/>
+ </group>
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis speech" match="any"/>
+ <else>
+ <text variable="genre" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <macro name="container-title-note">
+ <group delimiter=" ">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text term="in"/>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <text variable="container-title" text-case="title" font-style="italic"/>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="container-title">
+ <group delimiter=" ">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text term="in" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <text variable="container-title" text-case="title" font-style="italic"/>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="collection-title">
+ <choose>
+ <if match="none" type="article-journal">
+ <choose>
+ <if match="none" is-numeric="collection-number">
+ <group delimiter=", ">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=" ">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number"/>
+ </group>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="collection-title-journal">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=" ">
+ <text variable="collection-title"/>
+ <text variable="collection-number"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="edition-note">
+ <choose>
+ <if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" text-case="capitalize-first" suffix="."/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-note-join-with-space">
+ <choose>
+ <if type="article-journal" variable="volume" match="all">
+ <choose>
+ <if match="none" variable="collection-title">
+ <text macro="locators-note"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-note-join-with-comma">
+ <choose>
+ <if type="article-journal" match="none">
+ <text macro="locators-note"/>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume" match="none">
+ <text macro="locators-note"/>
+ </if>
+ <else-if match="any" variable="collection-title">
+ <text macro="locators-note"/>
+ </else-if>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-note">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=", ">
+ <text macro="collection-title-journal"/>
+ <number variable="volume"/>
+ <group delimiter=" ">
+ <text term="issue" form="short"/>
+ <number variable="issue"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="legal_case">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <number variable="volume"/>
+ <text variable="container-title"/>
+ <text variable="page"/>
+ </group>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else-if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <group delimiter=", ">
+ <text macro="edition-note"/>
+ <group delimiter=" ">
+ <text term="volume" form="short"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <choose>
+ <if variable="locator" match="none">
+ <group delimiter=" ">
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" plural="true"/>
+ </group>
+ </if>
+ </choose>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-join-with-space">
+ <choose>
+ <if type="article-journal" variable="volume" match="all">
+ <choose>
+ <if match="none" variable="collection-title">
+ <text macro="locators"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-join-with-comma">
+ <choose>
+ <if type="legal_case chapter paper-conference" match="any">
+ <text macro="locators"/>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume" match="none">
+ <text macro="locators"/>
+ </if>
+ <else-if match="any" variable="collection-title">
+ <text macro="locators"/>
+ </else-if>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-join-with-period">
+ <choose>
+ <if type="legal_case article-journal chapter paper-conference" match="none">
+ <text macro="locators"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=", ">
+ <text macro="collection-title-journal"/>
+ <number variable="volume"/>
+ <group delimiter=" ">
+ <text term="issue" form="short"/>
+ <number variable="issue"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="legal_case">
+ <group delimiter=" ">
+ <number variable="volume"/>
+ <text variable="container-title"/>
+ <text variable="page"/>
+ </group>
+ </else-if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <group delimiter=". ">
+ <text macro="edition"/>
+ <group delimiter=" ">
+ <text term="volume" form="short" text-case="capitalize-first"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <group delimiter=" ">
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" plural="true"/>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="chapter paper-conference" match="any">
+ <group delimiter=". ">
+ <text macro="edition"/>
+ <choose>
+ <if variable="page" match="none">
+ <group delimiter=" ">
+ <text term="volume" form="short" text-case="capitalize-first"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ </if>
+ </choose>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-newspaper">
+ <choose>
+ <if type="article-newspaper">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <number variable="edition"/>
+ <text term="edition"/>
+ </group>
+ <group delimiter=" ">
+ <text term="section" form="short"/>
+ <text variable="section"/>
+ </group>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="event-note">
+ <text variable="event"/>
+ </macro>
+ <macro name="event">
+ <choose>
+ <if variable="title">
+ <group delimiter=" ">
+ <text term="presented at"/>
+ <text variable="event"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=" ">
+ <text term="presented at" text-case="capitalize-first"/>
+ <text variable="event"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="originally-published">
+ <group delimiter=", ">
+ <group delimiter=": ">
+ <text variable="original-publisher-place"/>
+ <text variable="original-publisher"/>
+ </group>
+ <date variable="original-date" form="text" date-parts="year"/>
+ </group>
+ </macro>
+ <macro name="reprint-note">
+ <!--needs localization-->
+ <choose>
+ <if variable="original-date issued" match="all">
+ <choose>
+ <!--for whatever reason in notes, when we have both original and new publishers, reprint doesn't appear-->
+ <if variable="original-publisher original-publisher-place" match="none">
+ <text value="repr."/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="reprint">
+ <!--needs localization-->
+ <choose>
+ <if variable="original-date issued" match="all">
+ <text value="reprint" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if type="thesis">
+ <text variable="publisher"/>
+ </if>
+ <else-if type="speech">
+ <text variable="event-place"/>
+ </else-if>
+ <else>
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issued">
+ <choose>
+ <if variable="issued">
+ <choose>
+ <if type="graphic report" match="any">
+ <date variable="issued" form="text"/>
+ </if>
+ <else-if type="legal_case">
+ <group delimiter=" ">
+ <text variable="authority"/>
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </group>
+ </else-if>
+ <else-if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song thesis" match="any">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </else-if>
+ <else>
+ <date variable="issued" form="text"/>
+ </else>
+ </choose>
+ </if>
+ <else-if variable="status">
+ <text variable="status"/>
+ </else-if>
+ <else-if variable="accessed URL" match="all"/>
+ <else>
+ <text term="no date" form="short"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="point-locators-subsequent">
+ <choose>
+ <if type="legal_case"/>
+ <else-if variable="locator">
+ <choose>
+ <if locator="page" match="none">
+ <group delimiter=" ">
+ <choose>
+ <if type="bill book graphic legislation motion_picture report song" match="any">
+ <choose>
+ <if variable="volume">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text term="volume" form="short"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <label variable="locator" form="short"/>
+ </group>
+ </if>
+ <else>
+ <label variable="locator" form="short"/>
+ </else>
+ </choose>
+ </if>
+ <else>
+ <label variable="locator" form="short"/>
+ </else>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <group delimiter=":">
+ <number variable="volume" form="numeric"/>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else>
+ <text variable="locator"/>
+ </else>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="point-locators-join-with-colon">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="locator page" match="any">
+ <choose>
+ <if variable="volume issue" match="any">
+ <text macro="point-locators"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="point-locators-join-with-comma">
+ <choose>
+ <if type="article-journal" match="none">
+ <text macro="point-locators"/>
+ </if>
+ <else-if variable="volume issue" match="none">
+ <text macro="point-locators"/>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="point-locators">
+ <choose>
+ <if variable="locator" match="none">
+ <choose>
+ <if type="article-journal chapter paper-conference" match="any">
+ <text variable="page"/>
+ </if>
+ </choose>
+ </if>
+ <else-if type="article-journal">
+ <group delimiter=" ">
+ <choose>
+ <if locator="page" match="none">
+ <label variable="locator" form="short" suffix=" "/>
+ </if>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else-if type="legal_case"/>
+ <else>
+ <group delimiter=" ">
+ <choose>
+ <if locator="page" match="none">
+ <label variable="locator" form="short"/>
+ </if>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="locators-chapter">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <choose>
+ <if variable="author container-author" match="all"/>
+ <else>
+ <choose>
+ <if variable="page">
+ <number variable="volume" suffix=":"/>
+ <text variable="page"/>
+ </if>
+ </choose>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-journal-join-with-colon">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="any">
+ <text variable="page"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-journal-join-with-comma">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="none">
+ <text variable="page"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="archive-note">
+ <choose>
+ <if type="thesis">
+ <group delimiter=" ">
+ <text variable="archive"/>
+ <text variable="archive_location" prefix="(" suffix=")"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=", ">
+ <text variable="archive_location"/>
+ <text variable="archive"/>
+ <text variable="archive-place"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="archive">
+ <choose>
+ <if type="thesis">
+ <group delimiter=" ">
+ <text variable="archive"/>
+ <text variable="archive_location" prefix="(" suffix=")"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=". ">
+ <text variable="archive_location" text-case="capitalize-first"/>
+ <text variable="archive"/>
+ <text variable="archive-place"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue-note-join-with-space">
+ <choose>
+ <if type="article-journal legal_case manuscript thesis" variable="publisher-place publisher" match="any">
+ <!--Chicago doesn't use publisher/place for Newspapers and we want the date delimited by a comma-->
+ <choose>
+ <if type="article-newspaper" match="none">
+ <choose>
+ <if type="article-journal" match="none">
+ <text macro="issue-note"/>
+ </if>
+ <else-if variable="issue volume" match="any">
+ <text macro="issue-note"/>
+ </else-if>
+ </choose>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-note-join-with-comma">
+ <choose>
+ <if type="article-journal legal_case manuscript thesis" variable="publisher-place publisher" match="none">
+ <text macro="issue-note"/>
+ </if>
+ <else-if type="article-newspaper">
+ <text macro="issue-note"/>
+ </else-if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="none">
+ <text macro="issue-note"/>
+ </if>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="issue-note">
+ <choose>
+ <if type="legal_case" match="any">
+ <text macro="issued" prefix="(" suffix=")"/>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="any">
+ <text macro="issued" prefix="(" suffix=")"/>
+ </if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </else-if>
+ <else-if type="article-newspaper">
+ <text macro="issued"/>
+ </else-if>
+ <else-if variable="publisher-place event-place publisher genre" match="any">
+ <group prefix="(" suffix=")" delimiter=", ">
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="manuscript thesis speech" match="any">
+ <text variable="genre"/>
+ </else-if>
+ </choose>
+ <text macro="event-note"/>
+ <group delimiter="; ">
+ <text macro="originally-published"/>
+ <group delimiter=", ">
+ <text macro="reprint-note"/>
+ <text macro="publisher"/>
+ </group>
+ </group>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue-join-with-space">
+ <choose>
+ <if type="article-journal legal_case" match="any">
+ <choose>
+ <if variable="issue volume" match="any">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-join-with-period">
+ <choose>
+ <if type="article-journal legal_case" match="none">
+ <choose>
+ <if type="speech" variable="publisher publisher-place" match="any">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-join-with-comma">
+ <choose>
+ <if type="article-journal legal_case" match="none">
+ <choose>
+ <if type="speech" variable="publisher publisher-place" match="none">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </if>
+ <else-if variable="volume issue" match="none">
+ <text macro="issue"/>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="issue">
+ <choose>
+ <if type="legal_case" match="any">
+ <text macro="issued" prefix="(" suffix=")"/>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="issue volume" match="any">
+ <text macro="issued" prefix="(" suffix=")"/>
+ </if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </else-if>
+ <else-if type="speech">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <choose>
+ <if variable="title" match="none"/>
+ <else>
+ <text variable="genre" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ <text macro="event"/>
+ </group>
+ <text variable="event-place"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <!--Chicago doesn't use publisher/place for Newspapers -->
+ <else-if type="article-newspaper">
+ <text macro="issued"/>
+ </else-if>
+ <else-if variable="publisher-place publisher" match="any">
+ <group delimiter=", ">
+ <choose>
+ <if type="thesis">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ <group delimiter=". ">
+ <text macro="originally-published"/>
+ <group delimiter=", ">
+ <text macro="reprint"/>
+ <text macro="publisher"/>
+ </group>
+ </group>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="access-note">
+ <group delimiter=", ">
+ <choose>
+ <if type="graphic report" match="any">
+ <text macro="archive-note"/>
+ </if>
+ <else-if type="article-journal bill book chapter legal_case legislation motion_picture paper-conference" match="none">
+ <text macro="archive-note"/>
+ </else-if>
+ </choose>
+ <choose>
+ <if variable="issued" match="none">
+ <group delimiter=" ">
+ <text term="accessed"/>
+ <date variable="accessed" form="text"/>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else>
+ <text variable="URL"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="access">
+ <group delimiter=". ">
+ <choose>
+ <if type="graphic report" match="any">
+ <text macro="archive"/>
+ </if>
+ <else-if type="article-journal bill book chapter legal_case legislation motion_picture paper-conference" match="none">
+ <text macro="archive"/>
+ </else-if>
+ </choose>
+ <choose>
+ <if variable="issued" match="none">
+ <group delimiter=" ">
+ <text term="accessed" text-case="capitalize-first"/>
+ <date variable="accessed" form="text"/>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else>
+ <text variable="URL"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="case-locator-subsequent">
+ <choose>
+ <if type="legal_case">
+ <text macro="locators-note"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="case-issue-subsequent">
+ <choose>
+ <if type="legal_case">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="1" disambiguate-add-names="true">
+ <layout suffix="." delimiter="; ">
+ <choose>
+ <if position="ibid-with-locator">
+ <group delimiter=", ">
+ <text term="ibid"/>
+ <text macro="point-locators-subsequent"/>
+ </group>
+ </if>
+ <else-if position="ibid">
+ <text term="ibid"/>
+ </else-if>
+ <else>
+ <group delimiter=", ">
+ <text macro="contributors-short"/>
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <text macro="title-short"/>
+ <!--if title & author are the same: -->
+ <text macro="date-disambiguate"/>
+ <text macro="case-locator-subsequent"/>
+ </group>
+ <text macro="case-issue-subsequent"/>
+ </group>
+ <text macro="point-locators-subsequent"/>
+ </group>
+ </else>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography hanging-indent="true" et-al-min="11" et-al-use-first="7" subsequent-author-substitute="&#8212;&#8212;&#8212;" entry-spacing="0">
+ <sort>
+ <key macro="contributors-sort"/>
+ <key variable="title"/>
+ <key variable="genre"/>
+ <key variable="issued"/>
+ </sort>
+ <layout suffix=".">
+ <group delimiter=". ">
+ <group delimiter=": ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <group delimiter=". ">
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <group delimiter=". ">
+ <group delimiter=". ">
+ <text macro="contributors"/>
+ <text macro="title"/>
+ </group>
+ <text macro="description"/>
+ <text macro="secondary-contributors"/>
+ <group delimiter=", ">
+ <text macro="container-title"/>
+ <text macro="container-contributors"/>
+ </group>
+ <text macro="locators-join-with-period"/>
+ </group>
+ <text macro="locators-join-with-comma"/>
+ <text macro="locators-chapter"/>
+ </group>
+ <text macro="locators-join-with-space"/>
+ </group>
+ <text macro="collection-title"/>
+ <text macro="issue-join-with-period"/>
+ </group>
+ <text macro="issue-join-with-space"/>
+ </group>
+ <text macro="issue-join-with-comma"/>
+ <text macro="locators-journal-join-with-comma"/>
+ <text macro="locators-newspaper"/>
+ </group>
+ <text macro="locators-journal-join-with-colon"/>
+ </group>
+ <text macro="access"/>
+ </group>
+ <text variable="note" display="block"/>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/chicago-author-date-with-original-date-and-status.csl b/test/command/chicago-author-date-with-original-date-and-status.csl
new file mode 100644
index 000000000..ba80e654f
--- /dev/null
+++ b/test/command/chicago-author-date-with-original-date-and-status.csl
@@ -0,0 +1,575 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="never" page-range-format="chicago">
+ <info>
+ <title>Chicago Manual of Style 16th edition (author-date)</title>
+ <id>http://www.zotero.org/styles/chicago-author-date</id>
+ <link href="http://www.zotero.org/styles/chicago-author-date" rel="self"/>
+ <link href="http://www.chicagomanualofstyle.org/tools_citationguide.html" rel="documentation"/>
+ <author>
+ <name>Julian Onions</name>
+ <email>julian.onions@gmail.com</email>
+ </author>
+ <contributor>
+ <name>Sebastian Karcher</name>
+ </contributor>
+ <contributor>
+ <name>Richard Karnesky</name>
+ <email>karnesky+zotero@gmail.com</email>
+ <uri>http://arc.nucapt.northwestern.edu/Richard_Karnesky</uri>
+ </contributor>
+ <contributor>
+ <name>Andrew Dunning</name>
+ <email>andrew.dunning@utoronto.ca</email>
+ </contributor>
+ <category citation-format="author-date"/>
+ <category field="generic-base"/>
+ <summary>The author-date variant of the Chicago style</summary>
+ <updated>2014-05-23T03:53:32+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en">
+ <terms>
+ <term name="editor" form="verb-short">ed.</term>
+ <term name="container-author" form="verb">by</term>
+ <term name="translator" form="verb-short">trans.</term>
+ <term name="editortranslator" form="verb">
+ <single>edited and translated by</single>
+ <multiple>edited and translated by</multiple>
+ </term>
+ <term name="translator" form="short">trans.</term>
+ </terms>
+ </locale>
+ <macro name="secondary-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="none">
+ <names variable="editor translator" delimiter=". ">
+ <label form="verb" text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <group prefix=", " delimiter=", ">
+ <names variable="container-author" delimiter=", ">
+ <label form="verb" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="translator">
+ <names variable="translator">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="recipient">
+ <choose>
+ <if type="personal_communication">
+ <choose>
+ <if variable="genre">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ <else>
+ <text term="letter" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ <names variable="recipient" delimiter=", ">
+ <label form="verb" prefix=" " text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="contributors">
+ <group delimiter=". ">
+ <names variable="author">
+ <name and="text" name-as-sort-order="first" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ <text macro="recipient"/>
+ </group>
+ </macro>
+ <macro name="contributors-short">
+ <names variable="author">
+ <name form="short" and="text" delimiter=", " initialize-with=". "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="interviewer">
+ <names variable="interviewer" delimiter=", ">
+ <label form="verb" prefix=" " text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="archive">
+ <group delimiter=". ">
+ <text variable="archive_location" text-case="capitalize-first"/>
+ <text variable="archive"/>
+ <text variable="archive-place"/>
+ </group>
+ </macro>
+ <macro name="access">
+ <group delimiter=". ">
+ <choose>
+ <if type="graphic report" match="any">
+ <text macro="archive"/>
+ </if>
+ <else-if type="article-journal bill book chapter legal_case legislation motion_picture paper-conference" match="none">
+ <text macro="archive"/>
+ </else-if>
+ </choose>
+ <choose>
+ <if variable="issued" match="none">
+ <group delimiter=" ">
+ <text term="accessed" text-case="capitalize-first"/>
+ <date variable="accessed" delimiter=" ">
+ <date-part name="month"/>
+ <date-part name="day"/>
+ </date>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else>
+ <text variable="URL"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if variable="title" match="none">
+ <choose>
+ <if type="personal_communication" match="none">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" font-style="italic"/>
+ <group prefix=" (" suffix=")" delimiter=" ">
+ <text term="version"/>
+ <text variable="version"/>
+ </group>
+ </else-if>
+ <else-if variable="reviewed-author">
+ <group delimiter=", ">
+ <text variable="title" font-style="italic" prefix="Review of "/>
+ <names variable="reviewed-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </else-if>
+ <else-if type="legal_case interview" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" " prefix=". ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short" strip-periods="true"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" prefix=". "/>
+ </else>
+ </choose>
+ </if>
+ <else-if type="chapter paper-conference" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" " prefix=", ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" prefix=", "/>
+ </else>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="volume">
+ <text variable="volume" prefix=" "/>
+ <group prefix=" (" suffix=")">
+ <choose>
+ <if variable="issue">
+ <text variable="issue"/>
+ </if>
+ <else>
+ <date variable="issued">
+ <date-part name="month"/>
+ </date>
+ </else>
+ </choose>
+ </group>
+ </if>
+ <else-if variable="issue">
+ <group delimiter=" " prefix=", ">
+ <text term="issue" form="short"/>
+ <text variable="issue"/>
+ <date variable="issued" prefix="(" suffix=")">
+ <date-part name="month"/>
+ </date>
+ </group>
+ </else-if>
+ <else>
+ <date variable="issued" prefix=", ">
+ <date-part name="month"/>
+ </date>
+ </else>
+ </choose>
+ </if>
+ <else-if type="legal_case">
+ <text variable="volume" prefix=", "/>
+ <text variable="container-title" prefix=" "/>
+ <text variable="page" prefix=" "/>
+ </else-if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <group prefix=". " delimiter=". ">
+ <group>
+ <text term="volume" form="short" text-case="capitalize-first" suffix=" "/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <group>
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" prefix=" " plural="true"/>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="chapter paper-conference" match="any">
+ <choose>
+ <if variable="page" match="none">
+ <group prefix=". ">
+ <text term="volume" form="short" text-case="capitalize-first" suffix=" "/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ </if>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-chapter">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <choose>
+ <if variable="page">
+ <group prefix=", ">
+ <text variable="volume" suffix=":"/>
+ <text variable="page"/>
+ </group>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-article">
+ <choose>
+ <if type="article-newspaper">
+ <group prefix=", " delimiter=", ">
+ <group>
+ <text variable="edition" suffix=" "/>
+ <text term="edition" prefix=" "/>
+ </group>
+ <group>
+ <text term="section" form="short" suffix=" "/>
+ <text variable="section"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="any">
+ <text variable="page" prefix=": "/>
+ </if>
+ <else>
+ <text variable="page" prefix=", "/>
+ </else>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="point-locators">
+ <choose>
+ <if variable="locator">
+ <choose>
+ <if locator="page" match="none">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <choose>
+ <if variable="volume">
+ <group>
+ <text term="volume" form="short" suffix=" "/>
+ <number variable="volume" form="numeric"/>
+ <label variable="locator" form="short" prefix=", " suffix=" "/>
+ </group>
+ </if>
+ <else>
+ <label variable="locator" form="short" suffix=" "/>
+ </else>
+ </choose>
+ </if>
+ <else>
+ <label variable="locator" form="short" suffix=" "/>
+ </else>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <number variable="volume" form="numeric" suffix=":"/>
+ </else-if>
+ </choose>
+ <text variable="locator"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-prefix">
+ <text term="in" text-case="capitalize-first"/>
+ </macro>
+ <macro name="container-title">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text macro="container-prefix" suffix=" "/>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <text variable="container-title" text-case="title" font-style="italic"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </macro>
+ <macro name="date-citation">
+ <choose>
+ <if variable="original-date">
+ <date variable="original-date" prefix="[" suffix="]">
+ <date-part name="year"/>
+ </date>
+ </if>
+ </choose>
+ <choose>
+ <if variable="issued">
+ <date variable="issued" prefix=" ">
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else-if variable="status">
+ <text variable="status" prefix=", "/>
+ </else-if>
+ <else-if variable="accessed">
+ <date variable="accessed" prefix=" ">
+ <date-part name="year"/>
+ </date>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="date-bibliography">
+ <choose>
+ <if variable="original-date">
+ <date variable="original-date" prefix=" (" suffix=") ">
+ <date-part name="year"/>
+ </date>
+ </if>
+ </choose>
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else-if variable="status">
+ <text variable="status" text-case="capitalize-first"/>
+ </else-if>
+ <else-if variable="accessed">
+ <date variable="accessed">
+ <date-part name="year"/>
+ </date>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="day-month">
+ <date variable="issued">
+ <date-part name="month"/>
+ <date-part name="day" prefix=" "/>
+ </date>
+ </macro>
+ <macro name="collection-title">
+ <choose>
+ <if match="none" type="article-journal">
+ <choose>
+ <if match="none" is-numeric="collection-number">
+ <group delimiter=", ">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=" ">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number"/>
+ </group>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="collection-title-journal">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=" ">
+ <text variable="collection-title"/>
+ <text variable="collection-number"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="event">
+ <group>
+ <text term="presented at" suffix=" "/>
+ <text variable="event"/>
+ </group>
+ </macro>
+ <macro name="description">
+ <choose>
+ <if type="interview">
+ <group delimiter=". ">
+ <text macro="interviewer"/>
+ <text variable="medium" text-case="capitalize-first"/>
+ </group>
+ </if>
+ <else>
+ <text variable="medium" text-case="capitalize-first" prefix=". "/>
+ </else>
+ </choose>
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis personal_communication speech" match="any"/>
+ <else>
+ <group delimiter=" " prefix=". ">
+ <text variable="genre" text-case="capitalize-first"/>
+ <choose>
+ <if type="report">
+ <text variable="number"/>
+ </if>
+ </choose>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue">
+ <choose>
+ <if type="legal_case">
+ <text variable="authority" prefix=". "/>
+ </if>
+ <else-if type="speech">
+ <group prefix=". " delimiter=", ">
+ <group delimiter=" ">
+ <text variable="genre" text-case="capitalize-first"/>
+ <text macro="event"/>
+ </group>
+ <text variable="event-place"/>
+ <text macro="day-month"/>
+ </group>
+ </else-if>
+ <else-if type="article-newspaper article-magazine personal_communication" match="any">
+ <text macro="day-month" prefix=", "/>
+ </else-if>
+ <else>
+ <group prefix=". " delimiter=", ">
+ <choose>
+ <if type="thesis">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ <text macro="publisher"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="1" disambiguate-add-year-suffix="true" disambiguate-add-names="true" disambiguate-add-givenname="true" givenname-disambiguation-rule="primary-name">
+ <layout prefix="(" suffix=")" delimiter="; ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text macro="contributors-short"/>
+ <text macro="date-citation"/>
+ </group>
+ <text macro="point-locators"/>
+ </group>
+ </layout>
+ </citation>
+ <bibliography hanging-indent="true" et-al-min="11" et-al-use-first="7" subsequent-author-substitute="&#8212;&#8212;&#8212;" entry-spacing="0">
+ <sort>
+ <key macro="contributors"/>
+ <key variable="original-date"/>
+ <key variable="issued"/>
+ </sort>
+ <layout suffix=".">
+ <group delimiter=". ">
+ <text macro="contributors"/>
+ <text macro="date-bibliography" text-case="capitalize-first"/>
+ <text macro="title"/>
+ </group>
+ <text macro="description"/>
+ <text macro="secondary-contributors" prefix=". "/>
+ <text macro="container-title" prefix=". "/>
+ <text macro="container-contributors"/>
+ <text macro="edition"/>
+ <text macro="locators-chapter"/>
+ <text macro="collection-title-journal" prefix=", " suffix=", "/>
+ <text macro="locators"/>
+ <text macro="collection-title" prefix=". "/>
+ <text macro="issue"/>
+ <text macro="locators-article"/>
+ <text macro="access" prefix=". "/>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/chicago-fullnote-bibliography.csl b/test/command/chicago-fullnote-bibliography.csl
new file mode 100644
index 000000000..5bcfe59b3
--- /dev/null
+++ b/test/command/chicago-fullnote-bibliography.csl
@@ -0,0 +1,1182 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" version="1.0" demote-non-dropping-particle="never" page-range-format="chicago">
+ <info>
+ <title>Chicago Manual of Style 16th edition (full note)</title>
+ <id>http://www.zotero.org/styles/chicago-fullnote-bibliography</id>
+ <link href="http://www.zotero.org/styles/chicago-fullnote-bibliography" rel="self"/>
+ <link href="http://www.chicagomanualofstyle.org/tools_citationguide.html" rel="documentation"/>
+ <author>
+ <name>Julian Onions</name>
+ <email>julian.onions@gmail.com</email>
+ </author>
+ <contributor>
+ <name>Simon Kornblith</name>
+ <email>simon@simonster.com</email>
+ </contributor>
+ <contributor>
+ <name>Elena Razlogova</name>
+ <email>elena.razlogova@gmail.com</email>
+ </contributor>
+ <contributor>
+ <name>Frank Bennett</name>
+ <email>biercenator@gmail.com</email>
+ </contributor>
+ <contributor>
+ <name>Andrew Dunning</name>
+ <email>andrew.dunning@utoronto.ca</email>
+ </contributor>
+ <category citation-format="note"/>
+ <category field="generic-base"/>
+ <summary>Chicago format with full notes and bibliography</summary>
+ <updated>2014-05-15T18:02:53+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en">
+ <terms>
+ <term name="editor" form="verb-short">ed.</term>
+ <term name="translator" form="verb-short">trans.</term>
+ <term name="editortranslator" form="verb-short">
+ <single>ed. and trans.</single>
+ <multiple>ed. and trans.</multiple>
+ </term>
+ <term name="editortranslator" form="verb">
+ <single>Edited and translated by</single>
+ <multiple>Edited and translated by</multiple>
+ </term>
+ <term name="translator" form="short">trans.</term>
+ </terms>
+ </locale>
+ <macro name="editor-translator">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <choose>
+ <if variable="container-author reviewed-author" match="any">
+ <group>
+ <names variable="container-author reviewed-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </if>
+ </choose>
+ </group>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </macro>
+ <macro name="secondary-contributors-note">
+ <choose>
+ <if type="chapter paper-conference" match="none">
+ <text macro="editor-translator"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-contributors-note">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text macro="editor-translator"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="secondary-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="none">
+ <names variable="editor translator" delimiter=". ">
+ <label form="verb" text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <group delimiter=", ">
+ <choose>
+ <if variable="author">
+ <choose>
+ <if variable="container-author" match="any">
+ <names variable="container-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ <!--This includes page numers after the container author, e.g. for Introductions -->
+ <choose>
+ <if variable="container-author author" match="all">
+ <group delimiter=". ">
+ <text variable="page"/>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </if>
+ <else>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="recipient-note">
+ <names variable="recipient" delimiter=", ">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="contributors-note">
+ <group delimiter=" ">
+ <names variable="author">
+ <name and="text" sort-separator=", " delimiter=", "/>
+ <label form="short" prefix=", "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ </substitute>
+ </names>
+ <text macro="recipient-note"/>
+ </group>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="translator">
+ <names variable="translator">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="verb-short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="recipient">
+ <group delimiter=" ">
+ <choose>
+ <if type="personal_communication">
+ <choose>
+ <if variable="genre">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ <else>
+ <text term="letter" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ <text macro="recipient-note"/>
+ </group>
+ </macro>
+ <macro name="contributors">
+ <group delimiter=". ">
+ <names variable="author">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <substitute>
+ <text macro="editor"/>
+ <text macro="translator"/>
+ </substitute>
+ </names>
+ <text macro="recipient"/>
+ </group>
+ </macro>
+ <macro name="recipient-short">
+ <names variable="recipient">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name form="short" and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="contributors-short">
+ <group delimiter=" ">
+ <names variable="author">
+ <name form="short" and="text" delimiter=", "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ </substitute>
+ </names>
+ <text macro="recipient-short"/>
+ </group>
+ </macro>
+ <macro name="contributors-sort">
+ <names variable="author">
+ <name name-as-sort-order="all" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="interviewer-note">
+ <names variable="interviewer" delimiter=", ">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="interviewer">
+ <names variable="interviewer" delimiter=", ">
+ <label form="verb" text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="title-note">
+ <choose>
+ <if variable="title" match="none">
+ <text variable="genre"/>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" font-style="italic"/>
+ <group delimiter=" " prefix=", ">
+ <text term="version"/>
+ <text variable="version"/>
+ </group>
+ </else-if>
+ <else-if type="legal_case interview" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else-if variable="reviewed-author">
+ <text variable="title" font-style="italic" prefix="review of "/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if variable="title" match="none">
+ <choose>
+ <if type="personal_communication" match="none">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" font-style="italic"/>
+ <group prefix=" (" suffix=")" delimiter=" ">
+ <text term="version"/>
+ <text variable="version"/>
+ </group>
+ </else-if>
+ <else-if variable="reviewed-author">
+ <group delimiter=", ">
+ <text variable="title" font-style="italic" prefix="Review of "/>
+ <names variable="reviewed-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </else-if>
+ <else-if type="legal_case interview" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title-short">
+ <choose>
+ <if variable="title" match="none">
+ <choose>
+ <if type="interview">
+ <text term="interview"/>
+ </if>
+ <else-if type="manuscript speech" match="any">
+ <text variable="genre" form="short"/>
+ </else-if>
+ <else-if type="personal_communication">
+ <text macro="issued"/>
+ </else-if>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" form="short" font-style="italic"/>
+ </else-if>
+ <else-if type="legal_case interview" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" form="short" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="date-disambiguate">
+ <choose>
+ <if disambiguate="true">
+ <text macro="issued"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="description-note">
+ <group delimiter=", ">
+ <text macro="interviewer-note"/>
+ <text variable="medium"/>
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis speech" match="any"/>
+ <else>
+ <text variable="genre"/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <macro name="description">
+ <group delimiter=", ">
+ <group delimiter=". ">
+ <text macro="interviewer"/>
+ <text variable="medium" text-case="capitalize-first"/>
+ </group>
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis speech" match="any"/>
+ <else>
+ <text variable="genre" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <macro name="container-title-note">
+ <group delimiter=" ">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text term="in"/>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <text variable="container-title" text-case="title" font-style="italic"/>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="container-title">
+ <group delimiter=" ">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text term="in" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <text variable="container-title" text-case="title" font-style="italic"/>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="collection-title">
+ <choose>
+ <if match="none" type="article-journal">
+ <choose>
+ <if match="none" is-numeric="collection-number">
+ <group delimiter=", ">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=" ">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number"/>
+ </group>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="collection-title-journal">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=" ">
+ <text variable="collection-title"/>
+ <text variable="collection-number"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="edition-note">
+ <choose>
+ <if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" text-case="capitalize-first" suffix="."/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-note-join-with-space">
+ <choose>
+ <if type="article-journal" variable="volume" match="all">
+ <choose>
+ <if match="none" variable="collection-title">
+ <text macro="locators-note"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-note-join-with-comma">
+ <choose>
+ <if type="article-journal" match="none">
+ <text macro="locators-note"/>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume" match="none">
+ <text macro="locators-note"/>
+ </if>
+ <else-if match="any" variable="collection-title">
+ <text macro="locators-note"/>
+ </else-if>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-note">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=", ">
+ <text macro="collection-title-journal"/>
+ <number variable="volume"/>
+ <group delimiter=" ">
+ <text term="issue" form="short"/>
+ <number variable="issue"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="legal_case">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <number variable="volume"/>
+ <text variable="container-title"/>
+ <text variable="page"/>
+ </group>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else-if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <group delimiter=", ">
+ <text macro="edition-note"/>
+ <group delimiter=" ">
+ <text term="volume" form="short"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <choose>
+ <if variable="locator" match="none">
+ <group delimiter=" ">
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" plural="true"/>
+ </group>
+ </if>
+ </choose>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-join-with-space">
+ <choose>
+ <if type="article-journal" variable="volume" match="all">
+ <choose>
+ <if match="none" variable="collection-title">
+ <text macro="locators"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-join-with-comma">
+ <choose>
+ <if type="legal_case chapter paper-conference" match="any">
+ <text macro="locators"/>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume" match="none">
+ <text macro="locators"/>
+ </if>
+ <else-if match="any" variable="collection-title">
+ <text macro="locators"/>
+ </else-if>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-join-with-period">
+ <choose>
+ <if type="legal_case article-journal chapter paper-conference" match="none">
+ <text macro="locators"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=", ">
+ <text macro="collection-title-journal"/>
+ <number variable="volume"/>
+ <group delimiter=" ">
+ <text term="issue" form="short"/>
+ <number variable="issue"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="legal_case">
+ <group delimiter=" ">
+ <number variable="volume"/>
+ <text variable="container-title"/>
+ <text variable="page"/>
+ </group>
+ </else-if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <group delimiter=". ">
+ <text macro="edition"/>
+ <group delimiter=" ">
+ <text term="volume" form="short" text-case="capitalize-first"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <group delimiter=" ">
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" plural="true"/>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="chapter paper-conference" match="any">
+ <group delimiter=". ">
+ <text macro="edition"/>
+ <choose>
+ <if variable="page" match="none">
+ <group delimiter=" ">
+ <text term="volume" form="short" text-case="capitalize-first"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ </if>
+ </choose>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-newspaper">
+ <choose>
+ <if type="article-newspaper">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <number variable="edition"/>
+ <text term="edition"/>
+ </group>
+ <group delimiter=" ">
+ <text term="section" form="short"/>
+ <text variable="section"/>
+ </group>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="event">
+ <group delimiter=" ">
+ <text term="presented at"/>
+ <text variable="event"/>
+ </group>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if type="thesis">
+ <text variable="publisher"/>
+ </if>
+ <else-if type="speech">
+ <text variable="event-place"/>
+ </else-if>
+ <else>
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issued">
+ <choose>
+ <if variable="issued">
+ <choose>
+ <if type="graphic report" match="any">
+ <date variable="issued" form="text"/>
+ </if>
+ <else-if type="legal_case">
+ <group delimiter=" ">
+ <text variable="authority"/>
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </group>
+ </else-if>
+ <else-if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song thesis" match="any">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </else-if>
+ <else>
+ <date variable="issued" form="text"/>
+ </else>
+ </choose>
+ </if>
+ <else-if variable="accessed URL" match="all"/>
+ <else>
+ <text term="no date" form="short"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="point-locators-subsequent">
+ <choose>
+ <if variable="locator">
+ <choose>
+ <if locator="page" match="none">
+ <group delimiter=" ">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <choose>
+ <if variable="volume">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text term="volume" form="short"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <label variable="locator" form="short"/>
+ </group>
+ </if>
+ <else>
+ <label variable="locator" form="short"/>
+ </else>
+ </choose>
+ </if>
+ <else>
+ <label variable="locator" form="short"/>
+ </else>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <group delimiter=":">
+ <number variable="volume" form="numeric"/>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else>
+ <text variable="locator"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="point-locators-join-with-colon">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="locator page" match="any">
+ <choose>
+ <if variable="volume issue" match="any">
+ <text macro="point-locators"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="point-locators-join-with-comma">
+ <choose>
+ <if type="article-journal" match="none">
+ <text macro="point-locators"/>
+ </if>
+ <else-if variable="volume issue" match="none">
+ <text macro="point-locators"/>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="point-locators">
+ <choose>
+ <if variable="locator" match="none">
+ <choose>
+ <if type="article-journal chapter paper-conference" match="any">
+ <text variable="page"/>
+ </if>
+ </choose>
+ </if>
+ <else-if type="article-journal">
+ <group delimiter=" ">
+ <choose>
+ <if locator="page" match="none">
+ <label variable="locator" form="short" suffix=" "/>
+ </if>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else-if type="legal_case"/>
+ <else>
+ <group delimiter=" ">
+ <choose>
+ <if locator="page" match="none">
+ <label variable="locator" form="short"/>
+ </if>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="locators-chapter">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <choose>
+ <if variable="author container-author" match="all"/>
+ <else>
+ <choose>
+ <if variable="page">
+ <number variable="volume" suffix=":"/>
+ <text variable="page"/>
+ </if>
+ </choose>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-journal-join-with-colon">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="any">
+ <text variable="page"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-journal-join-with-comma">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="none">
+ <text variable="page"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="archive-note">
+ <choose>
+ <if type="thesis">
+ <group delimiter=" ">
+ <text variable="archive"/>
+ <text variable="archive_location" prefix="(" suffix=")"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=", ">
+ <text variable="archive_location"/>
+ <text variable="archive"/>
+ <text variable="archive-place"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="archive">
+ <choose>
+ <if type="thesis">
+ <group delimiter=" ">
+ <text variable="archive"/>
+ <text variable="archive_location" prefix="(" suffix=")"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=". ">
+ <text variable="archive_location" text-case="capitalize-first"/>
+ <text variable="archive"/>
+ <text variable="archive-place"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue-note-join-with-space">
+ <choose>
+ <if type="article-journal legal_case" variable="publisher-place publisher" match="any">
+ <!--Chicago doesn't use publisher/place for Newspapers and we want the date delimited by a comma-->
+ <choose>
+ <if type="article-newspaper" match="none">
+ <choose>
+ <if type="article-journal" match="none">
+ <text macro="issue-note"/>
+ </if>
+ <else-if variable="issue volume" match="any">
+ <text macro="issue-note"/>
+ </else-if>
+ </choose>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-note-join-with-comma">
+ <choose>
+ <if type="article-journal legal_case" variable="publisher-place publisher" match="none">
+ <text macro="issue-note"/>
+ </if>
+ <else-if type="article-newspaper">
+ <text macro="issue-note"/>
+ </else-if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="none">
+ <text macro="issue-note"/>
+ </if>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="issue-note">
+ <choose>
+ <if type="legal_case" match="any">
+ <text macro="issued" prefix="(" suffix=")"/>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="any">
+ <text macro="issued" prefix="(" suffix=")"/>
+ </if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </else-if>
+ <else-if type="article-newspaper">
+ <text macro="issued"/>
+ </else-if>
+ <else-if variable="publisher-place event-place publisher genre" match="any">
+ <group prefix="(" suffix=")" delimiter=", ">
+ <group delimiter=" ">
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis speech" match="any">
+ <text variable="genre"/>
+ </else-if>
+ </choose>
+ <text macro="event"/>
+ </group>
+ <text macro="publisher"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue-join-with-space">
+ <choose>
+ <if type="article-journal legal_case" match="any">
+ <choose>
+ <if variable="issue volume" match="any">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-join-with-period">
+ <choose>
+ <if type="article-journal legal_case" match="none">
+ <choose>
+ <if type="speech" variable="publisher publisher-place" match="any">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-join-with-comma">
+ <choose>
+ <if type="article-journal legal_case" match="none">
+ <choose>
+ <if type="speech" variable="publisher publisher-place" match="none">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </if>
+ <else-if variable="volume issue" match="none">
+ <text macro="issue"/>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="issue">
+ <choose>
+ <if type="legal_case" match="any">
+ <text macro="issued" prefix="(" suffix=")"/>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="issue volume" match="any">
+ <text macro="issued" prefix="(" suffix=")"/>
+ </if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </else-if>
+ <else-if type="speech">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <choose>
+ <if variable="title" match="none"/>
+ <else>
+ <text variable="genre" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ <text macro="event"/>
+ </group>
+ <text variable="event-place"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <!--Chicago doesn't use publisher/place for Newspapers -->
+ <else-if type="article-newspaper">
+ <text macro="issued"/>
+ </else-if>
+ <else-if variable="publisher-place publisher" match="any">
+ <group delimiter=", ">
+ <choose>
+ <if type="thesis">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ <text macro="publisher"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="access-note">
+ <group delimiter=", ">
+ <choose>
+ <if type="graphic report" match="any">
+ <text macro="archive-note"/>
+ </if>
+ <else-if type="article-journal bill book chapter legal_case legislation motion_picture paper-conference" match="none">
+ <text macro="archive-note"/>
+ </else-if>
+ </choose>
+ <choose>
+ <if variable="issued" match="none">
+ <group delimiter=" ">
+ <text term="accessed"/>
+ <date variable="accessed" form="text"/>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else>
+ <text variable="URL"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="access">
+ <group delimiter=". ">
+ <choose>
+ <if type="graphic report" match="any">
+ <text macro="archive"/>
+ </if>
+ <else-if type="article-journal bill book chapter legal_case legislation motion_picture paper-conference" match="none">
+ <text macro="archive"/>
+ </else-if>
+ </choose>
+ <choose>
+ <if variable="issued" match="none">
+ <group delimiter=" ">
+ <text term="accessed" text-case="capitalize-first"/>
+ <date variable="accessed" form="text"/>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else>
+ <text variable="URL"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="case-locator-subsequent">
+ <choose>
+ <if type="legal_case">
+ <text macro="locators-note"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="case-issue-subsequent">
+ <choose>
+ <if type="legal_case">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="1" disambiguate-add-names="true">
+ <layout suffix="." delimiter="; ">
+ <choose>
+ <if position="ibid-with-locator">
+ <group delimiter=", ">
+ <text term="ibid"/>
+ <text macro="point-locators-subsequent"/>
+ </group>
+ </if>
+ <else-if position="ibid">
+ <text term="ibid"/>
+ </else-if>
+ <else-if position="subsequent">
+ <group delimiter=", ">
+ <text macro="contributors-short"/>
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <text macro="title-short"/>
+ <!--if title & author are the same: -->
+ <text macro="date-disambiguate"/>
+ <text macro="case-locator-subsequent"/>
+ </group>
+ <text macro="case-issue-subsequent"/>
+ </group>
+ <text macro="point-locators-subsequent"/>
+ </group>
+ </else-if>
+ <else>
+ <group delimiter=", ">
+ <group delimiter=": ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <group delimiter=", ">
+ <text macro="contributors-note"/>
+ <text macro="title-note"/>
+ </group>
+ <text macro="description-note"/>
+ <text macro="secondary-contributors-note"/>
+ <text macro="container-title-note"/>
+ <text macro="container-contributors-note"/>
+ </group>
+ <text macro="locators-note-join-with-space"/>
+ </group>
+ <text macro="locators-note-join-with-comma"/>
+ <text macro="collection-title"/>
+ <text macro="issue-note-join-with-comma"/>
+ </group>
+ <text macro="issue-note-join-with-space"/>
+ </group>
+ <text macro="locators-newspaper"/>
+ <text macro="point-locators-join-with-comma"/>
+ </group>
+ <text macro="point-locators-join-with-colon"/>
+ </group>
+ <text macro="access-note"/>
+ </group>
+ </else>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography hanging-indent="true" et-al-min="11" et-al-use-first="7" subsequent-author-substitute="&#8212;&#8212;&#8212;" entry-spacing="0">
+ <sort>
+ <key macro="contributors-sort"/>
+ <key variable="title"/>
+ <key variable="genre"/>
+ <key variable="issued"/>
+ </sort>
+ <layout suffix=".">
+ <group delimiter=". ">
+ <group delimiter=": ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <group delimiter=". ">
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <group delimiter=". ">
+ <group delimiter=". ">
+ <text macro="contributors"/>
+ <text macro="title"/>
+ </group>
+ <text macro="description"/>
+ <text macro="secondary-contributors"/>
+ <group delimiter=", ">
+ <text macro="container-title"/>
+ <text macro="container-contributors"/>
+ </group>
+ <text macro="locators-join-with-period"/>
+ </group>
+ <text macro="locators-join-with-comma"/>
+ <text macro="locators-chapter"/>
+ </group>
+ <text macro="locators-join-with-space"/>
+ </group>
+ <text macro="collection-title"/>
+ <text macro="issue-join-with-period"/>
+ </group>
+ <text macro="issue-join-with-space"/>
+ </group>
+ <text macro="issue-join-with-comma"/>
+ <text macro="locators-journal-join-with-comma"/>
+ <text macro="locators-newspaper"/>
+ </group>
+ <text macro="locators-journal-join-with-colon"/>
+ </group>
+ <text macro="access"/>
+ </group>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/chicago-note-bibliography.csl b/test/command/chicago-note-bibliography.csl
new file mode 100644
index 000000000..faf70949f
--- /dev/null
+++ b/test/command/chicago-note-bibliography.csl
@@ -0,0 +1,1005 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" version="1.0" demote-non-dropping-particle="sort-only">
+ <info>
+ <title>Chicago Manual of Style (note)</title>
+ <id>http://www.zotero.org/styles/chicago-note-bibliography</id>
+ <link href="http://www.zotero.org/styles/chicago-note-bibliography" rel="self"/>
+ <link href="http://www.chicagomanualofstyle.org/tools_citationguide.html" rel="documentation"/>
+ <author>
+ <name>Julian Onions</name>
+ <email>julian.onions@gmail.com</email>
+ </author>
+ <contributor>
+ <name>Simon Kornblith</name>
+ <email>simon@simonster.com</email>
+ </contributor>
+ <contributor>
+ <name>Elena Razlogova</name>
+ <email>elena.razlogova@gmail.com</email>
+ </contributor>
+ <contributor>
+ <name>Frank Bennett</name>
+ <email>biercenator@gmail.com</email>
+ </contributor>
+ <category citation-format="note"/>
+ <category field="generic-base"/>
+ <summary>Chicago format with short notes and bibliography</summary>
+ <updated>2012-10-25T21:15:26+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en">
+ <terms>
+ <term name="editortranslator" form="verb-short">
+ <single>trans. and ed.</single>
+ <multiple>trans. and ed.</multiple>
+ </term>
+ <term name="editortranslator" form="verb">
+ <single> Translated and edited by</single>
+ <multiple> Translated and edited by</multiple>
+ </term>
+ <term name="editor" form="verb-short">ed.</term>
+ <term name="translator" form="verb-short">trans.</term>
+ </terms>
+ </locale>
+ <macro name="editor-translator">
+ <group delimiter=", ">
+ <choose>
+ <if variable="author">
+ <group delimiter=" ">
+ <choose>
+ <if variable="container-author">
+ <group>
+ <names variable="container-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </if>
+ </choose>
+ </group>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="secondary-contributors-note">
+ <choose>
+ <if type="chapter paper-conference" match="none">
+ <text macro="editor-translator"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-contributors-note">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text macro="editor-translator"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="secondary-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="none">
+ <group delimiter=". ">
+ <choose>
+ <if variable="author">
+ <names variable="editor translator" delimiter=". ">
+ <label form="verb" text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <group delimiter=", ">
+ <choose>
+ <if variable="author">
+ <choose>
+ <if variable="container-author">
+ <names variable="container-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ <!--This includes page numers after the container author, e.g. for Introductions -->
+ <choose>
+ <if variable="container-author author" match="all">
+ <group delimiter=". ">
+ <text variable="page"/>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </if>
+ <else>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="recipient-note">
+ <names variable="recipient" delimiter=", ">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="contributors-note">
+ <group delimiter=" ">
+ <names variable="author">
+ <name and="text" sort-separator=", " delimiter=", "/>
+ <label form="short" prefix=", "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ </substitute>
+ </names>
+ <text macro="recipient-note"/>
+ </group>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="translator">
+ <names variable="translator">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="verb-short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="recipient">
+ <group delimiter=" ">
+ <choose>
+ <if type="personal_communication">
+ <choose>
+ <if variable="genre">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ <else>
+ <text term="letter" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ <text macro="recipient-note"/>
+ </group>
+ </macro>
+ <macro name="contributors">
+ <group delimiter=". ">
+ <names variable="author">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <substitute>
+ <text macro="editor"/>
+ <text macro="translator"/>
+ </substitute>
+ </names>
+ <text macro="recipient"/>
+ </group>
+ </macro>
+ <macro name="recipient-short">
+ <names variable="recipient">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name form="short" and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="contributors-short">
+ <group delimiter=" ">
+ <names variable="author">
+ <name form="short" and="text" delimiter=", "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ </substitute>
+ </names>
+ <text macro="recipient-short"/>
+ </group>
+ </macro>
+ <macro name="contributors-sort">
+ <names variable="author">
+ <name name-as-sort-order="all" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="interviewer-note">
+ <names variable="interviewer" delimiter=", ">
+ <label form="verb" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="interviewer">
+ <names variable="interviewer" delimiter=", ">
+ <label form="verb" text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="title-note">
+ <choose>
+ <if variable="title" match="none">
+ <text variable="genre"/>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" font-style="italic"/>
+ <text variable="version" prefix=" , version " suffix=""/>
+ <!--This isn't localized because we don't have a version term. While not ideal, it should work for many languages and is better than not including a term.-->
+ </else-if>
+ <else-if type="legal_case">
+ <text variable="title"/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if variable="title" match="none">
+ <choose>
+ <if type="personal_communication" match="none">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" font-style="italic"/>
+ <text variable="version" prefix=" (version " suffix=")"/>
+ </else-if>
+ <else-if type="legal_case">
+ <text variable="title"/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title-short">
+ <choose>
+ <if variable="title" match="none">
+ <choose>
+ <if type="interview">
+ <text term="interview" text-case="lowercase"/>
+ </if>
+ <else-if type="manuscript speech" match="any">
+ <text variable="genre" form="short"/>
+ </else-if>
+ <else-if type="personal_communication">
+ <text macro="issued"/>
+ </else-if>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" form="short" font-style="italic"/>
+ </else-if>
+ <else-if type="legal_case">
+ <text variable="title"/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" form="short" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="description-note">
+ <group delimiter=", ">
+ <text macro="interviewer-note"/>
+ <text variable="medium"/>
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis speech" match="any"/>
+ <else>
+ <text variable="genre"/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <macro name="description">
+ <group delimiter=", ">
+ <group delimiter=". ">
+ <text macro="interviewer"/>
+ <text variable="medium" text-case="capitalize-first"/>
+ </group>
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis speech" match="any"/>
+ <else>
+ <text variable="genre" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <macro name="container-title-note">
+ <group delimiter=" ">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text term="in" text-case="lowercase"/>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <text variable="container-title" text-case="title" font-style="italic"/>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="container-title">
+ <group delimiter=" ">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text term="in" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <text variable="container-title" text-case="title" font-style="italic"/>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="collection-title">
+ <group delimiter=" ">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number"/>
+ </group>
+ </macro>
+ <macro name="edition-note">
+ <choose>
+ <if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <number variable="edition" suffix="."/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <number variable="edition" text-case="capitalize-first" suffix="."/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-note-join-with-space">
+ <choose>
+ <if type="article-journal">
+ <text macro="locators-note"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-note-join-with-comma">
+ <choose>
+ <if type="article-journal" match="none">
+ <text macro="locators-note"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-note">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=", ">
+ <number variable="volume"/>
+ <group delimiter=" ">
+ <text term="issue" form="short"/>
+ <number variable="issue"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="legal_case">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <number variable="volume"/>
+ <text variable="container-title"/>
+ <text variable="page"/>
+ </group>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else-if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text term="volume" form="short"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <choose>
+ <if variable="locator" match="none">
+ <group delimiter=" ">
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" plural="true"/>
+ </group>
+ </if>
+ </choose>
+ <text macro="edition-note"/>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-join-with-space">
+ <choose>
+ <if type="article-journal">
+ <text macro="locators"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-join-with-comma">
+ <choose>
+ <if type="legal_case">
+ <text macro="locators"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-join-with-period">
+ <choose>
+ <if type="legal_case article-journal" match="none">
+ <text macro="locators"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=", ">
+ <number variable="volume"/>
+ <group delimiter=" ">
+ <text term="issue" form="short"/>
+ <number variable="issue"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="legal_case">
+ <group delimiter=" ">
+ <number variable="volume"/>
+ <text variable="container-title"/>
+ <text variable="page"/>
+ </group>
+ </else-if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <group delimiter=". ">
+ <group delimiter=" ">
+ <text term="volume" form="short" text-case="capitalize-first"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <group delimiter=" ">
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" plural="true"/>
+ </group>
+ <text macro="edition"/>
+ </group>
+ </else-if>
+ <else-if type="chapter paper-conference" match="any">
+ <group delimiter=". ">
+ <choose>
+ <if variable="page" match="none">
+ <group delimiter=" ">
+ <text term="volume" form="short" text-case="capitalize-first"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ </if>
+ </choose>
+ <text macro="edition"/>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-newspaper">
+ <choose>
+ <if type="article-newspaper">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <number variable="edition"/>
+ <text term="edition"/>
+ </group>
+ <group delimiter=" ">
+ <text term="section" form="short"/>
+ <text variable="section"/>
+ </group>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="event">
+ <group delimiter=" ">
+ <text term="presented at"/>
+ <text variable="event"/>
+ </group>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if type="thesis">
+ <text variable="publisher"/>
+ </if>
+ <else>
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issued">
+ <choose>
+ <if variable="issued">
+ <choose>
+ <if type="graphic report" match="any">
+ <date variable="issued">
+ <date-part name="month" suffix=" "/>
+ <date-part name="day" suffix=", "/>
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else-if type="legal_case">
+ <group delimiter=" ">
+ <text variable="authority"/>
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </group>
+ </else-if>
+ <else-if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song thesis" match="any">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </else-if>
+ <else>
+ <date variable="issued">
+ <date-part name="month" suffix=" "/>
+ <date-part name="day" suffix=", "/>
+ <date-part name="year"/>
+ </date>
+ </else>
+ </choose>
+ </if>
+ <else-if variable="accessed URL" match="all">
+ </else-if>
+ <else>
+ <text term="no date" form="short"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="point-locators-subsequent">
+ <choose>
+ <if variable="locator">
+ <choose>
+ <if locator="page" match="none">
+ <group delimiter=" ">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <choose>
+ <if variable="volume">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text term="volume" form="short" text-case="lowercase"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <label variable="locator" form="short"/>
+ </group>
+ </if>
+ <else>
+ <label variable="locator" form="short"/>
+ </else>
+ </choose>
+ </if>
+ <else>
+ <label variable="locator" form="short"/>
+ </else>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <group delimiter=":">
+ <number variable="volume" form="numeric"/>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else>
+ <text variable="locator"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="point-locators-join-with-colon">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="locator page" match="any">
+ <text macro="point-locators"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="point-locators-join-with-comma">
+ <choose>
+ <if type="article-journal" match="none">
+ <text macro="point-locators"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="point-locators">
+ <choose>
+ <if variable="locator" match="none">
+ <choose>
+ <if type="article-journal chapter paper-conference" match="any">
+ <text variable="page"/>
+ </if>
+ </choose>
+ </if>
+ <else-if type="article-journal">
+ <group delimiter=" ">
+ <choose>
+ <if locator="page" match="none">
+ <label variable="locator" form="short" suffix=" "/>
+ </if>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else-if type="legal_case"/>
+ <else>
+ <group delimiter=" ">
+ <choose>
+ <if locator="page" match="none">
+ <label variable="locator" form="short"/>
+ </if>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="locators-chapter">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <choose>
+ <if variable="page">
+ <number variable="volume" suffix=":"/>
+ <text variable="page"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-journal">
+ <choose>
+ <if type="article-journal">
+ <text variable="page"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="archive-note">
+ <choose>
+ <if type="thesis">
+ <group delimiter=" ">
+ <text variable="archive"/>
+ <text variable="archive_location" prefix="(" suffix=")"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=", ">
+ <text variable="archive_location"/>
+ <text variable="archive"/>
+ <text variable="archive-place"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="archive">
+ <choose>
+ <if type="thesis">
+ <group delimiter=" ">
+ <text variable="archive"/>
+ <text variable="archive_location" prefix="(" suffix=")"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=". ">
+ <text variable="archive_location" text-case="capitalize-first"/>
+ <text variable="archive"/>
+ <text variable="archive-place"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue-note-join-with-space">
+ <choose>
+ <if type="article-journal legal_case" variable="publisher-place publisher" match="any">
+ <text macro="issue-note"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-note-join-with-comma">
+ <choose>
+ <if type="article-journal legal_case" variable="publisher-place publisher" match="none">
+ <text macro="issue-note"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-note">
+ <choose>
+ <if type="article-journal legal_case" match="any">
+ <text macro="issued" prefix="(" suffix=")"/>
+ </if>
+ <else-if variable="publisher-place publisher" match="any">
+ <group prefix="(" suffix=")" delimiter=", ">
+ <group delimiter=" ">
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis speech" match="any">
+ <text variable="genre"/>
+ </else-if>
+ </choose>
+ <text macro="event"/>
+ </group>
+ <text macro="publisher"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue-join-with-space">
+ <choose>
+ <if type="article-journal legal_case">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-join-with-period">
+ <choose>
+ <if type="article-journal legal_case" match="none">
+ <choose>
+ <if type="speech" variable="publisher publisher-place" match="any">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue-join-with-comma">
+ <choose>
+ <if type="article-journal legal_case" match="none">
+ <choose>
+ <if type="speech" variable="publisher publisher-place" match="none">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issue">
+ <choose>
+ <if type="article-journal legal_case" match="any">
+ <text macro="issued" prefix=" (" suffix=")"/>
+ </if>
+ <else-if type="speech">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <choose>
+ <if variable="title" match="none"/>
+ <else>
+ <text variable="genre" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ <text macro="event"/>
+ </group>
+ <text variable="event-place"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else-if variable="publisher-place publisher" match="any">
+ <group delimiter=", ">
+ <choose>
+ <if type="thesis">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ <text macro="publisher"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else>
+ <text macro="issued"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="access-note">
+ <group delimiter=", ">
+ <choose>
+ <if type="graphic report" match="any">
+ <text macro="archive-note"/>
+ </if>
+ <else-if type="article-journal article-magazine article-newspaper bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="none">
+ <text macro="archive-note"/>
+ </else-if>
+ </choose>
+ <choose>
+ <if variable="issued" match="none">
+ <group delimiter=" ">
+ <text term="accessed"/>
+ <date variable="accessed">
+ <date-part name="month" suffix=" "/>
+ <date-part name="day" suffix=", "/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else>
+ <text variable="URL"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="access">
+ <group delimiter=". ">
+ <choose>
+ <if type="graphic report" match="any">
+ <text macro="archive"/>
+ </if>
+ <else-if type="article-journal article-magazine article-newspaper bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="none">
+ <text macro="archive"/>
+ </else-if>
+ </choose>
+ <choose>
+ <if variable="issued" match="none">
+ <group delimiter=" ">
+ <text term="accessed" text-case="capitalize-first"/>
+ <date variable="accessed">
+ <date-part name="month" suffix=" "/>
+ <date-part name="day" suffix=", "/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else>
+ <text variable="URL"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="case-locator-subsequent">
+ <choose>
+ <if type="legal_case">
+ <text macro="locators-note"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="case-issue-subsequent">
+ <choose>
+ <if type="legal_case">
+ <text macro="issue"/>
+ </if>
+ </choose>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="1" disambiguate-add-names="true">
+ <layout suffix="." delimiter="; ">
+ <choose>
+ <if position="ibid-with-locator">
+ <group delimiter=", ">
+ <text term="ibid"/>
+ <text macro="point-locators-subsequent"/>
+ </group>
+ </if>
+ <else-if position="ibid">
+ <text term="ibid"/>
+ </else-if>
+ <else>
+ <group delimiter=", ">
+ <text macro="contributors-short"/>
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <text macro="title-short"/>
+ <text macro="case-locator-subsequent"/>
+ </group>
+ <text macro="case-issue-subsequent"/>
+ </group>
+ <text macro="point-locators-subsequent"/>
+ </group>
+ </else>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography hanging-indent="true" et-al-min="11" et-al-use-first="7" subsequent-author-substitute="&#8212;&#8212;&#8212;" entry-spacing="0">
+ <sort>
+ <key macro="contributors-sort"/>
+ <key variable="title"/>
+ <key variable="genre"/>
+ <key variable="issued"/>
+ </sort>
+ <layout suffix=".">
+ <group delimiter=". ">
+ <group delimiter=": ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <group delimiter=". ">
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <group delimiter=". ">
+ <group delimiter=" ">
+ <group delimiter=". ">
+ <text macro="contributors"/>
+ <text macro="title"/>
+ </group>
+ <text macro="description"/>
+ </group>
+ <text macro="secondary-contributors"/>
+ <group delimiter=", ">
+ <text macro="container-title"/>
+ <text macro="container-contributors"/>
+ <text macro="locators-chapter"/>
+ </group>
+ <text macro="locators-join-with-period"/>
+ </group>
+ <text macro="locators-join-with-comma"/>
+ </group>
+ <text macro="locators-join-with-space"/>
+ </group>
+ <text macro="collection-title"/>
+ <text macro="issue-join-with-period"/>
+ </group>
+ <text macro="issue-join-with-space"/>
+ </group>
+ <text macro="issue-join-with-comma"/>
+ <text macro="locators-newspaper"/>
+ </group>
+ <text macro="locators-journal"/>
+ </group>
+ <text macro="access"/>
+ </group>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/chinese-gb7714-2005-numeric.csl b/test/command/chinese-gb7714-2005-numeric.csl
new file mode 100644
index 000000000..de295ea60
--- /dev/null
+++ b/test/command/chinese-gb7714-2005-numeric.csl
@@ -0,0 +1,213 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="sort-only" default-locale="zh-CN">
+ <info>
+ <title>Chinese Std GB/T 7714-2005 (numeric, Chinese)</title>
+ <id>http://www.zotero.org/styles/chinese-gb7714-2005-numeric</id>
+ <link href="http://www.zotero.org/styles/chinese-gb7714-2005-numeric" rel="self"/>
+ <link href="http://gradschool.ustc.edu.cn/ylb/material/xw/wdxz/19.pdf" rel="documentation"/>
+ <author>
+ <name>heromyth</name>
+ <email>zxpmyth@yahoo.com.cn</email>
+ </author>
+ <category citation-format="numeric"/>
+ <category field="engineering"/>
+ <category field="generic-base"/>
+ <category field="science"/>
+ <summary>This style just partly implemented what the Chinese GB/T 7714-2005 requires.</summary>
+ <updated>2012-10-11T09:38:41+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <macro name="author">
+ <names variable="author">
+ <name initialize-with=" " name-as-sort-order="all" sort-separator=" " delimiter=", " delimiter-precedes-last="always">
+ <name-part name="family" text-case="uppercase"/>
+ </name>
+ </names>
+ </macro>
+ <macro name="recipient">
+ <names variable="recipient">
+ <name name-as-sort-order="all" sort-separator=" " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", " text-case="lowercase"/>
+ </names>
+ </macro>
+ <macro name="interviewer">
+ <names variable="interviewer">
+ <name name-as-sort-order="all" sort-separator=" " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", " text-case="lowercase"/>
+ </names>
+ </macro>
+ <macro name="composer">
+ <names variable="composer">
+ <name name-as-sort-order="all" sort-separator=" " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", " text-case="lowercase"/>
+ </names>
+ </macro>
+ <macro name="original-author">
+ <names variable="original-author">
+ <name name-as-sort-order="all" sort-separator=" " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", " text-case="lowercase"/>
+ </names>
+ </macro>
+ <macro name="title">
+ <text variable="title"/>
+ </macro>
+ <macro name="titleField">
+ <choose>
+ <if type="report">
+ <text macro="title" suffix="[R]. "/>
+ </if>
+ <else-if type="thesis">
+ <text macro="title" suffix="[D]. "/>
+ </else-if>
+ <else-if type="bill legislation" match="any">
+ <text variable="number" suffix=", "/>
+ <text macro="title" suffix="[S]"/>
+ </else-if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <text macro="title" suffix="[M]. "/>
+ </else-if>
+ <else-if type="paper-conference">
+ <text macro="title" suffix="[C]//"/>
+ </else-if>
+ <else-if type="chapter paper-conference" match="any">
+ <text macro="title" suffix="[G]//"/>
+ </else-if>
+ <else-if type="webpage">
+ <text macro="title" suffix="[EB/OL]. "/>
+ </else-if>
+ <else-if type="patent">
+ <text macro="title"/>
+ <text variable="number" prefix=": 中国, " suffix="[P]. "/>
+ </else-if>
+ <else>
+ <text macro="title" suffix="[J]. "/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="secondaryAuthor">
+ <names variable="editor">
+ <name initialize-with=" " name-as-sort-order="all" sort-separator=" " delimiter=", " delimiter-precedes-last="always">
+ <name-part name="family" text-case="uppercase"/>
+ </name>
+ </names>
+ <names variable="translator">
+ <name name-as-sort-order="all" sort-separator=" " delimiter=", " delimiter-precedes-last="always" suffix=", 译"/>
+ </names>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text variable="container-title" suffix=". "/>
+ </if>
+ <else-if type="report">
+ <text variable="collection-title" suffix=", "/>
+ <text variable="number" suffix=", "/>
+ </else-if>
+ <else-if type="bill legislation" match="any">
+ <text variable="container-title" prefix=". "/>
+ </else-if>
+ <else>
+ <text variable="container-title" suffix=", "/>
+ </else>
+ </choose>
+ <!--
+
+<text variable="event" suffix="event "/>
+<text variable="event-place" suffix="event-place "/>
+<text variable="original-title" suffix="original-title"/>
+
+ -->
+ <text variable="publisher-place" suffix=": "/>
+ <group delimiter=", ">
+ <text variable="publisher"/>
+ <choose>
+ <if type="webpage" variable="container-title" match="all">
+ <date variable="issued" suffix=". ">
+ <date-part name="year"/>
+ <date-part name="month" form="numeric-leading-zeros" prefix="-"/>
+ <date-part name="day" form="numeric-leading-zeros" prefix="-"/>
+ </date>
+ </if>
+ <else-if type="webpage"/>
+ <else-if type="patent">
+ <date variable="issued">
+ <date-part name="year"/>
+ <date-part name="month" form="numeric-leading-zeros" prefix="-"/>
+ <date-part name="day" form="numeric-leading-zeros" prefix="-"/>
+ </date>
+ </else-if>
+ <else-if variable="publisher">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </else-if>
+ <else-if type="bill legislation" match="any"/>
+ <else>
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </else>
+ </choose>
+ </group>
+ <text variable="volume" prefix=", "/>
+ <text variable="issue" prefix="(" suffix=")"/>
+ </macro>
+ <macro name="pageField">
+ <text variable="page"/>
+ </macro>
+ <macro name="referenceDate">
+ <choose>
+ <if type="webpage">
+ <date variable="issued" prefix="(" suffix=")">
+ <date-part name="year"/>
+ <date-part name="month" form="numeric-leading-zeros" prefix="-"/>
+ <date-part name="day" form="numeric-leading-zeros" prefix="-"/>
+ </date>
+ <date variable="accessed" prefix="[" suffix="]">
+ <date-part name="year"/>
+ <date-part name="month" form="numeric-leading-zeros" prefix="-"/>
+ <date-part name="day" form="numeric-leading-zeros" prefix="-"/>
+ </date>
+ </if>
+ </choose>
+ </macro>
+ <macro name="access">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else-if variable="URL">
+ <text variable="URL"/>
+ </else-if>
+ </choose>
+ </macro>
+ <citation collapse="citation-number">
+ <sort>
+ <key variable="citation-number" sort="ascending"/>
+ </sort>
+ <layout vertical-align="sup" prefix="[" suffix="]" delimiter=",">
+ <text variable="citation-number"/>
+ </layout>
+ </citation>
+ <bibliography et-al-min="4" et-al-use-first="3" second-field-align="flush" entry-spacing="0">
+ <layout suffix=".">
+ <text variable="citation-number" prefix="[" suffix="]"/>
+ <text macro="author" suffix=". "/>
+ <text macro="titleField"/>
+ <text macro="secondaryAuthor" suffix=". "/>
+ <text variable="edition" prefix="第" suffix="版. "/>
+ <text macro="publisher"/>
+ <text macro="pageField" prefix=": "/>
+ <text macro="referenceDate"/>
+ <choose>
+ <if type="webpage" match="any">
+ <text macro="access" prefix=". "/>
+ </if>
+ </choose>
+ <text macro="recipient"/>
+ <text macro="interviewer"/>
+ <text macro="composer"/>
+ <text macro="original-author"/>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/citeproc-7a.md b/test/command/citeproc-7a.md
new file mode 100644
index 000000000..fc4e799cf
--- /dev/null
+++ b/test/command/citeproc-7a.md
@@ -0,0 +1,42 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/chicago-fullnote-bibliography.csl
+references:
+ - id: test
+ title: Test
+ author:
+ family: Doe
+ given: John
+---
+
+Test [@test, 12].
+
+Test [@test, 12].
+
+Test.^[asdfasdf]
+
+Test [@test, 12].
+^D
+Test.[^1]
+
+Test.[^2]
+
+Test.[^3]
+
+Test.[^4]
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-test .csl-entry}
+Doe, John. "Test," n.d.
+:::
+:::
+
+[^1]: John Doe, "Test," n.d., 12.
+
+[^2]: Ibid.
+
+[^3]: asdfasdf
+
+[^4]: Doe, "Test," 12.
+```
diff --git a/test/command/citeproc-7b.md b/test/command/citeproc-7b.md
new file mode 100644
index 000000000..a8768f562
--- /dev/null
+++ b/test/command/citeproc-7b.md
@@ -0,0 +1,36 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/bioethics.csl
+references:
+ - id: test
+ title: Test
+ author:
+ family: Doe
+ given: John
+---
+
+Irrelevant.^[note]
+
+Test [@test, 12].
+
+Test.^[asdfasdf]
+
+Test [@test, 12].
+^D
+Irrelevant.[^1]
+
+Test.[^2]
+
+Test.[^3]
+
+Test.[^4]
+
+[^1]: note
+
+[^2]: J. Doe. ***Test***: 12.
+
+[^3]: asdfasdf
+
+[^4]: Doe (cited n. 2) : 12.
+```
diff --git a/test/command/din-1505-2.csl b/test/command/din-1505-2.csl
new file mode 100644
index 000000000..8d175738f
--- /dev/null
+++ b/test/command/din-1505-2.csl
@@ -0,0 +1,406 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="sort-only" default-locale="de-DE">
+ <info>
+ <title>DIN 1505-2 (author-date, German)</title>
+ <id>http://www.zotero.org/styles/din-1505-2</id>
+ <link href="http://www.zotero.org/styles/din-1505-2" rel="self"/>
+ <link href="http://www.bui.haw-hamburg.de/fileadmin/redaktion/diplom/Lorenzen__litverz.pdf" rel="documentation"/>
+ <link href="http://bibliothek.fh-potsdam.de/fileadmin/fhp_bib/dokumente/Schulungen/wissenschaftliches_Arbeiten/Zitieren_Lorenzen.pdf" rel="documentation"/>
+ <link href="http://www.uni-muenster.de/imperia/md/content/fachbereich_physik/didaktik_physik/materialien/materialschlichting/zitierregeln.pdf" rel="documentation"/>
+ <link href="http://forums.zotero.org/discussion/1857" rel="documentation"/>
+ <author>
+ <name>Sven Rothe</name>
+ <email>mmoole@googlemail.com</email>
+ </author>
+ <contributor>
+ <name>Julian Onions</name>
+ <email>julian.onions@gmail.com</email>
+ </contributor>
+ <category citation-format="author-date"/>
+ <category field="generic-base"/>
+ <summary>Style following DIN 1505-2, for other media types on additional standards
+ Hinweise zur Benutzung:
+ * Zitieren von Gesetzen:
+ - hier müssen manuell §, Abs und S. zur Seitenangabe beim Zitieren eingetragen werden
+ - im Kurzbeleg wird der Kurztitel verwendet, dafür keine Autoren eintragen!
+ - als Jahresangabe wird 'Datum des Inkrafttretens' herangezogen, Verwenden nur bei Verweis auf nicht z.Z. gültige Gesetze, z.B. (idF. v. 12.12.1972)
+ * Zitieren von Normen und Standards - nicht vollständig nach DIN 1505
+ - Nutzen Sie den Typ 'Bericht' - als Abhilfe, da es keinen Typ 'Standard' gibt.
+ - als Autor die Kurzbezeichnung inkl. Nummer und Jahr eingeben (z.B. VDI 2222-1997), Vorname leer, Jahr leer
+ - als Titel den ausführlichen Titel bei Bedarf (z.B. VDI Richtlinie 2222 Blatt 1 - Konstruktionsmethodik - Methodisches Entwickeln von Lösungsprinzipien)</summary>
+ <!-- This is just a beginning to try to have a DIN 1505 citation style,
+ Feel free to send me any comments, suggestions etc...
+ todo:
+ * basic media types (book, journal article, etc..)
+ * more media types (according DINxxx) audio video etc...
+ * fine tuning
+ * correcting errors
+ known bugs, help appreciated
+ * Abbreviations (Mitarb.) & (Hrsg. der Reihe) are missing (contributor, seriesEditor labels)
+ * "contributor" is not valid as a name variable , nevertheless it works but doesnt validate!
+ * author etc. first names should not be abbreviated
+ * reviewed author seems to be not available as variable (newspaper article)
+ * thesis type does notoffer a PLACE or FACULTY as variable!
+ how to show the place if it is not included in the University title!?!?
+ * thesis type: publisher (university), genre (type) dont seem to get through!?
+ -->
+ <!-- useful things:
+ non breaking space: &#160;
+ narrow no break space: uni202F / &#8239; - but this is not supported widely!
+ em dash: &#8212;
+ space: &#032;
+ tab: &#009;
+
+ -->
+ <updated>2012-09-27T22:06:38+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="de">
+ <terms>
+ <term name="anonymous" form="short">o.&#160;A.</term>
+ <term name="no date" form="short">o.&#160;J.</term>
+ <term name="collection-editor" form="short">Hrsg.</term>
+ <term name="retrieved">abgerufen am</term>
+ <term name="composer" form="short">Komp.</term>
+ <term name="composer" form="long">Komponist</term>
+ </terms>
+ </locale>
+ <macro name="author">
+ <names variable="author" delimiter=" ; ">
+ <name name-as-sort-order="all" sort-separator=", " delimiter=" ; " delimiter-precedes-last="always" font-variant="small-caps"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ </names>
+ </macro>
+ <macro name="author-container">
+ <names variable="container-author" delimiter=" ; ">
+ <name name-as-sort-order="all" sort-separator=", " initialize-with=". " delimiter=" ; " delimiter-precedes-last="always" font-variant="small-caps"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ </names>
+ </macro>
+ <macro name="editor">
+ <names variable="editor" delimiter=" ; ">
+ <name name-as-sort-order="all" sort-separator=", " initialize-with=". " delimiter=" ; " delimiter-precedes-last="always" font-variant="small-caps"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ <!-- needed: Label should appear as suffix to EVERY name...!-->
+ </names>
+ </macro>
+ <macro name="editor-collection">
+ <names variable="collection-editor" delimiter=" ; ">
+ <name name-as-sort-order="all" sort-separator=", " initialize-with=". " delimiter=" ; " delimiter-precedes-last="always" font-variant="small-caps"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ <!-- needed: Label should appear as suffix to EVERY name...!-->
+ </names>
+ </macro>
+ <macro name="composer">
+ <names variable="composer" delimiter=" ; ">
+ <name name-as-sort-order="all" sort-separator=", " delimiter=" ; " delimiter-precedes-last="always" font-variant="small-caps"/>
+ <label form="long" prefix=" (" suffix=")"/>
+ <!-- needed: Label should appear as suffix to EVERY name...!-->
+ </names>
+ </macro>
+ <!-- <macro name="contributor">
+ <names variable=" " delimiter=" ; ">
+ <name name-as-sort-order="all" sort-separator=", " initialize-with=". " delimiter=" ; "
+ delimiter-precedes-last="always" font-variant="small-caps"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ </names>
+ </macro>-->
+ <macro name="translator">
+ <names variable="translator" delimiter=" ; ">
+ <name name-as-sort-order="all" sort-separator=", " initialize-with=". " delimiter=" ; " delimiter-precedes-last="always" font-variant="small-caps"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ <!-- needed: Label should appear as suffix to EVERY name...!-->
+ </names>
+ </macro>
+ <macro name="recipient">
+ <names variable="recipient" delimiter=" ; ">
+ <name name-as-sort-order="all" sort-separator=", " initialize-with=". " delimiter=" ; " delimiter-precedes-last="always" font-variant="small-caps"/>
+ <!--<label form="long" prefix=" (" suffix=")"/>-->
+ <!-- needed: Label should appear as suffix to EVERY name...!-->
+ </names>
+ </macro>
+ <macro name="author-short">
+ <names variable="author">
+ <name form="short" and="symbol" delimiter=", " initialize-with=". " delimiter-precedes-last="never" font-variant="small-caps"/>
+ <et-al font-variant="normal"/>
+ <substitute>
+ <names variable="editor" font-variant="small-caps"/>
+ <names variable="translator" font-variant="small-caps"/>
+ <choose>
+ <if type="bill book graphic legal_case motion_picture report song" match="any">
+ <text variable="title" form="short" font-style="italic"/>
+ </if>
+ <else-if type="bill legal_case legislation" match="any">
+ <text variable="title" form="short" font-style="normal"/>
+ </else-if>
+ <else>
+ <text variable="title" form="short" quotes="true"/>
+ </else>
+ </choose>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="access">
+ <group>
+ <text term="retrieved" suffix=" "/>
+ <date variable="accessed">
+ <date-part name="year" form="long" suffix="-"/>
+ <date-part name="month" form="numeric-leading-zeros" suffix="-"/>
+ <date-part name="day" form="numeric-leading-zeros"/>
+ </date>
+ <!--<date variable="accessed" form="numeric" date-parts="year-month-day"/> // dd.mm.yyy -->
+ </group>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="bill legislation" match="any">
+ <group delimiter=" &#8212; ">
+ <text variable="title-short" font-style="normal"/>
+ <text variable="title"/>
+ </group>
+ </if>
+ <else-if type="book graphic legal_case motion_picture report song" match="any">
+ <text variable="title" font-style="italic"/>
+ </else-if>
+ <else>
+ <text variable="title"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="genre">
+ <choose>
+ <if type="report thesis manuscript map" match="any">
+ <group>
+ <text variable="genre"/>
+ <!--<text term="number" form="short" suffix=" "/>-->
+ <text variable="number" prefix=" Nr. "/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="volumes">
+ <group delimiter=" ">
+ <text term="volume" form="short" plural="false"/>
+ <number variable="volume" form="numeric"/>
+ <number variable="number-of-volumes" form="numeric" prefix="v. "/>
+ </group>
+ </macro>
+ <macro name="edition">
+ <group>
+ <number variable="edition" form="numeric" suffix=". "/>
+ <text term="edition" form="short" plural="false"/>
+ </group>
+ </macro>
+ <macro name="pages">
+ <choose>
+ <if type="chapter paper-conference article-journal" match="any">
+ <label variable="page" form="short" suffix="&#160;"/>
+ <text variable="page"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="dimensions">
+ <group>
+ <text variable="dimensions"/>
+ </group>
+ </macro>
+ <macro name="medium">
+ <group>
+ <text variable="medium"/>
+ </group>
+ </macro>
+ <macro name="scale">
+ <group>
+ <text term="scale"/>
+ <text prefix=" " variable="scale"/>
+ </group>
+ </macro>
+ <macro name="recipient-show">
+ <choose>
+ <if type="personal_communication">
+ <choose>
+ <if variable="genre">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ <else>
+ <text term="letter" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ <text macro="recipient" prefix=", "/>
+ </macro>
+ <macro name="cite-year">
+ <group>
+ <choose>
+ <if type="bill legislation" match="any">
+ <date variable="issued" prefix=" (" suffix=")">
+ <date-part name="year" prefix="idF. v. "/>
+ </date>
+ </if>
+ <else>
+ <date variable="issued" prefix=", ">
+ <date-part name="year"/>
+ </date>
+ <text variable="year-suffix"/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <macro name="bibliography-year">
+ <date variable="issued" form="numeric" date-parts="year"/>
+ <text variable="year-suffix"/>
+ </macro>
+ <macro name="locator">
+ <group>
+ <choose>
+ <if type="bill legislation" match="any">
+ <text variable="locator" prefix=" "/>
+ </if>
+ <else>
+ <label variable="locator" form="short" prefix=", "/>
+ <text variable="locator" prefix=" "/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <citation et-al-min="3" et-al-use-first="1" disambiguate-add-year-suffix="true" disambiguate-add-names="false" disambiguate-add-givenname="false" collapse="year">
+ <sort>
+ <key macro="author"/>
+ <key variable="issued"/>
+ </sort>
+ <layout prefix="(" suffix=")" delimiter="; ">
+ <group>
+ <text macro="author-short"/>
+ <text macro="cite-year"/>
+ <text macro="locator"/>
+ </group>
+ </layout>
+ </citation>
+ <bibliography hanging-indent="true" et-al-min="9" et-al-use-first="8">
+ <sort>
+ <key macro="author"/>
+ <key variable="issued"/>
+ <key variable="title"/>
+ </sort>
+ <layout>
+ <group delimiter=" ; " suffix=":">
+ <text macro="author"/>
+ <choose>
+ <if type="bill book graphic legal_case legislation manuscript map motion_picture report song thesis webpage" match="any">
+ <!-- except type="chapter article " etc.... -->
+ <text macro="editor"/>
+ <text macro="editor-collection"/>
+ <text macro="composer"/>
+ </if>
+ </choose>
+ <!-- <text macro="contributor"/> -->
+ <text macro="translator"/>
+ </group>
+ <choose>
+ <!-- Tabelle 1 aus litverz.ps -->
+ <if type="bill book broadcast graphic legal_case legislation manuscript map motion_picture report song" match="any">
+ <text prefix=" " macro="title"/>
+ <text prefix=", " variable="collection-title" font-style="italic"/>
+ <!--Reihe-->
+ <text prefix=" (" macro="genre" suffix=")"/>
+ <text prefix=". " macro="volumes"/>
+ <text prefix=". " macro="edition"/>
+ <text prefix=". " macro="medium"/>
+ <text prefix=". " macro="dimensions"/>
+ <text prefix=". " variable="publisher-place"/>
+ <text prefix="&#160;: " variable="publisher"/>
+ <text macro="bibliography-year" prefix=", "/>
+ <!-- " (1. Gesamttitel mit Zählung)"
+ " (2. Gesamttitel mit Zählung)" -->
+ <text prefix=" &#8211;&#160;" macro="scale"/>
+ <text prefix=". &#8212;&#160;" variable="note"/>
+ <text prefix=" &#8212;&#160;ISBN&#160;" variable="ISBN"/>
+ </if>
+ <!-- Tabelle 3 aus litverz.ps -->
+ <else-if type="chapter paper-conference" match="any">
+ <text prefix=" " macro="title" suffix="."/>
+ <text prefix=". " term="in" text-case="capitalize-all" suffix=": "/>
+ <!-- verfahre nach Tabelle 1... -->
+ <group delimiter=" ; " suffix=": ">
+ <text macro="author-container"/>
+ <text macro="editor"/>
+ <text macro="editor-collection"/>
+ </group>
+ <text variable="container-title" font-style="italic"/>
+ <text prefix=", " variable="collection-title" font-style="italic"/>
+ <!-- Reihe -->
+ <text prefix=". " macro="volumes"/>
+ <!-- <text prefix=" : " variable="title of volumes"/> what is this? -->
+ <text prefix=". " macro="edition"/>
+ <text prefix=". " variable="publisher-place"/>
+ <text prefix="&#160;: " variable="publisher"/>
+ <text macro="bibliography-year" prefix=", "/>
+ <!-- " (1. Gesamttitel mit Zählung)"
+ " (2. Gesamttitel mit Zählung)" -->
+ <text prefix=". &#8212;&#160;" variable="note"/>
+ <text prefix=" &#8212;&#160;ISBN&#160;" variable="ISBN"/>
+ <text prefix=", " macro="pages"/>
+ </else-if>
+ <!-- Tabelle 5 aus litverz.ps - Hochschulschriften
+ (Diplomarbeiten, Dissertationen, Master-A., unverö. Studienarbeiten -->
+ <else-if type="thesis" match="any">
+ <text prefix=" " macro="title" font-style="italic"/>
+ <text prefix=". " macro="edition"/>
+ <text prefix=". " variable="publisher-place"/>
+ <text prefix=", " variable="publisher" form="long"/>
+ <!-- <text prefix=", " variable="faculty"/> -->
+ <text prefix=", " macro="genre"/>
+ <text macro="bibliography-year" prefix=", "/>
+ <text prefix=". &#8212;&#160;" variable="note"/>
+ </else-if>
+ <else-if type="webpage post post-weblog" match="any">
+ <text prefix=" " macro="title" suffix=". " font-style="italic"/>
+ <text prefix="URL " variable="URL"/>
+ <text prefix=". - " macro="access"/>
+ <text prefix=". &#8212;&#160;" variable="container-title"/>
+ <text prefix=". &#8212;&#160;" variable="note"/>
+ </else-if>
+ <!-- Tabelle 2 aus litverz.ps UND -->
+ <!-- Tabelle 4 aus litverz.ps - Schriften von Tagungen, Konferenzen, Symposien, ...-->
+ <else-if type="article article-journal article-magazine article-newspaper" match="any">
+ <text prefix=" " variable="title"/>
+ <!-- " : Zusatz zum Sachtitel"
+ ". Angabe des Teils"
+ " (Gesamttitelangabe)" -->
+ <group>
+ <text prefix=". " term="in" text-case="capitalize-first" suffix=": "/>
+ <text macro="editor" suffix=" "/>
+ <text variable="container-title" font-style="italic"/>
+ <text prefix=", " variable="collection-title" font-style="italic" suffix="."/>
+ <!--", unterreihe der zeitschrift/zeitung" -->
+ </group>
+ <text prefix=" " macro="volumes"/>
+ <text prefix=". " variable="publisher-place"/>
+ <text prefix=", " variable="publisher" form="long"/>
+ <text macro="bibliography-year" prefix=" (" suffix=")"/>
+ <text prefix=", Nr.&#160;" variable="issue"/>
+ <text prefix=", " macro="pages"/>
+ <text prefix=". &#8212;&#160;" variable="note"/>
+ <text prefix=" &#8212;&#160;ISBN&#160;" variable="ISBN"/>
+ </else-if>
+ <!-- keiner der oben genannten fälle -->
+ <else>
+ <group suffix=".">
+ <text prefix=" " macro="title"/>
+ <text prefix=", " macro="editor"/>
+ <text prefix=". " macro="recipient-show"/>
+ </group>
+ <group prefix=" " suffix=".">
+ <text variable="container-title" font-style="italic"/>
+ <group prefix=", ">
+ <text variable="volume" font-style="italic"/>
+ <text variable="issue" prefix="(" suffix=")"/>
+ </group>
+ <text prefix=", " macro="pages"/>
+ </group>
+ </else>
+ </choose>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/harvard-university-of-kent.csl b/test/command/harvard-university-of-kent.csl
new file mode 100644
index 000000000..0243de136
--- /dev/null
+++ b/test/command/harvard-university-of-kent.csl
@@ -0,0 +1,253 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="sort-only" default-locale="en-GB">
+ <info>
+ <title>University of Kent - Harvard</title>
+ <id>http://www.zotero.org/styles/harvard-university-of-kent</id>
+ <link href="http://www.zotero.org/styles/harvard-university-of-kent" rel="self"/>
+ <link href="http://www.zotero.org/styles/harvard-cardiff-university-biosi" rel="template"/>
+ <link href="http://www.kent.ac.uk/ai/Harvard-Style-Guide-July-2014.pdf" rel="documentation"/>
+ <author>
+ <name>Sebastian Karcher</name>
+ </author>
+ <category citation-format="author-date"/>
+ <category field="generic-base"/>
+ <summary>The Harvard author-date style - adapted for the University of Kent</summary>
+ <updated>2012-09-27T22:06:38+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <macro name="editor">
+ <names variable="editor" delimiter=", ">
+ <name name-as-sort-order="all" and="text" sort-separator=", " initialize-with=". " delimiter=", " delimiter-precedes-last="never"/>
+ <label form="short" prefix=" "/>
+ </names>
+ </macro>
+ <macro name="author">
+ <names variable="author">
+ <name name-as-sort-order="all" and="text" sort-separator=", " initialize-with="." delimiter-precedes-last="never" delimiter=", "/>
+ <label form="short" prefix=" "/>
+ <et-al font-style="italic"/>
+ <substitute>
+ <names variable="editor"/>
+ <text macro="title-substitute"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="author-short">
+ <names variable="author">
+ <name form="short" and="text" delimiter=", " delimiter-precedes-last="never" initialize-with=". "/>
+ <et-al font-style="italic"/>
+ <substitute>
+ <names variable="editor"/>
+ <text macro="title-substitute"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="access">
+ <choose>
+ <if variable="URL">
+ <group delimiter=" ">
+ <group delimiter=": ">
+ <text term="available at" text-case="capitalize-first"/>
+ <text variable="URL"/>
+ </group>
+ <group prefix="[" suffix="]" delimiter=": ">
+ <text term="accessed" text-case="capitalize-first"/>
+ <date variable="accessed">
+ <date-part name="day" suffix=" "/>
+ <date-part name="month" suffix=" "/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song thesis webpage" match="any">
+ <text variable="title" font-style="italic" text-case="title"/>
+ </if>
+ <else>
+ <text variable="title"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title-substitute">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song thesis webpage" match="any">
+ <text variable="title" font-style="italic" text-case="title"/>
+ </if>
+ <else-if type="broadcast">
+ <choose>
+ <if variable="container-title">
+ <text variable="title"/>
+ </if>
+ <else>
+ <text variable="title" font-style="italic"/>
+ </else>
+ </choose>
+ </else-if>
+ <else>
+ <text variable="title"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if type="thesis">
+ <text variable="publisher"/>
+ </if>
+ <else-if type="graphic">
+ <text variable="archive"/>
+ </else-if>
+ <else>
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="year-date">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else>
+ <text term="no date" form="short"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" suffix="."/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="online">
+ <choose>
+ <if variable="medium">
+ <text variable="medium" prefix="[" suffix="]"/>
+ </if>
+ <else-if variable="URL">
+ <text term="online" text-case="capitalize-first" prefix="[" suffix="]"/>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="broadcast-info">
+ <choose>
+ <if type="broadcast">
+ <group delimiter=". ">
+ <text variable="container-title" font-style="italic"/>
+ <text variable="number"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="pages">
+ <group>
+ <label variable="page" form="short" suffix=" "/>
+ <text variable="page"/>
+ </group>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="1" disambiguate-add-year-suffix="true" disambiguate-add-names="true" disambiguate-add-givenname="true">
+ <layout prefix="(" suffix=")" delimiter="; ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text macro="author-short"/>
+ <text macro="year-date"/>
+ </group>
+ <group>
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </group>
+ </layout>
+ </citation>
+ <bibliography et-al-min="4" et-al-use-first="1" hanging-indent="true">
+ <sort>
+ <key macro="author"/>
+ <key variable="title"/>
+ </sort>
+ <layout suffix=".">
+ <text macro="author"/>
+ <date variable="issued" prefix=" (" suffix=").">
+ <date-part name="year"/>
+ </date>
+ <choose>
+ <if type="book broadcast graphic legal_case motion_picture report song" match="any">
+ <group prefix=" " delimiter=". " suffix=".">
+ <text macro="title"/>
+ <text macro="broadcast-info"/>
+ <text macro="online"/>
+ <group delimiter=" ">
+ <text term="volume" form="short" text-case="capitalize-first"/>
+ <text variable="volume"/>
+ </group>
+ <text macro="edition"/>
+ <text macro="editor"/>
+ <text variable="collection-title"/>
+ <text variable="collection-number" prefix="Number "/>
+ <text macro="publisher"/>
+ <text variable="dimensions"/>
+ </group>
+ </if>
+ <else-if type="chapter paper-conference" match="any">
+ <text macro="title" prefix=" " suffix="."/>
+ <group prefix=" " delimiter=" ">
+ <text term="in" text-case="capitalize-first" suffix=":"/>
+ <text macro="editor"/>
+ <text variable="container-title" font-style="italic" suffix="." text-case="title"/>
+ <text macro="edition"/>
+ <group suffix="." delimiter=", ">
+ <text macro="publisher"/>
+ <text macro="pages"/>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="thesis">
+ <group prefix=" " delimiter=". " suffix=".">
+ <text macro="title"/>
+ <group delimiter=", ">
+ <text variable="genre"/>
+ <text macro="publisher"/>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="webpage">
+ <group prefix=" " suffix=".">
+ <group delimiter=" " suffix=".">
+ <text macro="title"/>
+ <text macro="online"/>
+ </group>
+ <text macro="edition"/>
+ </group>
+ </else-if>
+ <else>
+ <group suffix=".">
+ <text macro="title" prefix=" "/>
+ <text macro="editor" prefix=" "/>
+ </group>
+ <group prefix=" " suffix=".">
+ <group delimiter=" ">
+ <text variable="container-title" font-style="italic"/>
+ <text macro="online"/>
+ </group>
+ <text variable="volume" font-weight="bold" prefix=" "/>
+ <text variable="page" prefix=":"/>
+ </group>
+ </else>
+ </choose>
+ <text prefix=". " macro="access" suffix="."/>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/ieee.csl b/test/command/ieee.csl
new file mode 100644
index 000000000..0bde51130
--- /dev/null
+++ b/test/command/ieee.csl
@@ -0,0 +1,339 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="sort-only">
+ <info>
+ <title>IEEE</title>
+ <id>http://www.zotero.org/styles/ieee</id>
+ <link href="http://www.zotero.org/styles/ieee" rel="self"/>
+ <link href="http://www.ieee.org/documents/style_manual.pdf" rel="documentation"/>
+ <link href="http://www.ieee.org/documents/auinfo07.pdf" rel="documentation"/>
+ <author>
+ <name>Michael Berkowitz</name>
+ <email>mberkowi@gmu.edu</email>
+ </author>
+ <contributor>
+ <name>Julian Onions</name>
+ <email>julian.onions@gmail.com</email>
+ </contributor>
+ <contributor>
+ <name>Rintze Zelle</name>
+ <uri>http://twitter.com/rintzezelle</uri>
+ </contributor>
+ <contributor>
+ <name>Stephen Frank</name>
+ <uri>http://www.zotero.org/sfrank</uri>
+ </contributor>
+ <contributor>
+ <name>Sebastian Karcher</name>
+ </contributor>
+ <category citation-format="numeric"/>
+ <category field="engineering"/>
+ <category field="generic-base"/>
+ <updated>2013-12-17T18:04:02+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en">
+ <terms>
+ <term name="chapter" form="short">ch.</term>
+ <term name="presented at">presented at the</term>
+ <term name="available at">available</term>
+ </terms>
+ </locale>
+ <!-- Macros -->
+ <macro name="edition">
+ <choose>
+ <if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" text-case="capitalize-first" suffix="."/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="issued">
+ <choose>
+ <if type="article-journal report" match="any">
+ <date variable="issued">
+ <date-part name="month" form="short" suffix=" "/>
+ <date-part name="year" form="long"/>
+ </date>
+ </if>
+ <else-if type=" bill book chapter graphic legal_case legislation motion_picture paper-conference song thesis" match="any">
+ <date variable="issued">
+ <date-part name="year" form="long"/>
+ </date>
+ </else-if>
+ <else>
+ <date variable="issued">
+ <date-part name="day" form="numeric-leading-zeros" suffix="-"/>
+ <date-part name="month" form="short" suffix="-" strip-periods="true"/>
+ <date-part name="year" form="long"/>
+ </date>
+ </else>
+ </choose>
+ </macro>
+ <macro name="author">
+ <names variable="author">
+ <name initialize-with=". " delimiter=", " and="text"/>
+ <label form="short" prefix=", " text-case="capitalize-first"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <name initialize-with=". " delimiter=", " and="text"/>
+ <label form="short" prefix=", " text-case="capitalize-first"/>
+ </names>
+ </macro>
+ <macro name="locators">
+ <group delimiter=", ">
+ <text macro="edition"/>
+ <group delimiter=" ">
+ <text term="volume" form="short"/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <group delimiter=" ">
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" plural="true"/>
+ </group>
+ <group delimiter=" ">
+ <text term="issue" form="short"/>
+ <number variable="issue" form="numeric"/>
+ </group>
+ </group>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture song" match="any">
+ <text variable="title" font-style="italic"/>
+ </if>
+ <else>
+ <text variable="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if type=" bill book chapter graphic legal_case legislation motion_picture paper-conference song" match="any">
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=", ">
+ <text variable="publisher"/>
+ <text variable="publisher-place"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="event">
+ <choose>
+ <if type="paper-conference speech" match="any">
+ <choose>
+ <!-- Published Conference Paper -->
+ <if variable="container-title">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text term="in"/>
+ <text variable="container-title" font-style="italic"/>
+ </group>
+ <text variable="event-place"/>
+ </group>
+ </if>
+ <!-- Unpublished Conference Paper -->
+ <else>
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text term="presented at"/>
+ <text variable="event"/>
+ </group>
+ <text variable="event-place"/>
+ </group>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="access">
+ <choose>
+ <if type="webpage">
+ <choose>
+ <if variable="URL">
+ <group delimiter=". ">
+ <text term="online" prefix="[" suffix="]" text-case="capitalize-first"/>
+ <group delimiter=": ">
+ <text term="available at" text-case="capitalize-first"/>
+ <text variable="URL"/>
+ </group>
+ <group prefix="[" suffix="]" delimiter=": ">
+ <text term="accessed" text-case="capitalize-first"/>
+ <date variable="accessed">
+ <date-part name="day" form="numeric-leading-zeros" suffix="-"/>
+ <date-part name="month" form="short" suffix="-" strip-periods="true"/>
+ <date-part name="year" form="long"/>
+ </date>
+ </group>
+ </group>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="page">
+ <group>
+ <label variable="page" form="short" suffix=" "/>
+ <text variable="page"/>
+ </group>
+ </macro>
+ <macro name="citation-locator">
+ <group delimiter=" ">
+ <choose>
+ <if locator="page">
+ <label variable="locator" form="short"/>
+ </if>
+ <else>
+ <label variable="locator" form="short" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </macro>
+ <!-- Citation -->
+ <citation collapse="citation-number">
+ <sort>
+ <key variable="citation-number"/>
+ </sort>
+ <layout delimiter=", ">
+ <group prefix="[" suffix="]" delimiter=", ">
+ <text variable="citation-number"/>
+ <text macro="citation-locator"/>
+ </group>
+ </layout>
+ </citation>
+ <!-- Bibliography -->
+ <bibliography entry-spacing="0" second-field-align="flush">
+ <layout suffix=".">
+ <!-- Citation Number -->
+ <text variable="citation-number" prefix="[" suffix="]"/>
+ <!-- Author(s) -->
+ <text macro="author" suffix=", "/>
+ <!-- Rest of Citation -->
+ <choose>
+ <!-- Specific Formats -->
+ <if type="article-journal">
+ <group delimiter=", ">
+ <text macro="title"/>
+ <text variable="container-title" font-style="italic" form="short"/>
+ <text macro="locators"/>
+ <text macro="page"/>
+ <text macro="issued"/>
+ </group>
+ </if>
+ <else-if type="paper-conference speech" match="any">
+ <group delimiter=", ">
+ <text macro="title"/>
+ <text macro="event"/>
+ <text macro="issued"/>
+ <text macro="locators"/>
+ <text macro="page"/>
+ </group>
+ </else-if>
+ <else-if type="report">
+ <group delimiter=", ">
+ <text macro="title"/>
+ <text macro="publisher"/>
+ <group delimiter=" ">
+ <text variable="genre"/>
+ <text variable="number"/>
+ </group>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else-if type="thesis">
+ <group delimiter=", ">
+ <text macro="title"/>
+ <text variable="genre"/>
+ <text macro="publisher"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else-if type="webpage post-weblog" match="any">
+ <group delimiter=", " suffix=". ">
+ <text macro="title"/>
+ <text variable="container-title" font-style="italic"/>
+ <text macro="issued"/>
+ </group>
+ <text macro="access"/>
+ </else-if>
+ <else-if type="patent">
+ <group delimiter=", ">
+ <text macro="title"/>
+ <text variable="number"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <!-- Generic/Fallback Formats -->
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <group delimiter=", " suffix=". ">
+ <text macro="title"/>
+ <text macro="locators"/>
+ </group>
+ <group delimiter=", ">
+ <text macro="publisher"/>
+ <text macro="issued"/>
+ <text macro="page"/>
+ </group>
+ </else-if>
+ <else-if type="article-magazine article-newspaper broadcast interview manuscript map patent personal_communication song speech thesis webpage" match="any">
+ <group delimiter=", ">
+ <text macro="title"/>
+ <text variable="container-title" font-style="italic"/>
+ <text macro="locators"/>
+ <text macro="publisher"/>
+ <text macro="page"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else-if type="chapter paper-conference" match="any">
+ <group delimiter=", " suffix=", ">
+ <text macro="title"/>
+ <group delimiter=" ">
+ <text term="in"/>
+ <text variable="container-title" font-style="italic"/>
+ </group>
+ <text macro="locators"/>
+ </group>
+ <text macro="editor" suffix=" "/>
+ <group delimiter=", ">
+ <text macro="publisher"/>
+ <text macro="issued"/>
+ <text macro="page"/>
+ </group>
+ </else-if>
+ <else>
+ <group delimiter=", " suffix=". ">
+ <text macro="title"/>
+ <text variable="container-title" font-style="italic"/>
+ <text macro="locators"/>
+ </group>
+ <group delimiter=", ">
+ <text macro="publisher"/>
+ <text macro="page"/>
+ <text macro="issued"/>
+ </group>
+ </else>
+ </choose>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/issue160.csl b/test/command/issue160.csl
new file mode 100644
index 000000000..32446e057
--- /dev/null
+++ b/test/command/issue160.csl
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" default-locale="en-US">
+ <info>
+ <title>Issue 160 Test Style</title>
+ <id>issue-160-test</id>
+ <category citation-format="label"/>
+ <updated>2017-02-04T19:31:46+0000</updated>
+ </info>
+ <citation>
+ <layout prefix="[" suffix="]" delimiter=",">
+ <text variable="citation-label"/>
+ </layout>
+ </citation>
+ <bibliography>
+ <layout>
+ <text variable="citation-label" prefix="[" suffix="] "/>
+ <group delimiter=". " suffix=".">
+ <names variable="author">
+ <name delimiter=", " delimiter-precedes-last="always"/>
+ </names>
+ <text variable="title"/>
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </group>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/issue437.csl b/test/command/issue437.csl
new file mode 100644
index 000000000..396ff441c
--- /dev/null
+++ b/test/command/issue437.csl
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" default-locale="en-US" version="1.0">
+ <info>
+ <title>Minimal style to reproduce bug</title>
+ <id>http://www.example.org/styles/minimal-test-style</id>
+ <author>
+ <name>Nicolas Chachereau</name>
+ <email>nicolas@nchachereau.ch</email>
+ </author>
+ <updated>2020-01-27T14:27:45+01:00</updated>
+ </info>
+ <citation>
+ <layout>
+ <group delimiter=", ">
+ <names variable="author"/>
+ <text variable="title"/>
+ <text variable="publisher-place"/>
+ <date variable="issued" form="numeric" date-parts="year"/>
+ <group delimiter="&#160;">
+ <number variable="number-of-pages"/>
+ <label variable="number-of-pages"/>
+ </group>
+ </group>
+ </layout>
+ </citation>
+</style>
diff --git a/test/command/issue58.csl b/test/command/issue58.csl
new file mode 100644
index 000000000..b18500cc8
--- /dev/null
+++ b/test/command/issue58.csl
@@ -0,0 +1,553 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="never" page-range-format="chicago">
+ <info>
+ <title>Chicago Manual of Style 16th edition (author-date) modif 2014-06-30</title>
+ <id></id>
+ <link href="" rel="self"/>
+ <link href="http://www.chicagomanualofstyle.org/tools_citationguide.html" rel="documentation"/>
+ <author>
+ <name>Julian Onions</name>
+ <email>julian.onions@gmail.com</email>
+ </author>
+ <contributor>
+ <name>Sebastian Karcher</name>
+ </contributor>
+ <contributor>
+ <name>Richard Karnesky</name>
+ <email>karnesky+zotero@gmail.com</email>
+ <uri>http://arc.nucapt.northwestern.edu/Richard_Karnesky</uri>
+ </contributor>
+ <contributor>
+ <name>Andrew Dunning</name>
+ <email>andrew.dunning@utoronto.ca</email>
+ </contributor>
+ <category citation-format="author-date"/>
+ <category field="generic-base"/>
+ <summary>The author-date variant of the Chicago style</summary>
+ <updated>2014-05-23T03:53:32+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en">
+ <terms>
+ <term name="editor" form="verb-short">ed.</term>
+ <term name="container-author" form="verb">by</term>
+ <term name="translator" form="verb-short">trans.</term>
+ <term name="editortranslator" form="verb">
+ <single>edited and translated by</single>
+ <multiple>edited and translated by</multiple>
+ </term>
+ <term name="translator" form="short">trans.</term>
+ </terms>
+ </locale>
+ <macro name="secondary-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="none">
+ <names variable="editor translator" delimiter=". ">
+ <label form="verb" text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-contributors">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <group prefix=", " delimiter=", ">
+ <names variable="container-author" delimiter=", ">
+ <label form="verb" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="translator">
+ <names variable="translator">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="recipient">
+ <choose>
+ <if type="personal_communication">
+ <choose>
+ <if variable="genre">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ <else>
+ <text term="letter" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ <names variable="recipient" delimiter=", ">
+ <label form="verb" prefix=" " text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="noauthor-container-title">
+ <choose>
+ <if variable="container-title">
+ <choose>
+ <if type="article-journal article-magazine article-newspaper" match="any">
+ <text macro="container-title"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="contributors">
+ <group delimiter=". ">
+ <names variable="author">
+ <name and="text" name-as-sort-order="first" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="noauthor-container-title"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ <text macro="recipient"/>
+ </group>
+ </macro>
+ <macro name="contributors-short">
+ <names variable="author">
+ <name form="short" and="text" delimiter=", " initialize-with=". "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="noauthor-container-title"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="interviewer">
+ <names variable="interviewer" delimiter=", ">
+ <label form="verb" prefix=" " text-case="capitalize-first" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="archive">
+ <group delimiter=". ">
+ <text variable="archive_location" text-case="capitalize-first"/>
+ <text variable="archive"/>
+ <text variable="archive-place"/>
+ </group>
+ </macro>
+ <macro name="access">
+ <group delimiter=". ">
+ <choose>
+ <if type="graphic report" match="any">
+ <text macro="archive"/>
+ </if>
+ <else-if type="article-journal bill book chapter legal_case legislation motion_picture paper-conference" match="none">
+ <text macro="archive"/>
+ </else-if>
+ </choose>
+ <choose>
+ <if variable="issued" match="none">
+ <group delimiter=" ">
+ <text term="accessed" text-case="capitalize-first"/>
+ <date variable="accessed" delimiter=" ">
+ <date-part name="month"/>
+ <date-part name="day"/>
+ </date>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix="doi:"/>
+ </if>
+ <else>
+ <text variable="URL"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if variable="title" match="none">
+ <choose>
+ <if type="personal_communication" match="none">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legislation motion_picture report song" match="any">
+ <text variable="title" text-case="title" font-style="italic"/>
+ <group prefix=" (" suffix=")" delimiter=" ">
+ <text term="version"/>
+ <text variable="version"/>
+ </group>
+ </else-if>
+ <else-if variable="reviewed-author">
+ <group delimiter=", ">
+ <text variable="title" font-style="italic" prefix="Review of "/>
+ <names variable="reviewed-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </else-if>
+ <else-if type="legal_case interview" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else>
+ <text variable="title" text-case="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" " prefix=". ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short" strip-periods="true"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" prefix=". "/>
+ </else>
+ </choose>
+ </if>
+ <else-if type="chapter paper-conference" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" " prefix=", ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" prefix=", "/>
+ </else>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="volume">
+ <text variable="volume" prefix=" "/>
+ <group prefix=" (" suffix=")">
+ <choose>
+ <if variable="issue">
+ <text variable="issue"/>
+ </if>
+ <else>
+ <date variable="issued">
+ <date-part name="month"/>
+ </date>
+ </else>
+ </choose>
+ </group>
+ </if>
+ <else-if variable="issue">
+ <group delimiter=" " prefix=", ">
+ <text term="issue" form="short"/>
+ <text variable="issue"/>
+ <date variable="issued" prefix="(" suffix=")">
+ <date-part name="month"/>
+ </date>
+ </group>
+ </else-if>
+ <else>
+ <date variable="issued" prefix=", ">
+ <date-part name="month"/>
+ </date>
+ </else>
+ </choose>
+ </if>
+ <else-if type="legal_case">
+ <text variable="volume" prefix=", "/>
+ <text variable="container-title" prefix=" "/>
+ <text variable="page" prefix=" "/>
+ </else-if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <group prefix=". " delimiter=". ">
+ <group>
+ <text term="volume" form="short" text-case="capitalize-first" suffix=" "/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ <group>
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" prefix=" " plural="true"/>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="chapter paper-conference" match="any">
+ <choose>
+ <if variable="page" match="none">
+ <group prefix=". ">
+ <text term="volume" form="short" text-case="capitalize-first" suffix=" "/>
+ <number variable="volume" form="numeric"/>
+ </group>
+ </if>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locators-chapter">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <choose>
+ <if variable="page">
+ <group prefix=", ">
+ <text variable="volume" suffix=":"/>
+ <text variable="page"/>
+ </group>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locators-article">
+ <choose>
+ <if type="article-newspaper">
+ <group prefix=", " delimiter=", ">
+ <group>
+ <text variable="edition" suffix=" "/>
+ <text term="edition" prefix=" "/>
+ </group>
+ <group>
+ <text term="section" form="short" suffix=" "/>
+ <text variable="section"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="volume issue" match="any">
+ <text variable="page" prefix=": "/>
+ </if>
+ <else>
+ <text variable="page" prefix=", "/>
+ </else>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="point-locators">
+ <choose>
+ <if variable="locator">
+ <choose>
+ <if locator="page" match="none">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <choose>
+ <if variable="volume">
+ <group>
+ <text term="volume" form="short" suffix=" "/>
+ <number variable="volume" form="numeric"/>
+ <label variable="locator" form="short" prefix=", " suffix=" "/>
+ </group>
+ </if>
+ <else>
+ <label variable="locator" form="short" suffix=" "/>
+ </else>
+ </choose>
+ </if>
+ <else>
+ <label variable="locator" form="short" suffix=" "/>
+ </else>
+ </choose>
+ </if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <number variable="volume" form="numeric" suffix=":"/>
+ </else-if>
+ </choose>
+ <text variable="locator"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-prefix">
+ <text term="in" text-case="capitalize-first"/>
+ </macro>
+ <macro name="container-title">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text macro="container-prefix" suffix=" "/>
+ </if>
+ </choose>
+ <choose>
+ <if type="legal_case" match="none">
+ <text variable="container-title" text-case="title" font-style="italic"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </macro>
+ <macro name="date">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else-if variable="accessed">
+ <date variable="accessed">
+ <date-part name="year"/>
+ </date>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="day-month">
+ <date variable="issued">
+ <date-part name="month"/>
+ <date-part name="day" prefix=" "/>
+ </date>
+ </macro>
+ <macro name="collection-title">
+ <choose>
+ <if match="none" type="article-journal">
+ <choose>
+ <if match="none" is-numeric="collection-number">
+ <group delimiter=", ">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=" ">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number"/>
+ </group>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="collection-title-journal">
+ <choose>
+ <if type="article-journal">
+ <group delimiter=" ">
+ <text variable="collection-title"/>
+ <text variable="collection-number"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="event">
+ <group>
+ <text term="presented at" suffix=" "/>
+ <text variable="event"/>
+ </group>
+ </macro>
+ <macro name="description">
+ <choose>
+ <if type="interview">
+ <group delimiter=". ">
+ <text macro="interviewer"/>
+ <text variable="medium" text-case="capitalize-first"/>
+ </group>
+ </if>
+ <else>
+ <text variable="medium" text-case="capitalize-first" prefix=". "/>
+ </else>
+ </choose>
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis personal_communication speech" match="any"/>
+ <else>
+ <group delimiter=" " prefix=". ">
+ <text variable="genre" text-case="capitalize-first"/>
+ <choose>
+ <if type="report">
+ <text variable="number"/>
+ </if>
+ </choose>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue">
+ <choose>
+ <if type="legal_case">
+ <text variable="authority" prefix=". "/>
+ </if>
+ <else-if type="speech">
+ <group prefix=". " delimiter=", ">
+ <group delimiter=" ">
+ <text variable="genre" text-case="capitalize-first"/>
+ <text macro="event"/>
+ </group>
+ <text variable="event-place"/>
+ <text macro="day-month"/>
+ </group>
+ </else-if>
+ <else-if type="article-newspaper article-magazine personal_communication" match="any">
+ <text macro="day-month" prefix=", "/>
+ </else-if>
+ <else>
+ <group prefix=". " delimiter=", ">
+ <choose>
+ <if type="thesis">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ <text macro="publisher"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="1" disambiguate-add-year-suffix="true" disambiguate-add-names="true" disambiguate-add-givenname="true" givenname-disambiguation-rule="primary-name">
+ <layout prefix="(" suffix=")" delimiter="; ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text macro="contributors-short"/>
+ <text macro="date"/>
+ </group>
+ <text macro="point-locators"/>
+ </group>
+ </layout>
+ </citation>
+ <bibliography hanging-indent="true" et-al-min="11" et-al-use-first="7" subsequent-author-substitute="&#8212;&#8212;&#8212;" entry-spacing="0">
+ <sort>
+ <key macro="contributors"/>
+ <key variable="issued"/>
+ </sort>
+ <layout suffix=".">
+ <group delimiter=". ">
+ <text macro="contributors"/>
+ <text macro="date"/>
+ <text macro="title"/>
+ </group>
+ <text macro="description"/>
+ <text macro="secondary-contributors" prefix=". "/>
+ <text macro="container-title" prefix=". "/>
+ <text macro="container-contributors"/>
+ <text macro="edition"/>
+ <text macro="locators-chapter"/>
+ <text macro="collection-title-journal" prefix=", " suffix=", "/>
+ <text macro="locators"/>
+ <text macro="collection-title" prefix=". "/>
+ <text macro="issue"/>
+ <text macro="locators-article"/>
+ <text macro="access" prefix=". "/>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/jats.csl b/test/command/jats.csl
new file mode 100644
index 000000000..64872863c
--- /dev/null
+++ b/test/command/jats.csl
@@ -0,0 +1,208 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" default-locale="en-US">
+ <info>
+ <title>Journal Article Tag Suite</title>
+ <title-short>JATS</title-short>
+ <id>http://www.zotero.org/styles/journal-article-tag-suite</id>
+ <link href="https://github.com/MartinPaulEve/JATS-CSL/blob/master/jats.csl" rel="self"/>
+ <link rel="documentation" href="http://jats.nlm.nih.gov/archiving/tag-library/1.0/index.html"/>
+ <author>
+ <name>Martin Paul Eve</name>
+ <email>martin@martineve.com</email>
+ </author>
+ <category citation-format="numeric"/>
+ <category field="medicine"/>
+ <category field="biology"/>
+ <summary>Use this style to generate bibliographic data in Journal Article Tagging Suite (JATS) 1.0 XML format</summary>
+ <updated>2014-06-21T17:41:26+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License. Originally by Martin Fenner.</rights>
+ </info>
+ <locale xml:lang="en">
+ <terms>
+ <term name="et-al">{{jats}}&lt;etal/&gt;{{/jats}}</term>
+ </terms>
+ </locale>
+ <macro name="citation-number">
+ <text variable="citation-number" prefix="{{jats}}id=&quot;ref-{{/jats}}" suffix="{{jats}}&quot;&gt;{{/jats}}"/>
+ </macro>
+ <macro name="author">
+ <names variable="author">
+ <name prefix="{{jats}}&lt;name&gt;{{/jats}}" suffix="{{jats}}&lt;/name&gt;{{/jats}}" name-as-sort-order="all" sort-separator="">
+ <name-part name="family" text-case="capitalize-first" prefix="{{jats}}&lt;surname&gt;{{/jats}}" suffix="{{jats}}&lt;/surname&gt;{{/jats}}"/>
+ <name-part name="given" text-case="capitalize-first" prefix="{{jats}}&lt;given-names&gt;{{/jats}}" suffix="{{jats}}&lt;/given-names&gt;{{/jats}}"/>
+ </name>
+ <substitute>
+ <names variable="editor"/>
+ </substitute>
+ </names>
+ </macro>
+
+ <macro name="editor">
+ <names variable="editor" prefix="{{jats}}&lt;person-group person-group-type=&quot;editor&quot;&gt;{{/jats}}" suffix="{{jats}}&lt;/person-group&gt;{{/jats}}">
+ <name prefix="{{jats}}&lt;name&gt;{{/jats}}" suffix="{{jats}}&lt;/name&gt;{{/jats}}" name-as-sort-order="all" sort-separator="">
+ <name-part name="family" text-case="capitalize-first" prefix="{{jats}}&lt;surname&gt;{{/jats}}" suffix="{{jats}}&lt;/surname&gt;{{/jats}}"/>
+ <name-part name="given" text-case="capitalize-first" prefix="{{jats}}&lt;given-names&gt;{{/jats}}" suffix="{{jats}}&lt;/given-names&gt;{{/jats}}"/>
+ </name>
+ <substitute>
+ <names variable="editor"/>
+ </substitute>
+ </names>
+ </macro>
+
+ <macro name="editor">
+ <group delimiter=": ">
+ <names variable="editor">
+ <name prefix="{{jats}}&lt;name&gt;{{/jats}}" suffix="{{jats}}&lt;/name&gt;{{/jats}}" name-as-sort-order="all" sort-separator="">
+ <name-part name="family" text-case="capitalize-first" prefix="{{jats}}&lt;surname&gt;{{/jats}}" suffix="{{jats}}&lt;/surname&gt;{{/jats}}"/>
+ <name-part name="given" text-case="capitalize-first" prefix="{{jats}}&lt;given-names&gt;{{/jats}}" suffix="{{jats}}&lt;given-names&gt;{{/jats}}"/>
+ </name>
+ </names>
+ </group>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="book" match="any">
+ <group prefix="{{jats}}&lt;source&gt;{{/jats}}" suffix="{{jats}}&lt;/source&gt;{{/jats}}">
+ <text variable="title"/>
+ </group>
+ </if>
+ <else>
+ <group prefix="{{jats}}&lt;article-title&gt;{{/jats}}" suffix="{{jats}}&lt;/article-title&gt;{{/jats}}">
+ <text variable="title"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="container-title">
+ <text variable="container-title" form="short" prefix="{{jats}}&lt;source&gt;{{/jats}}" suffix="{{jats}}&lt;/source&gt;{{/jats}}"/>
+ </macro>
+ <macro name="publisher">
+ <text variable="publisher" prefix="{{jats}}&lt;publisher-name&gt;{{/jats}}" suffix="{{jats}}&lt;/publisher-name&gt;{{/jats}}"/>
+ <text variable="publisher-place" prefix="{{jats}}&lt;publisher-loc&gt;{{/jats}}" suffix="{{jats}}&lt;/publisher-loc&gt;{{/jats}}"/>
+ </macro>
+ <macro name="link">
+ <choose>
+ <if match="any" variable="DOI">
+ <group prefix="{{jats}}&lt;pub-id pub-id-type=&quot;doi&quot;&gt;{{/jats}}" suffix="{{jats}}&lt;/pub-id&gt;{{/jats}}">
+ <text variable="DOI"/>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if match="any" variable="PMID">
+ <group prefix="{{jats}}&lt;ext-link ext-link-type=&quot;pmid&quot; {{/jats}}" suffix="{{jats}}&lt;/ext-link&gt;{{/jats}}">
+ <text variable="PMID" prefix="{{jats}}xlink:href=&quot;http://www.ncbi.nlm.nih.gov/pubmed/{{/jats}}" suffix="{{jats}}&quot; xlink:type=&quot;simple&quot;&gt;{{/jats}}"/>
+ <text variable="PMID"/>
+ </group>
+ </if>
+ </choose>
+ <choose>
+ <if variable="URL" match="any">
+ <group prefix="{{jats}}&lt;ext-link ext-link-type=&quot;uri&quot; {{/jats}}" suffix="{{jats}}&lt;/ext-link&gt;{{/jats}}">
+ <text variable="URL" prefix="{{jats}}xlink:href=&quot;{{/jats}}" suffix="{{jats}}&quot; xlink:type=&quot;simple&quot;&gt;{{/jats}}"/>
+ <text variable="URL"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="date">
+ <choose>
+ <if type="article-journal article-magazine article-newspaper report patent book" match="any">
+ <group prefix="{{jats}}&lt;date&gt;{{/jats}}" suffix="{{jats}}&lt;/date&gt;{{/jats}}">
+ <date variable="issued">
+ <date-part name="day" form="numeric-leading-zeros" prefix="{{jats}}&lt;day&gt;{{/jats}}" suffix="{{jats}}&lt;/day&gt;{{/jats}}"/>
+ <date-part name="month" form="numeric-leading-zeros" prefix="{{jats}}&lt;month&gt;{{/jats}}" suffix="{{jats}}&lt;/month&gt;{{/jats}}"/>
+ <date-part name="year" prefix="{{jats}}&lt;year&gt;{{/jats}}" suffix="{{jats}}&lt;/year&gt;{{/jats}}"/>
+ </date>
+ </group>
+ </if>
+ <else>
+ <group prefix="{{jats}}&lt;date-in-citation content-type=&quot;access-date&quot;{{/jats}}" suffix="{{jats}}&lt;/date-in-citation&gt;{{/jats}}">
+ <date variable="accessed" prefix="{{jats}} iso-8601-date=&quot;{{/jats}}" suffix="{{jats}}&quot;&gt;{{/jats}}">
+ <date-part name="year"/>
+ <date-part name="month" form="numeric-leading-zeros" prefix="{{jats}}-{{/jats}}"/>
+ <date-part name="day" form="numeric-leading-zeros" prefix="{{jats}}-{{/jats}}"/>
+ </date>
+ <date variable="accessed">
+ <date-part name="day" prefix="{{jats}}&lt;day&gt;{{/jats}}" suffix="{{jats}}&lt;/day&gt;{{/jats}}"/>
+ <date-part name="month" form="numeric-leading-zeros" prefix="{{jats}}&lt;month&gt;{{/jats}}" suffix="{{jats}}&lt;/month&gt;{{/jats}}"/>
+ <date-part name="year" prefix="{{jats}}&lt;year&gt;{{/jats}}" suffix="{{jats}}&lt;/year&gt;{{/jats}}"/>
+ </date>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="location">
+ <choose>
+ <if type="article-journal article-magazine" match="any">
+ <text variable="volume" prefix="{{jats}}&lt;volume&gt;{{/jats}}" suffix="{{jats}}&lt;/volume&gt;{{/jats}}"/>
+ <text variable="issue" prefix="{{jats}}&lt;issue&gt;{{/jats}}" suffix="{{jats}}&lt;/issue&gt;{{/jats}}"/>
+ </if>
+ </choose>
+ <choose>
+ <if type="article-journal article-magazine article-newspaper chapter" match="any">
+ <text variable="page-first" prefix="{{jats}}&lt;fpage&gt;{{/jats}}" suffix="{{jats}}&lt;/fpage&gt;{{/jats}}"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="publication-type">
+ <group prefix="{{jats}} publication-type=&quot;{{/jats}}" suffix="{{jats}}&quot;&gt;{{/jats}}">
+ <choose>
+ <if type="article-journal article-magazine article-newspaper" match="any">
+ <text value="journal"/>
+ </if>
+ <else-if type="book" match="any">
+ <text value="book"/>
+ </else-if>
+ <else-if type="chapter" match="any">
+ <text value="bookchapter"/>
+ </else-if>
+ <else-if type="dataset" match="any">
+ <text value="dataset"/>
+ </else-if>
+ <else-if type="patent" match="any">
+ <text value="patent"/>
+ </else-if>
+ <else-if type="report" match="any">
+ <text value="report"/>
+ </else-if>
+ <else-if type="review" match="any">
+ <text value="review"/>
+ </else-if>
+ <else>
+ <text value="standard"/>
+ </else>
+ </choose>
+ </group>
+ </macro>
+ <citation collapse="citation-number">
+ <sort>
+ <key variable="citation-number"/>
+ </sort>
+ <layout delimiter=",">
+ <group prefix="{{jats}}&lt;xref ref-type=&quot;bibr&quot; rid=&quot;{{/jats}}" suffix="{{jats}}&lt;/xref&gt;{{/jats}}">
+ <text variable="citation-number" prefix="{{jats}}ref-{{/jats}}" suffix="{{jats}}&quot;&gt;{{/jats}}"/>
+ <text variable="citation-number"/>
+ </group>
+ </layout>
+ </citation>
+ <bibliography sort-separator="">
+ <layout>
+ <group prefix="{{jats}}&lt;ref {{/jats}}" suffix="{{jats}}&lt;/ref&gt;{{/jats}}">
+ <text macro="citation-number"/>
+ <group prefix="{{jats}}&lt;element-citation{{/jats}}" suffix="{{jats}}&lt;/element-citation&gt;{{/jats}}">
+ <text macro="publication-type"/>
+ <text macro="author" prefix="{{jats}}&lt;person-group person-group-type=&quot;author&quot;&gt;{{/jats}}" suffix="{{jats}}&lt;/person-group&gt;{{/jats}}"/>
+ <text macro="title" />
+ <text macro="container-title"/>
+ <text macro="editor"/>
+ <text macro="publisher"/>
+ <text macro="date"/>
+ <text macro="location"/>
+ <text macro="link"/>
+ </group>
+ </group>
+ </layout>
+ </bibliography>
+</style>
+
diff --git a/test/command/le-tapuscrit-note.csl b/test/command/le-tapuscrit-note.csl
new file mode 100644
index 000000000..b0680b44d
--- /dev/null
+++ b/test/command/le-tapuscrit-note.csl
@@ -0,0 +1,496 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" default-locale="fr-FR" version="1.0" page-range-format="expanded">
+ <info>
+ <title>Le tapuscrit (École des hautes études en sciences sociales) (note, French)</title>
+ <title-short>Tapuscrit-EHESS</title-short>
+ <id>http://www.zotero.org/styles/le-tapuscrit-note</id>
+ <link href="http://www.zotero.org/styles/le-tapuscrit-note" rel="self"/>
+ <link href="http://www.editions.ehess.fr/ouvrages/ouvrage/le-tapuscrit/" rel="documentation"/>
+ <author>
+ <name>Franziska Heimburger</name>
+ <email>zotero@franziska.fr</email>
+ </author>
+ <category citation-format="note"/>
+ <category field="social_science"/>
+ <category field="generic-base"/>
+ <updated>2018-07-12T11:20:37+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="fr">
+ <terms>
+ <term name="ordinal-01">ère</term>
+ <term name="ordinal-02">e</term>
+ <term name="ordinal-03">e</term>
+ <term name="ordinal-04">e</term>
+ <term name="cited">op.&#160;cit.</term>
+ <term name="page" form="short">p.</term>
+ <term name="editor" form="short">
+ <single>ed.</single>
+ <multiple>eds.</multiple>
+ </term>
+ <term name="in">dans</term>
+ </terms>
+ </locale>
+ <macro name="author">
+ <choose>
+ <if variable="author">
+ <names variable="author">
+ <name form="long" and="text" delimiter-precedes-last="never" sort-separator=" "/>
+ </names>
+ </if>
+ <else-if variable="editor">
+ <names variable="editor">
+ <name form="long" and="text" delimiter-precedes-last="never" sort-separator=" "/>
+ <label form="short" prefix="&#160;(" suffix=".)"/>
+ </names>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="author-bib">
+ <choose>
+ <if variable="author">
+ <names variable="author">
+ <name name-as-sort-order="all" form="long" and="text" delimiter-precedes-last="never" sort-separator=" ">
+ <name-part name="family" font-variant="small-caps"/>
+ </name>
+ </names>
+ </if>
+ <else-if variable="editor">
+ <names variable="editor">
+ <name name-as-sort-order="all" form="long" and="text" delimiter-precedes-last="never" sort-separator=" ">
+ <name-part name="family" font-variant="small-caps"/>
+ </name>
+ <label form="short" prefix="&#160;(" suffix=".)"/>
+ </names>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="author-ibid">
+ <choose>
+ <if variable="author">
+ <names variable="author">
+ <name and="text" initialize="true" initialize-with="." delimiter-precedes-last="never" sort-separator=" " font-style="normal"/>
+ </names>
+ </if>
+ <else-if variable="editor">
+ <names variable="editor">
+ <name form="long" and="text" delimiter-precedes-last="never" sort-separator=" "/>
+ <label form="short" prefix="&#160;(" suffix=".)"/>
+ </names>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="editor">
+ <names variable="editor">
+ <name form="long" and="text" delimiter-precedes-last="never" sort-separator=" "/>
+ <label form="short" prefix="&#160;(" suffix=".)"/>
+ </names>
+ </macro>
+ <macro name="translator">
+ <names variable="translator">
+ <name form="long" and="text" delimiter-precedes-last="never" sort-separator=" " prefix=" traduit par "/>
+ </names>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="bill book graphic legal_case motion_picture report song" match="any">
+ <text variable="title" text-case="capitalize-first" font-style="italic"/>
+ </if>
+ <else-if type="article-journal article-newspaper article-magazine" match="any">
+ <group delimiter=", ">
+ <text variable="title" text-case="capitalize-first" quotes="true"/>
+ <text variable="container-title" font-style="italic"/>
+ </group>
+ </else-if>
+ <else-if type="thesis" match="any">
+ <group delimiter="">
+ <text variable="title" text-case="capitalize-first" font-style="italic" suffix=","/>
+ <text variable="genre" suffix=", " prefix=" "/>
+ <text variable="publisher"/>
+ </group>
+ </else-if>
+ <else-if type="manuscript" match="any">
+ <group delimiter=",">
+ <text variable="title" text-case="capitalize-first" font-style="italic"/>
+ <text variable="genre" prefix=" [" suffix="]"/>
+ </group>
+ </else-if>
+ <else-if type="chapter entry-dictionary entry-encyclopedia" match="any">
+ <group delimiter="">
+ <text variable="title" text-case="capitalize-first" quotes="true"/>
+ <text value="dans" suffix=" " prefix=" "/>
+ <text macro="editor" suffix=", "/>
+ <text variable="container-title" text-case="capitalize-first" font-style="italic"/>
+ </group>
+ </else-if>
+ <else-if type="webpage post-weblog" match="any">
+ <group delimiter="">
+ <text variable="title" text-case="capitalize-first" font-style="italic" suffix=", "/>
+ <text variable="URL"/>
+ <group prefix=" , ">
+ <date variable="issued">
+ <date-part name="day" suffix=" "/>
+ <date-part name="month" suffix=" "/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </group>
+ </else-if>
+ <else>
+ <text variable="title" quotes="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="pub-place">
+ <choose>
+ <if type="bill book chapter entry-dictionary entry-encyclopedia thesis graphic legal_case manuscript motion_picture paper-conference report song" match="any">
+ <choose>
+ <if variable="publisher-place" match="any">
+ <text variable="publisher-place"/>
+ </if>
+ <else>
+ <text value="s.l."/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <if type="bill book chapter entry-dictionary entry-encyclopedia graphic legal_case motion_picture paper-conference report song" match="any">
+ <text variable="publisher"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="yearpage">
+ <choose>
+ <if type="bill book graphic legal_case motion_picture paper-conference manuscript report song thesis" match="any">
+ <group delimiter=", ">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ <group>
+ <text term="volume" form="short" suffix="."/>
+ <text variable="number-of-volumes" prefix=". " suffix="/"/>
+ <text variable="volume"/>
+ </group>
+ <choose>
+ <if variable="locator" match="any">
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else-if variable="locator" match="none">
+ <text variable="number-of-pages" suffix="&#160;p"/>
+ </else-if>
+ </choose>
+ </group>
+ </if>
+ <else-if type="chapter entry-dictionary entry-encyclopedia" match="any">
+ <group delimiter=" ">
+ <date variable="issued">
+ <date-part name="year" suffix=", "/>
+ </date>
+ <group>
+ <text term="volume" form="short" suffix="."/>
+ <text variable="number-of-volumes" prefix=". " suffix="/"/>
+ <text variable="volume" suffix=","/>
+ </group>
+ <choose>
+ <if variable="locator" match="any">
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else-if variable="locator" match="none">
+ <label variable="page" form="short"/>
+ <text variable="page"/>
+ </else-if>
+ </choose>
+ </group>
+ </else-if>
+ <else-if type="article-journal" match="any">
+ <group delimiter=" " font-style="normal">
+ <choose>
+ <if variable="locator" match="any">
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else-if variable="locator" match="none">
+ <label variable="page" form="short"/>
+ <text variable="page"/>
+ </else-if>
+ </choose>
+ </group>
+ </else-if>
+ <else-if type="article-newspaper article-magazine" match="any">
+ <date variable="issued">
+ <date-part name="day" suffix=" "/>
+ <date-part name="month" form="short" suffix=" "/>
+ <date-part name="year"/>
+ </date>
+ <group delimiter=" " font-style="normal">
+ <label variable="page" form="short"/>
+ <text variable="page"/>
+ </group>
+ <group delimiter=" " font-style="normal">
+ <choose>
+ <if variable="locator" match="any">
+ <group delimiter="&#8239;">
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else-if variable="locator" match="none">
+ <label variable="page" form="short"/>
+ </else-if>
+ </choose>
+ </group>
+ </else-if>
+ <else-if type="webpage post-weblog" match="any">
+ <group delimiter=" " prefix="(" suffix=")">
+ <text value="consulté le" suffix=" " prefix=" "/>
+ <date variable="accessed" form="text">
+ <date-part name="day"/>
+ <date-part name="month"/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="yearpage-bib">
+ <choose>
+ <if type="bill book graphic legal_case motion_picture paper-conference report song thesis" match="any">
+ <group delimiter=", ">
+ <group delimiter=", ">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ <group>
+ <text term="volume" form="short" suffix="."/>
+ <text variable="number-of-volumes" prefix=". " suffix="/"/>
+ <text variable="volume"/>
+ </group>
+ <text variable="number-of-pages" suffix="&#160;p"/>
+ </group>
+ <group>
+ <label variable="locator" form="short"/>
+ <text variable="locator"/>
+ </group>
+ </group>
+ </if>
+ <else-if type="chapter entry-dictionary entry-encyclopedia" match="any">
+ <group delimiter=", ">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ <group>
+ <text term="volume" form="short" suffix="."/>
+ <text variable="number-of-volumes" prefix=". " suffix="/"/>
+ <text variable="volume"/>
+ </group>
+ <group>
+ <label variable="page" form="short"/>
+ <text variable="page" prefix="&#160;"/>
+ </group>
+ </group>
+ </else-if>
+ <else-if type="article-journal chapter" match="any">
+ <group delimiter=" ">
+ <label variable="page" form="short"/>
+ <text variable="page"/>
+ </group>
+ </else-if>
+ <else-if type="article-newspaper article-magazine" match="any">
+ <group delimiter=" ">
+ <date variable="issued">
+ <date-part name="day" suffix=" "/>
+ <date-part name="month" form="short" suffix=" "/>
+ <date-part name="year"/>
+ </date>
+ <label variable="page" form="short"/>
+ <text variable="page"/>
+ </group>
+ </else-if>
+ <else-if type="manuscript">
+ <group delimiter="" font-style="normal">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="day" suffix=" "/>
+ <date-part name="month" suffix=" "/>
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else>
+ <text value="s. d."/>
+ </else>
+ </choose>
+ </group>
+ </else-if>
+ <else-if type="webpage post-weblog" match="any">
+ <group delimiter=" ">
+ <text value="consulté le" suffix=" " prefix=" "/>
+ <date variable="accessed" form="text">
+ <date-part name="day"/>
+ <date-part name="month"/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if type="bill book graphic legal_case motion_picture report song chapter paper-conference" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" text-case="capitalize-first" suffix="."/>
+ </else>
+ </choose>
+ </if>
+ <else-if type="article-journal article-magazine" match="any">
+ <group delimiter="">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="day" suffix=" "/>
+ <date-part name="month" suffix=" "/>
+ <date-part name="year"/>
+ </date>
+ <text macro="volume" prefix=", "/>
+ </if>
+ <else>
+ <text macro="volume" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </group>
+ </else-if>
+ </choose>
+ <text macro="issue" prefix=", "/>
+ </macro>
+ <macro name="volume">
+ <choose>
+ <if is-numeric="volume">
+ <text term="volume" form="short" suffix=".&#160;"/>
+ <text variable="volume"/>
+ </if>
+ <else>
+ <text variable="volume"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="issue">
+ <choose>
+ <if is-numeric="issue">
+ <text term="issue" form="short" suffix="&#160;"/>
+ <text variable="issue"/>
+ </if>
+ <else>
+ <text variable="issue"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="collection">
+ <text variable="collection-title" quotes="true" prefix=" (coll.&#160;" suffix=")"/>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="1">
+ <layout suffix="." delimiter="&#160;; ">
+ <choose>
+ <if position="ibid-with-locator">
+ <group delimiter=", ">
+ <text term="ibid" text-case="capitalize-first" font-style="italic" suffix="."/>
+ <text variable="locator" prefix="p.&#160;"/>
+ </group>
+ </if>
+ <else-if position="ibid">
+ <text term="ibid" text-case="capitalize-first" font-style="italic"/>
+ </else-if>
+ <else-if position="subsequent">
+ <group delimiter=", ">
+ <text macro="author-ibid"/>
+ <choose>
+ <if type="bill book graphic legal_case motion_picture report song thesis manuscript" match="any">
+ <text variable="title" form="short" font-style="italic"/>
+ <text term="cited" font-style="italic" suffix="."/>
+ </if>
+ <else>
+ <text variable="title" text-case="capitalize-first" form="short" quotes="true"/>
+ <text value="art cit"/>
+ </else>
+ </choose>
+ <text variable="locator" prefix="p.&#160;"/>
+ </group>
+ </else-if>
+ <else>
+ <choose>
+ <if type="manuscript">
+ <group delimiter=", ">
+ <text variable="archive"/>
+ <text variable="archive_location"/>
+ <text variable="call-number"/>
+ <text macro="title"/>
+ <text macro="yearpage-bib"/>
+ </group>
+ </if>
+ <else-if type="bill chapter article-journal article-newspaper interview book graphic legal_case motion_picture paper-conference report song thesis webpage post-weblog article-magazine" match="any">
+ <group delimiter=", ">
+ <text macro="author"/>
+ <text macro="title"/>
+ <text macro="translator"/>
+ <text macro="edition"/>
+ <text macro="pub-place"/>
+ <text macro="publisher"/>
+ <text macro="yearpage"/>
+ </group>
+ </else-if>
+ </choose>
+ </else>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography>
+ <sort>
+ <key macro="author" names-min="3" names-use-first="3"/>
+ <key variable="issued" sort="descending"/>
+ </sort>
+ <layout suffix=".">
+ <choose>
+ <if type="manuscript">
+ <group delimiter=", ">
+ <text variable="archive"/>
+ <text variable="archive_location"/>
+ <text variable="call-number"/>
+ <text macro="title"/>
+ <text macro="yearpage-bib"/>
+ </group>
+ </if>
+ <else-if type="bill chapter article-journal article-newspaper interview book graphic legal_case motion_picture paper-conference report song thesis webpage post-weblog article-magazine" match="any">
+ <group delimiter=", ">
+ <text macro="author-bib"/>
+ <text macro="title"/>
+ <text macro="translator"/>
+ <text macro="edition"/>
+ <text macro="pub-place"/>
+ <group delimiter=" ">
+ <text macro="publisher"/>
+ <text macro="collection"/>
+ </group>
+ <text macro="yearpage-bib"/>
+ </group>
+ </else-if>
+ </choose>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/locators.csl b/test/command/locators.csl
new file mode 100644
index 000000000..610ac5bd4
--- /dev/null
+++ b/test/command/locators.csl
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" version="1.0" demote-non-dropping-particle="sort-only" default-locale="en-GB">
+ <info>
+ <title>A CSL to test locator parsing in pandoc-citeproc</title>
+ <title-short>test-locators</title-short>
+ <id>https://example.com/test-locators</id>
+ <link href="https://forums.zotero.org/discussion/4841/new-australian-legal-citation-style/?Focus=20831#Comment_20831" rel="documentation"/>
+ <category citation-format="note"/>
+ </info>
+
+ <locale>
+ <terms>
+ <term name="section" form="short">
+ <single>s</single>
+ <multiple>ss</multiple>
+ </term>
+ </terms>
+ </locale>
+
+ <macro name="locator">
+ <choose>
+ <if locator="section">
+ <!-- s or ss -->
+ <group delimiter=" " prefix=" ">
+ <label variable="locator" form="short" />
+ <text variable="locator" prefix="{" suffix="}" />
+ </group>
+ </if>
+ <else>
+ <text variable="locator" prefix=" {" suffix="}" />
+ </else>
+ </choose>
+ </macro>
+
+ <macro name="title">
+ <text variable="title" suffix=" "/>
+ </macro>
+
+ <citation>
+ <layout prefix="" suffix="." delimiter="; ">
+ <choose>
+ <if position="ibid-with-locator">
+ <text value="ibid-with-locator"/>
+ <text macro="locator"/>
+ </if>
+ <else-if position="ibid">
+ <text value="ibid"/>
+ </else-if>
+ <else-if position="subsequent">
+ <text value="subsequent"/>
+ <text macro="locator"/>
+ </else-if>
+ <else>
+ <text macro="title" />
+ <text macro="locator" />
+ </else>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography>
+ <sort>
+ <key variable="issued"/>
+ </sort>
+ <layout>
+ <text variable="title" />
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/modern-humanities-research-association.csl b/test/command/modern-humanities-research-association.csl
new file mode 100644
index 000000000..abdef0dd8
--- /dev/null
+++ b/test/command/modern-humanities-research-association.csl
@@ -0,0 +1,445 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" version="1.0" demote-non-dropping-particle="sort-only" default-locale="en-GB">
+ <info>
+ <title>Modern Humanities Research Association (note with bibliography)</title>
+ <id>http://www.zotero.org/styles/modern-humanities-research-association</id>
+ <link href="http://www.zotero.org/styles/modern-humanities-research-association" rel="self"/>
+ <link href="http://www.mhra.org.uk/Publications/Books/StyleGuide/download.shtml" rel="documentation"/>
+ <author>
+ <name>Rintze Zelle</name>
+ <uri>http://twitter.com/rintzezelle</uri>
+ </author>
+ <contributor>
+ <name>Sebastian Karcher</name>
+ </contributor>
+ <category citation-format="note"/>
+ <category field="generic-base"/>
+ <summary>MHRA format with full notes and bibliography</summary>
+ <updated>2013-04-16T04:40:01+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en">
+ <terms>
+ <term name="et-al">and others</term>
+ <term name="editor" form="verb-short">ed. by</term>
+ <term name="edition" form="short">edn</term>
+ <term name="translator" form="verb-short">trans. by</term>
+ </terms>
+ </locale>
+ <macro name="author">
+ <group delimiter=". ">
+ <names variable="author">
+ <name name-as-sort-order="first" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", " suffix="."/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title-note"/>
+ </substitute>
+ </names>
+ <text macro="recipient"/>
+ </group>
+ </macro>
+ <macro name="recipient">
+ <group delimiter=" ">
+ <choose>
+ <if type="personal_communication">
+ <choose>
+ <if variable="genre">
+ <text variable="genre" text-case="capitalize-first"/>
+ </if>
+ <else>
+ <text term="letter" text-case="capitalize-first"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ <text macro="recipient-note"/>
+ </group>
+ </macro>
+ <macro name="contributors-note">
+ <names variable="author">
+ <name and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="never"/>
+ <label form="short" prefix=", "/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title-note"/>
+ </substitute>
+ </names>
+ <text macro="recipient-note"/>
+ </macro>
+ <macro name="title-note">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <text variable="title" font-style="italic" text-case="title"/>
+ </if>
+ <else>
+ <text variable="title" quotes="true" text-case="title"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="disambiguate">
+ <choose>
+ <if disambiguate="true">
+ <choose>
+ <if variable="title" match="none">
+ <text macro="issued"/>
+ </if>
+ <else-if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <text variable="title" font-style="italic" text-case="title" form="short"/>
+ </else-if>
+ <else>
+ <text variable="title" quotes="true" text-case="title" form="short"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="title-sort-substitute">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <text variable="title" font-style="italic" text-case="title" form="short"/>
+ </if>
+ <else>
+ <text variable="title" quotes="true" text-case="title" form="short"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="editor-translator">
+ <group delimiter=", ">
+ <choose>
+ <if variable="author">
+ <group delimiter=" ">
+ <choose>
+ <if variable="container-author">
+ <group>
+ <names variable="container-author">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </group>
+ </if>
+ </choose>
+ </group>
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb-short" text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </if>
+ </choose>
+ </group>
+ </macro>
+ <macro name="collection-title">
+ <text variable="collection-title" text-case="title"/>
+ <text variable="collection-number" prefix=", "/>
+ </macro>
+ <macro name="locators-note">
+ <choose>
+ <if type="article-journal">
+ <text variable="volume"/>
+ </if>
+ <else-if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <group delimiter=", ">
+ <text macro="edition-note"/>
+ <group>
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" prefix=" " plural="true"/>
+ </group>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="volume">
+ <choose>
+ <if type="article-journal">
+ <text variable="volume"/>
+ </if>
+ <else-if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <group delimiter=", ">
+ <text macro="edition-note"/>
+ <group>
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" prefix=" " plural="true"/>
+ </group>
+ </group>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="issue-note">
+ <choose>
+ <if type="article-journal">
+ <choose>
+ <if variable="volume">
+ <text macro="issued" prefix=" (" suffix=")"/>
+ </if>
+ <else>
+ <text macro="issued" prefix=", "/>
+ </else>
+ </choose>
+ </if>
+ <else-if variable="publisher-place publisher" match="any">
+ <group prefix=" (" suffix=")" delimiter=", ">
+ <group delimiter=" ">
+ <choose>
+ <if variable="title" match="none"/>
+ <else-if type="thesis speech" match="any">
+ <text variable="genre" prefix="unpublished "/>
+ </else-if>
+ </choose>
+ <text macro="event"/>
+ </group>
+ <text macro="publisher"/>
+ <text macro="issued"/>
+ </group>
+ </else-if>
+ <else>
+ <text macro="issued" prefix=", "/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="locators-specific-note">
+ <choose>
+ <if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <choose>
+ <if is-numeric="volume">
+ <number variable="volume" form="roman" font-variant="small-caps"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-title-note">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text term="in" text-case="lowercase" suffix=" "/>
+ </if>
+ </choose>
+ <text variable="container-title" font-style="italic"/>
+ </macro>
+ <macro name="edition-note">
+ <choose>
+ <if type="bill book chapter graphic legal_case legislation motion_picture paper-conference report song" match="any">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition"/>
+ </else>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="editor-note">
+ <names variable="editor">
+ <name and="text" sort-separator=", " delimiter=", "/>
+ <label form="short" prefix=", " suffix="."/>
+ </names>
+ </macro>
+ <macro name="translator-note">
+ <names variable="translator">
+ <name and="text" sort-separator=", " delimiter=", "/>
+ <label form="verb-short" prefix=", " suffix="."/>
+ </names>
+ </macro>
+ <macro name="recipient-note">
+ <names variable="recipient" delimiter=", ">
+ <label form="verb" prefix=" " text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="recipient-short">
+ <names variable="recipient">
+ <label form="verb" prefix=" " text-case="lowercase" suffix=" "/>
+ <name form="short" and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="contributors-short">
+ <names variable="author">
+ <name form="short" and="text" sort-separator=", " delimiter=", " delimiter-precedes-last="never"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title-sort-substitute"/>
+ </substitute>
+ </names>
+ <text macro="recipient-short"/>
+ </macro>
+ <macro name="interviewer-note">
+ <names variable="interviewer" delimiter=", ">
+ <label form="verb" prefix=" " text-case="lowercase" suffix=" "/>
+ <name and="text" delimiter=", "/>
+ </names>
+ </macro>
+ <macro name="locators-newspaper">
+ <choose>
+ <if type="article-newspaper">
+ <group delimiter=", ">
+ <group>
+ <text variable="edition" suffix=" "/>
+ <text term="edition" prefix=" "/>
+ </group>
+ <group>
+ <text term="section" suffix=" "/>
+ <text variable="section"/>
+ </group>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="event">
+ <group>
+ <text term="presented at" suffix=" "/>
+ <text variable="event"/>
+ </group>
+ </macro>
+ <macro name="publisher">
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </macro>
+ <macro name="issued">
+ <choose>
+ <if type="graphic report article-newspaper article-magazine personal_communication" match="any">
+ <date variable="issued">
+ <date-part name="day" suffix=" "/>
+ <date-part name="month" suffix=" "/>
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else>
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </else>
+ </choose>
+ </macro>
+ <macro name="pages">
+ <choose>
+ <if type="article-journal">
+ <text variable="page" prefix=", "/>
+ </if>
+ <else>
+ <choose>
+ <if variable="volume">
+ <text variable="page" prefix=", "/>
+ </if>
+ <else>
+ <label variable="page" form="short" prefix=", " suffix=" "/>
+ <text variable="page"/>
+ </else>
+ </choose>
+ </else>
+ </choose>
+ </macro>
+ <macro name="point-locators">
+ <text macro="pages"/>
+ <choose>
+ <if variable="page">
+ <group prefix=" (" suffix=")">
+ <label variable="locator" form="short" suffix=" "/>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else>
+ <label variable="locator" form="short" prefix=", " suffix=" "/>
+ <text variable="locator"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="point-locators-subsequent">
+ <label variable="locator" form="short" prefix=", " suffix=" "/>
+ <text variable="locator"/>
+ </macro>
+ <macro name="archive-note">
+ <group delimiter=", ">
+ <text variable="archive_location"/>
+ <text variable="archive"/>
+ <text variable="archive-place"/>
+ </group>
+ </macro>
+ <macro name="access-note">
+ <group delimiter=", ">
+ <choose>
+ <if type="article-journal bill chapter legal_case legislation paper-conference" match="none">
+ <text macro="archive-note" prefix=", "/>
+ </if>
+ </choose>
+ </group>
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix=" &lt;doi:" suffix="&gt;"/>
+ </if>
+ <else>
+ <choose>
+ <if variable="URL">
+ <text variable="URL" prefix=" &lt;" suffix="&gt;"/>
+ <group prefix=" [" suffix="]">
+ <text term="accessed" text-case="lowercase"/>
+ <date variable="accessed">
+ <date-part name="day" prefix=" "/>
+ <date-part name="month" prefix=" "/>
+ <date-part name="year" prefix=" "/>
+ </date>
+ </group>
+ </if>
+ </choose>
+ </else>
+ </choose>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="1" disambiguate-add-names="true" disambiguate-add-givenname="true">
+ <layout prefix="" suffix="." delimiter="; ">
+ <choose>
+ <if position="subsequent">
+ <group delimiter=", ">
+ <text macro="contributors-short"/>
+ <text macro="disambiguate"/>
+ <text macro="locators-specific-note"/>
+ </group>
+ <text macro="point-locators-subsequent"/>
+ </if>
+ <else>
+ <group delimiter=", ">
+ <text macro="contributors-note"/>
+ <text macro="title-note"/>
+ <text macro="container-title-note"/>
+ <text macro="editor-translator"/>
+ <text macro="collection-title"/>
+ <text macro="locators-note"/>
+ </group>
+ <text macro="issue-note"/>
+ <text macro="locators-specific-note" prefix=", "/>
+ <text macro="locators-newspaper" prefix=", "/>
+ <text macro="point-locators"/>
+ <text macro="access-note"/>
+ </else>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography hanging-indent="true" et-al-min="7" et-al-use-first="6" subsequent-author-substitute="---">
+ <sort>
+ <key macro="author"/>
+ <key variable="title"/>
+ </sort>
+ <layout>
+ <group delimiter=", ">
+ <text macro="author"/>
+ <text macro="title-note"/>
+ <text macro="container-title-note"/>
+ <text macro="editor-translator"/>
+ <text macro="collection-title"/>
+ <text macro="volume"/>
+ </group>
+ <text macro="issue-note"/>
+ <text macro="locators-specific-note" prefix=", "/>
+ <text macro="locators-newspaper" prefix=", "/>
+ <text macro="pages"/>
+ <text macro="access-note"/>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/oscola.csl b/test/command/oscola.csl
new file mode 100644
index 000000000..8ff736119
--- /dev/null
+++ b/test/command/oscola.csl
@@ -0,0 +1,680 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" version="1.0" demote-non-dropping-particle="never" default-locale="en-GB">
+ <info>
+ <title>OSCOLA (Oxford University Standard for Citation of Legal Authorities)</title>
+ <title-short>OSCOLA</title-short>
+ <id>http://www.zotero.org/styles/oscola</id>
+ <link href="http://www.zotero.org/styles/oscola" rel="self"/>
+ <link href="http://www.zotero.org/styles/australian-guide-to-legal-citation" rel="template"/>
+ <link href="http://www.law.ox.ac.uk/publications/oscola.php" rel="documentation"/>
+ <author>
+ <name>Sebastian Karcher</name>
+ </author>
+ <category citation-format="note"/>
+ <category field="law"/>
+ <summary>The OSCOLA Standards. For a Zotero Group showing data-entry in Zotero see: https://www.zotero.org/groups/oscola_samples/items/order/itemType</summary>
+ <updated>2013-11-15T01:14:57+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale>
+ <terms>
+ <term name="chapter" form="short">
+ <single>ch.</single>
+ <multiple>chs.</multiple>
+ </term>
+ <term name="section" form="short">
+ <single>s</single>
+ <multiple>ss</multiple>
+ </term>
+ <term name="paragraph" form="short">
+ <single>para</single>
+ <multiple>paras</multiple>
+ </term>
+ <term name="translator" form="short">
+ <single>tr.</single>
+ <multiple>trs.</multiple>
+ </term>
+ <term name="edition" form="short">edn.</term>
+ <term name="et-al">and others</term>
+ </terms>
+ </locale>
+ <!--Authors and Persons-->
+ <macro name="author-note">
+ <!--for bills & hearing this should start with jurisdiction once available-->
+ <choose>
+ <if type="interview">
+ <group delimiter=", ">
+ <names variable="interviewer">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ </names>
+ <names variable="author" prefix="Interview with ">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ </names>
+ </group>
+ </if>
+ <else-if type="personal_communication">
+ <group delimiter=" ">
+ <group delimiter=" from ">
+ <text variable="genre"/>
+ <names variable="author">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ </names>
+ </group>
+ <names variable="recipient" prefix="to ">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ </names>
+ </group>
+ </else-if>
+ <else-if type="broadcast">
+ <text variable="publisher"/>
+ </else-if>
+ <else-if type="legal_case legislation" match="any"/>
+ <else>
+ <names variable="author">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ <label form="short" prefix=" (" suffix=")" strip-periods="true"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </else>
+ </choose>
+ </macro>
+ <macro name="author-short">
+ <choose>
+ <if type="interview">
+ <group delimiter=", ">
+ <names variable="interviewer">
+ <name delimiter-precedes-last="never" and="text" form="short" delimiter=", " initialize="false" initialize-with=""/>
+ </names>
+ <names variable="author" prefix="Interview with ">
+ <name delimiter-precedes-last="never" and="text" form="short" delimiter=", " initialize="false" initialize-with=""/>
+ </names>
+ </group>
+ </if>
+ <else-if type="personal_communication">
+ <group delimiter=" ">
+ <group delimiter=" from ">
+ <text variable="genre"/>
+ <names variable="author">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " form="short" initialize="false" initialize-with=""/>
+ </names>
+ </group>
+ <names variable="recipient" prefix="to ">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" form="short" initialize-with=""/>
+ </names>
+ </group>
+ </else-if>
+ <else-if type="broadcast">
+ <text variable="publisher"/>
+ </else-if>
+ <else>
+ <names variable="author">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with="" form="short"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </else>
+ </choose>
+ </macro>
+ <macro name="author">
+ <!--for bills & hearing this should start with jurisdiction once available-->
+ <choose>
+ <if type="interview">
+ <group delimiter=", ">
+ <names variable="interviewer">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize-with="" name-as-sort-order="all" sort-separator=" "/>
+ </names>
+ <names variable="author" prefix="Interview with ">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ </names>
+ </group>
+ </if>
+ <else-if type="personal_communication">
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <names variable="author">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize-with="" name-as-sort-order="all" sort-separator=" "/>
+ </names>
+ <text variable="genre"/>
+ </group>
+ <names variable="recipient" prefix="to ">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ </names>
+ </group>
+ </else-if>
+ <else-if type="broadcast">
+ <text variable="publisher"/>
+ </else-if>
+ <else-if type="legal_case legislation" match="any"/>
+ <else>
+ <names variable="author">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " name-as-sort-order="all" initialize-with="" sort-separator=" "/>
+ <label form="short" prefix=" (" suffix=")" strip-periods="true"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </else>
+ </choose>
+ </macro>
+ <macro name="editor">
+ <choose>
+ <if type="chapter paper-conference entry-encyclopedia" match="none">
+ <names variable="editor translator container-author" delimiter=", ">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ <label form="short" prefix=" " strip-periods="true"/>
+ </names>
+ </if>
+ </choose>
+ </macro>
+ <macro name="editor-chapter">
+ <group>
+ <text term="in" suffix=" "/>
+ <names variable="editor translator container-author" delimiter=", ">
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ <label form="short" prefix=" (" suffix=")" strip-periods="true"/>
+ </names>
+ </group>
+ </macro>
+ <!-- Titles -->
+ <macro name="title">
+ <choose>
+ <if type="book motion_picture treaty" match="any">
+ <text variable="title" font-style="italic" text-case="title"/>
+ </if>
+ <else-if type="bill legislation" match="any">
+ <text variable="title"/>
+ </else-if>
+ <else-if type="legal_case">
+ <text variable="title" font-style="italic" strip-periods="true"/>
+ </else-if>
+ <else>
+ <text variable="title" quotes="true" text-case="title"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title-short">
+ <choose>
+ <if type="book motion_picture treaty" match="any">
+ <text variable="title" font-style="italic" text-case="title" form="short"/>
+ </if>
+ <else-if type="bill legislation" match="any">
+ <text variable="title" form="short"/>
+ </else-if>
+ <else-if type="legal_case">
+ <choose>
+ <if variable="title-short">
+ <text variable="title-short" font-style="italic"/>
+ </if>
+ <else>
+ <text variable="title" font-style="italic"/>
+ </else>
+ </choose>
+ </else-if>
+ <else>
+ <text variable="title" quotes="true" text-case="title" form="short"/>
+ </else>
+ </choose>
+ </macro>
+ <!--Dates-->
+ <macro name="issued-year">
+ <date variable="issued" form="text" date-parts="year"/>
+ </macro>
+ <macro name="issued-full">
+ <date variable="issued" form="text"/>
+ </macro>
+ <macro name="date-parenthesis">
+ <choose>
+ <if type="legal_case article-journal article-magazine" match="any">
+ <choose>
+ <if variable="number authority" match="all">
+ <text macro="issued-year" prefix="[" suffix="]"/>
+ </if>
+ <else-if variable="volume">
+ <text macro="issued-year" prefix="(" suffix=")"/>
+ </else-if>
+ <else-if variable="container-title volume number" match="any">
+ <!--no year in square brackets for unreported case w/o medium neutral citation-->
+ <text macro="issued-year" prefix="[" suffix="]"/>
+ </else-if>
+ </choose>
+ </if>
+ <else-if type="legislation bill" match="any">
+ <text macro="issued-year"/>
+ </else-if>
+ </choose>
+ </macro>
+ <!--publication info -->
+ <macro name="publisher">
+ <choose>
+ <if type="book chapter broadcast personal_communication manuscript paper-conference article-newspaper report legislation motion_picture speech interview thesis entry-encyclopedia webpage post-weblog" match="any">
+ <group delimiter=" ">
+ <group prefix="(" suffix=")" delimiter=", ">
+ <choose>
+ <if type="article-newspaper">
+ <text variable="publisher-place" strip-periods="true"/>
+ <date variable="issued" form="text"/>
+ </if>
+ <else-if type="broadcast personal_communication treaty" match="any">
+ <date variable="issued" form="text"/>
+ </else-if>
+ <else-if type="legislation bill" match="any">
+ <!--this should be jurisdiction we use code instead-->
+ <text variable="container-title" strip-periods="true"/>
+ </else-if>
+ <else>
+ <!--this won't work in Zotero yet, but does no harm -->
+ <names variable="director">
+ <label form="verb" text-case="capitalize-first" suffix=" "/>
+ <name delimiter-precedes-last="never" and="text" delimiter=", " initialize="false" initialize-with=""/>
+ </names>
+ <text macro="editor"/>
+ <choose>
+ <!--if none of these, this we don't want edition either. Might be Loose-Leaf-->
+ <if variable="publisher issued genre container-title" match="any">
+ <text macro="edition"/>
+ </if>
+ </choose>
+ <choose>
+ <if type="speech">
+ <text variable="event"/>
+ <text variable="event-place"/>
+ <text macro="issued-full"/>
+ </if>
+ <else-if type="thesis" match="any">
+ <text variable="genre" strip-periods="true"/>
+ <group delimiter=" ">
+ <text variable="publisher" strip-periods="true"/>
+ <text macro="issued-year"/>
+ </group>
+ </else-if>
+ <else-if type="webpage post-weblog" match="any">
+ <text variable="container-title" font-style="italic"/>
+ <text macro="issued-full"/>
+ </else-if>
+ <else-if type="interview" match="any">
+ <text macro="issued-full"/>
+ </else-if>
+ <else>
+ <group delimiter=" ">
+ <text variable="publisher" strip-periods="true"/>
+ <text macro="issued-year"/>
+ </group>
+ </else>
+ </choose>
+ </else>
+ </choose>
+ </group>
+ <choose>
+ <if type="report interview manuscript" match="any">
+ <group delimiter=" ">
+ <text variable="genre" strip-periods="true"/>
+ <text variable="number"/>
+ </group>
+ </if>
+ </choose>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="looseleaf-note">
+ <choose>
+ <if type="book">
+ <choose>
+ <if variable="publisher issued" match="none">
+ <choose>
+ <if variable="locator">
+ <group delimiter=" ">
+ <label variable="locator" form="short" strip-periods="true"/>
+ <text variable="locator"/>
+ <text variable="edition" prefix="(" suffix=")"/>
+ </group>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="volume-book">
+ <choose>
+ <if type="book chapter report" match="any">
+ <group delimiter=" ">
+ <label variable="volume" form="short" strip-periods="true"/>
+ <text variable="volume"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <label variable="edition" form="short" strip-periods="true"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" strip-periods="true"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="book-container">
+ <choose>
+ <if type="chapter paper-conference entry-encyclopedia" match="any">
+ <group>
+ <text macro="editor-chapter" prefix=" "/>
+ <text variable="container-title" font-style="italic" prefix=", "/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="broadcast-container">
+ <choose>
+ <if type="broadcast" match="any">
+ <text variable="container-title" font-style="italic"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="bill-number">
+ <choose>
+ <if type="bill">
+ <text variable="number" prefix="[" suffix="]"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="article-case-info">
+ <choose>
+ <if type="article-journal article-magazine article-newspaper legal_case" match="any">
+ <group delimiter=", ">
+ <!--Assume that only cases with a Medium Neutral Citation have a docket number -->
+ <choose>
+ <if variable="authority number" match="all">
+ <group delimiter=" ">
+ <text variable="authority" form="short" strip-periods="true"/>
+ <text variable="number"/>
+ </group>
+ </if>
+ </choose>
+ <group delimiter=" ">
+ <text variable="volume"/>
+ <choose>
+ <if type="legal_case">
+ <choose>
+ <if variable="container-title">
+ <text variable="container-title" form="short" strip-periods="true"/>
+ </if>
+ </choose>
+ </if>
+ <else-if type="article-magazine article-newspaper" match="any">
+ <text variable="container-title" font-style="italic"/>
+ </else-if>
+ <else>
+ <text variable="container-title"/>
+ </else>
+ </choose>
+ </group>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="page-first">
+ <choose>
+ <if type="chapter report paper-conference" match="none">
+ <text variable="page-first"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="court">
+ <choose>
+ <if type="legal_case">
+ <choose>
+ <if variable="number" match="none">
+ <text variable="authority" prefix="(" suffix=")" strip-periods="true"/>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="locator-basic">
+ <group delimiter=" ">
+ <choose>
+ <if locator="page" match="none">
+ <label variable="locator" form="short" strip-periods="true"/>
+ </if>
+ </choose>
+ <text variable="locator"/>
+ </group>
+ </macro>
+ <macro name="locator-space">
+ <choose>
+ <if type="legal_case">
+ <choose>
+ <if locator="paragraph">
+ <text variable="locator" prefix="[" suffix="]"/>
+ </if>
+ <else-if variable="number container-title volume page" match="all"/>
+ <else-if variable="authority">
+ <text variable="locator"/>
+ </else-if>
+ </choose>
+ </if>
+ <else-if type="legislation book article-journal article-magazine" match="none">
+ <text macro="locator-basic"/>
+ </else-if>
+ <else-if type="book">
+ <choose>
+ <if variable="issued publisher" match="any">
+ <text macro="locator-basic"/>
+ </if>
+ </choose>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="locator-comma">
+ <choose>
+ <if type="legal_case">
+ <choose>
+ <if locator="paragraph" match="none">
+ <choose>
+ <if variable="authority" match="none">
+ <text variable="locator"/>
+ </if>
+ <else-if variable="number container-title volume page" match="all">
+ <text variable="locator"/>
+ </else-if>
+ </choose>
+ </if>
+ </choose>
+ </if>
+ <else-if type="legislation article-journal article-magazine" match="any">
+ <text macro="locator-basic"/>
+ </else-if>
+ </choose>
+ </macro>
+ <!--Others -->
+ <macro name="treaty-catchall">
+ <choose>
+ <if type="treaty">
+ <text variable="genre"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="URL">
+ <choose>
+ <if type="legal_case legislation bill" match="none">
+ <choose>
+ <if variable="URL">
+ <group delimiter=" ">
+ <text variable="URL" prefix="&lt;" suffix="&gt;"/>
+ <group delimiter=" ">
+ <text term="accessed"/>
+ <date variable="accessed" form="text"/>
+ </group>
+ </group>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="author-count">
+ <names variable="author">
+ <name form="count"/>
+ <substitute>
+ <names variable="editor"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="sort-type">
+ <!--This should just sort secondary sources first. I'm leaving the rest from AGLC for simplicity-->
+ <choose>
+ <if type="book chapter paper-conference article-magazine article-newspaper article-journal manuscript report speech entry-encyclopedia" match="any">
+ <text value="1"/>
+ </if>
+ <else-if type="legal_case">
+ <text value="2"/>
+ <text variable="title"/>
+ </else-if>
+ <else-if type="bill legislation" match="any">
+ <text value="3"/>
+ <choose>
+ <if type="legislation">
+ <text variable="title"/>
+ </if>
+ </choose>
+ </else-if>
+ <else-if type="treaty">
+ <text value="4"/>
+ </else-if>
+ <else>
+ <text value="1"/>
+ </else>
+ </choose>
+ </macro>
+ <citation et-al-min="4" et-al-use-first="1">
+ <layout suffix="." delimiter="; ">
+ <choose>
+ <if position="ibid-with-locator">
+ <group delimiter=" ">
+ <text term="ibid" strip-periods="true" text-case="lowercase"/>
+ <text variable="locator"/>
+ </group>
+ </if>
+ <else-if position="ibid">
+ <text term="ibid" strip-periods="true" text-case="lowercase"/>
+ </else-if>
+ <else-if position="subsequent">
+ <choose>
+ <if type="legal_case bill legislation treaty" match="any">
+ <!--don't use short form and above note for legal citations -->
+ <group delimiter=" ">
+ <text macro="author-note"/>
+ <text macro="title-short"/>
+ <text macro="looseleaf-note"/>
+ <text variable="first-reference-note-number" prefix="(n " suffix=")"/>
+ <text macro="locator-space"/>
+ </group>
+ </if>
+ <else>
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <text macro="author-short"/>
+ <choose>
+ <if disambiguate="true">
+ <text macro="title-short"/>
+ </if>
+ </choose>
+ </group>
+ <text variable="first-reference-note-number" prefix="(n " suffix=")"/>
+ <text macro="locator-basic"/>
+ </group>
+ </else>
+ </choose>
+ </else-if>
+ <else>
+ <!--general whole citation -->
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <text macro="author-note"/>
+ <group>
+ <text macro="title"/>
+ <text macro="book-container"/>
+ </group>
+ <text macro="broadcast-container"/>
+ <text macro="volume-book"/>
+ <text macro="looseleaf-note"/>
+ </group>
+ <group delimiter=" ">
+ <text macro="date-parenthesis"/>
+ <text macro="bill-number"/>
+ <text macro="article-case-info"/>
+ <text macro="publisher"/>
+ </group>
+ </group>
+ <text macro="treaty-catchall"/>
+ </group>
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text macro="page-first"/>
+ <text macro="court"/>
+ <text macro="locator-space"/>
+ </group>
+ <text macro="locator-comma"/>
+ </group>
+ <text macro="URL"/>
+ </group>
+ </else>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography et-al-min="4" et-al-use-first="1" subsequent-author-substitute="&#8212;&#8212;">
+ <sort>
+ <key macro="sort-type"/>
+ <key macro="author" names-min="1" names-use-first="1"/>
+ <key macro="author-count" names-min="2" names-use-first="2"/>
+ <key macro="author"/>
+ <key variable="issued"/>
+ <key variable="title"/>
+ </sort>
+ <layout>
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <text macro="author"/>
+ <group>
+ <text macro="title"/>
+ <text macro="book-container"/>
+ </group>
+ <text macro="broadcast-container"/>
+ <text macro="volume-book"/>
+ <text macro="looseleaf-note"/>
+ </group>
+ <group delimiter=" ">
+ <text macro="date-parenthesis"/>
+ <text macro="bill-number"/>
+ <text macro="article-case-info"/>
+ <text macro="publisher"/>
+ </group>
+ </group>
+ <text macro="treaty-catchall"/>
+ </group>
+ <group delimiter=" ">
+ <text macro="page-first"/>
+ <text macro="court"/>
+ </group>
+ <text macro="URL"/>
+ </group>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/pandoc-citeproc-118.md b/test/command/pandoc-citeproc-118.md
new file mode 100644
index 000000000..063bb6bbf
--- /dev/null
+++ b/test/command/pandoc-citeproc-118.md
@@ -0,0 +1,28 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- director:
+ family: Hitchcock
+ given: Alfred
+ id: nbn
+ issued:
+ year: 1959
+ language: 'en-US'
+ publisher: 'Metro-Goldwyn-Mayer'
+ publisher-place: USA
+ title: North by Northwest
+ type: motion_picture
+---
+
+[@nbn] is a spy thriller film.
+^D
+(Hitchcock 1959) is a spy thriller film.
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-nbn .csl-entry}
+Hitchcock, Alfred, dir. 1959. *North by Northwest*. USA:
+Metro-Goldwyn-Mayer.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-119.md b/test/command/pandoc-citeproc-119.md
new file mode 100644
index 000000000..8dfdfe421
--- /dev/null
+++ b/test/command/pandoc-citeproc-119.md
@@ -0,0 +1,39 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+bibliography: 'command/biblatex-examples.bib'
+csl: command/apa.csl
+---
+
+@averroes/bland; @averroes/hannes; @averroes/hercz
+
+References {#references .unnumbered}
+==========
+^D
+Averroes (1982); Averroes (1892); Averroes (1869)
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent line-spacing="2"}
+::: {#ref-averroes/hercz .csl-entry}
+Averroes. (1869). *Drei Abhandlungen über die Conjunction des separaten
+Intellects mit dem Menschen: Von Averroes (Vater und Sohn), aus dem
+Arabischen übersetzt von Samuel Ibn Tibbon*. (J. Hercz, Ed. & Trans.).
+Berlin: S. Hermann.
+:::
+
+::: {#ref-averroes/hannes .csl-entry}
+Averroes. (1892). *Des Averroës Abhandlung: "Über die Möglichkeit der
+Conjunktion" oder "Über den materiellen Intellekt"*. (L. Hannes, Ed. &
+Trans.). Halle an der Saale: C. A. Kaemmerer.
+:::
+
+::: {#ref-averroes/bland .csl-entry}
+Averroes. (1982). *The epistle on the possibility of conjunction with
+the active intellect by Ibn Rushd with the commentary of Moses Narboni*.
+(K. P. Bland, Ed. & Trans.). New York: Jewish Theological Seminary of
+America.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-13.md b/test/command/pandoc-citeproc-13.md
new file mode 100644
index 000000000..7d05aee0a
--- /dev/null
+++ b/test/command/pandoc-citeproc-13.md
@@ -0,0 +1,29 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chicago-note-bibliography.csl'
+references:
+- author:
+ family: Author
+ given:
+ - Ann
+ container-title: Journal
+ id: item1
+ issued:
+ - year: 2011
+ title: Title
+ type: 'article-newspaper'
+---
+
+Foo [@item1].
+^D
+Foo.[^1]
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+Author, Ann. "Title." *Journal*, 2011.
+:::
+:::
+
+[^1]: Author, "Title."
+```
diff --git a/test/command/pandoc-citeproc-136.md b/test/command/pandoc-citeproc-136.md
new file mode 100644
index 000000000..b04ff7c71
--- /dev/null
+++ b/test/command/pandoc-citeproc-136.md
@@ -0,0 +1,23 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- id: stanze
+ type: book
+ issued:
+ - year: 1547
+ title: Stanze in lode della donna brutta
+ publisher-place: Florence
+ language: it-IT
+...
+
+@stanze is an anoynymous work.
+^D
+*Stanze in lode della donna brutta* (1547) is an anoynymous work.
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-stanze .csl-entry}
+*Stanze in lode della donna brutta*. 1547. Florence.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-14.md b/test/command/pandoc-citeproc-14.md
new file mode 100644
index 000000000..18c3a91ee
--- /dev/null
+++ b/test/command/pandoc-citeproc-14.md
@@ -0,0 +1,78 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ family: Pelikan
+ given: Jaroslav
+ container-title: 'The Christian tradition: A history of the
+ development of doctrine'
+ id: CTv1c2
+ issued:
+ - year: 1971
+ language: 'en-US'
+ page: '34-56'
+ publisher: University of Chicago Press
+ publisher-place: Chicago
+ title: Chapter two
+ type: chapter
+ volume: 1
+ volume-title: 'The emergence of the Catholic tradition (100--600)'
+- author:
+ family: Pelikan
+ given: Jaroslav
+ container-title: 'The Christian tradition: A history of the
+ development of doctrine'
+ id: CTv1
+ issued:
+ - year: 1971
+ language: 'en-US'
+ publisher: University of Chicago Press
+ publisher-place: Chicago
+ title: 'The emergence of the Catholic tradition (100--600)'
+ type: book
+ volume: 1
+- author:
+ family: Pelikan
+ given: Jaroslav
+ id: CT
+ issued:
+ - year: 1971
+ language: 'en-US'
+ publisher: University of Chicago Press
+ publisher-place: Chicago
+ title: 'The Christian tradition: A history of the development of
+ doctrine'
+ type: book
+---
+
+Foo [@CT, 1:12]. Bar [@CTv1, 12]. Baz [@CTv1c2, 12].
+
+References {#references .unnumbered}
+==========
+^D
+Foo (Pelikan 1971b, 1:12). Bar (Pelikan 1971c, 1:12). Baz (Pelikan
+1971a, 12).
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-CTv1c2 .csl-entry}
+Pelikan, Jaroslav. 1971a. "Chapter Two." In *The Christian Tradition: A
+History of the Development of Doctrine*, 1:34--56. Chicago: University
+of Chicago Press.
+:::
+
+::: {#ref-CT .csl-entry}
+---------. 1971b. *The Christian Tradition: A History of the Development
+of Doctrine*. Chicago: University of Chicago Press.
+:::
+
+::: {#ref-CTv1 .csl-entry}
+---------. 1971c. *The Emergence of the Catholic Tradition (100--600)*.
+*The Christian Tradition: A History of the Development of Doctrine*.
+Vol. 1. Chicago: University of Chicago Press.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-152.md b/test/command/pandoc-citeproc-152.md
new file mode 100644
index 000000000..3e7be2e93
--- /dev/null
+++ b/test/command/pandoc-citeproc-152.md
@@ -0,0 +1,65 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/apa.csl
+references:
+- URL: 'http://geekfeminism.wikia.com/wiki/Geek_Feminism'
+ accessed:
+ day: 10
+ month: 4
+ year: 2013
+ container-title: Geek Feminism
+ custom2: ok.mm
+ id: Feminism2013gf
+ issued:
+ day: 10
+ month: 4
+ year: 2013
+ keyword: gender
+ title: Geek Feminism
+ type: webpage
+- URL: 'http://geekfeminism.wikia.com/wiki/Category:Communities'
+ accessed:
+ day: 19
+ month: 10
+ year: 2011
+ container-title: Geek Feminism
+ custom2: gender.mm
+ id: Feminism2011ces
+ issued:
+ day: 14
+ month: 8
+ year: 2011
+ keyword: gender
+ title: Communities
+ type: 'entry-encyclopedia'
+---
+
+Test
+====
+
+I have two citations [@Feminism2013gf; @Feminism2011ces].
+
+References
+==========
+^D
+Test
+====
+
+I have two citations ("Communities," 2011; "Geek Feminism," 2013).
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent line-spacing="2"}
+::: {#ref-Feminism2011ces .csl-entry}
+Communities. (2011, August 14). In *Geek Feminism*. Retrieved from
+<http://geekfeminism.wikia.com/wiki/Category:Communities>
+:::
+
+::: {#ref-Feminism2013gf .csl-entry}
+Geek Feminism. (2013, April 10). *Geek Feminism*. Retrieved April 10,
+2013, from <http://geekfeminism.wikia.com/wiki/Geek_Feminism>
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-160.md b/test/command/pandoc-citeproc-160.md
new file mode 100644
index 000000000..9f2a29e2c
--- /dev/null
+++ b/test/command/pandoc-citeproc-160.md
@@ -0,0 +1,46 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/issue160.csl
+references:
+- author:
+ - family: Doe
+ given: Jane
+ citation-label: Jane11
+ id: item1
+ issued:
+ year: 2011
+ title: A book
+ type: book
+---
+
+No citation-label
+-----------------
+
+Foo [@item1].
+
+Expected
+--------
+
+> Foo \[Jane11\].
+>
+> \[Jane11\] Jane Doe. A book. 2011.
+^D
+No citation-label
+-----------------
+
+Foo \[Jane11\].
+
+Expected
+--------
+
+> Foo \[Jane11\].
+>
+> \[Jane11\] Jane Doe. A book. 2011.
+
+::: {#refs .references .csl-bib-body}
+::: {#ref-item1 .csl-entry}
+\[Jane11\] Jane Doe. A book. 2011.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-175.md b/test/command/pandoc-citeproc-175.md
new file mode 100644
index 000000000..7fc50f2b1
--- /dev/null
+++ b/test/command/pandoc-citeproc-175.md
@@ -0,0 +1,45 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: Doe
+ given: Jane
+ container-title: A magazine
+ id: item1
+ issued:
+ - month: 1
+ year: 2011
+ - month: 2
+ year: 2011
+ page: '33-44'
+ title: A title
+ type: 'article-magazine'
+---
+
+Missing en-dash between months
+------------------------------
+
+Foo [@item1].
+
+Expected
+--------
+
+> Doe, Jane. 2011. "A Title." *A Magazine*, January--February.
+^D
+Missing en-dash between months
+------------------------------
+
+Foo (Doe 2011).
+
+Expected
+--------
+
+> Doe, Jane. 2011. "A Title." *A Magazine*, January--February.
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+Doe, Jane. 2011. "A Title." *A Magazine*, January--February 2011.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-197.md b/test/command/pandoc-citeproc-197.md
new file mode 100644
index 000000000..5713d67cc
--- /dev/null
+++ b/test/command/pandoc-citeproc-197.md
@@ -0,0 +1,31 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chicago-fullnote-bibliography.csl'
+nocite: '@test'
+references:
+- editor:
+ - family: Abelard
+ given: Peter
+ id: test
+ issued:
+ date-parts:
+ - - 1989
+ publisher: Clarendon Press
+ publisher-place: Oxford
+ title: Test
+ type: book
+---
+
+This is a test [@test].
+^D
+This is a test.[^1]
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-test .csl-entry}
+Abelard, Peter, ed. *Test*. Oxford: Clarendon Press, 1989.
+:::
+:::
+
+[^1]: Peter Abelard, ed., *Test* (Oxford: Clarendon Press, 1989).
+```
diff --git a/test/command/pandoc-citeproc-213.md b/test/command/pandoc-citeproc-213.md
new file mode 100644
index 000000000..2ca2287a1
--- /dev/null
+++ b/test/command/pandoc-citeproc-213.md
@@ -0,0 +1,34 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/harvard-university-of-kent.csl'
+references:
+- author:
+ - family: Doe
+ given: Ann
+ collection-title: The collection title
+ dimensions: 789 pp.
+ id: doe1
+ issued:
+ - year: 1999
+ publisher: The publisher
+ title: Title
+ type: book
+---
+
+Foo [@doe1].
+
+References {#references .unnumbered}
+==========
+^D
+Foo (Doe 1999).
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-doe1 .csl-entry}
+Doe, A. (1999). *Title*. The collection title. The publisher. 789 pp.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-25.md b/test/command/pandoc-citeproc-25.md
new file mode 100644
index 000000000..ab0b8c6f8
--- /dev/null
+++ b/test/command/pandoc-citeproc-25.md
@@ -0,0 +1,31 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: Author
+ given: Al
+ id: item1
+ issued:
+ date-parts:
+ - - 1998
+ title: 'foo bar baz: bazbaz foo'
+ type: 'article-journal'
+---
+
+Foo [@item1].
+
+References {#references .unnumbered}
+==========
+^D
+Foo (Author 1998).
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+Author, Al. 1998. "Foo Bar Baz: Bazbaz Foo."
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-250.md b/test/command/pandoc-citeproc-250.md
new file mode 100644
index 000000000..48cf68de1
--- /dev/null
+++ b/test/command/pandoc-citeproc-250.md
@@ -0,0 +1,21 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+link-citations: true
+references:
+- author:
+ family: Doe
+ id: doe
+ title: Title
+---
+
+[@doe]
+^D
+([Doe, n.d.](#ref-doe))
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-doe .csl-entry}
+Doe. n.d. "Title."
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-27.md b/test/command/pandoc-citeproc-27.md
new file mode 100644
index 000000000..ce8c20eff
--- /dev/null
+++ b/test/command/pandoc-citeproc-27.md
@@ -0,0 +1,39 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/science.csl
+references:
+- author:
+ - family: AuthorOne
+ given: Joe
+ - family: AuthorTwo
+ given: Jill
+ container-title: Some Journal
+ id: AuthorOne2014
+ issue: X
+ issued:
+ date-parts:
+ - - 2014
+ page: 'XXXX-YYYY'
+ title: Sample Title
+ type: 'article-journal'
+ volume: XX
+---
+
+Minimal example
+===============
+
+Here is some text that needs a citation [@AuthorOne2014].
+^D
+Minimal example
+===============
+
+Here is some text that needs a citation (*1*).
+
+::: {#refs .references .csl-bib-body}
+::: {#ref-AuthorOne2014 .csl-entry}
+[1. ]{.csl-left-margin}[J. AuthorOne, J. AuthorTwo, *Some Journal*, in
+press.]{.csl-right-inline}
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-292.md b/test/command/pandoc-citeproc-292.md
new file mode 100644
index 000000000..cffeb0539
--- /dev/null
+++ b/test/command/pandoc-citeproc-292.md
@@ -0,0 +1,43 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/sage-harvard.csl'
+references:
+- author:
+ family: Doe
+ id: doe
+ issued:
+ year: 2007
+ type: article
+- author:
+ family: Zoe
+ id: zoe
+ issued:
+ - year: 2009
+ type: article
+- author:
+ family: Roe
+ id: roe
+ issued:
+ - year: 2007
+ type: article
+---
+
+[@zoe; @roe; see for comparison @doe, p. 3]
+^D
+(Roe, 2007; Zoe, 2009; see for comparison Doe, 2007: 3)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-doe .csl-entry}
+Doe (2007).
+:::
+
+::: {#ref-roe .csl-entry}
+Roe (2007).
+:::
+
+::: {#ref-zoe .csl-entry}
+Zoe (2009).
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-301.md b/test/command/pandoc-citeproc-301.md
new file mode 100644
index 000000000..9d4af0339
--- /dev/null
+++ b/test/command/pandoc-citeproc-301.md
@@ -0,0 +1,25 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- id: test
+ title: Essays presented to N.R. Ker (On Art)
+- id: test2
+ title: '*Test:* An experiment: An abridgement'
+---
+
+@test; @test2
+^D
+"Essays Presented to N.R. Ker (On Art)" (n.d.); "*Test:* An Experiment:
+An Abridgement" (n.d.)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-test .csl-entry}
+"Essays Presented to N.R. Ker (On Art)." n.d.
+:::
+
+::: {#ref-test2 .csl-entry}
+"*Test:* An Experiment: An Abridgement." n.d.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-307.md b/test/command/pandoc-citeproc-307.md
new file mode 100644
index 000000000..ada3781e4
--- /dev/null
+++ b/test/command/pandoc-citeproc-307.md
@@ -0,0 +1,31 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+lang: 'fr-FR'
+references:
+- author:
+ - family: Bazin
+ given: André
+ container-title: Cahiers du cinéma
+ id: bazin_cybernetique_1954
+ issue: 36
+ issued:
+ date-parts:
+ - - 1954
+ - 6
+ page: '22-27'
+ title: 'La Cybernétique d''André Cayatte'
+ type: 'article-journal'
+---
+
+Bonjour[@bazin_cybernetique_1954] !
+^D
+Bonjour(Bazin 1954) !
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-bazin_cybernetique_1954 .csl-entry}
+Bazin, André. 1954. « La Cybernétique d'André Cayatte ». *Cahiers du
+cinéma*, nᵒ 36 (juin): 22‑27.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-31.md b/test/command/pandoc-citeproc-31.md
new file mode 100644
index 000000000..a06b2ae41
--- /dev/null
+++ b/test/command/pandoc-citeproc-31.md
@@ -0,0 +1,48 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/oscola.csl
+references:
+- DOI: 10.1086/504343
+ author:
+ - family: Olson
+ given: Hope A.
+ container-title: Library Quarterly
+ id: item1
+ issue: 1
+ issued:
+ date-parts:
+ - - 2006
+ page: '19-35'
+ title: 'Codes, costs, and critiques: The organization of information
+ in *Library Quarterly*, 1931--2004'
+ title-short: 'Codes, costs, and critiques'
+ type: 'article-magazine'
+ volume: 76
+- id: item2
+ title: Second title
+---
+
+Foo [@item1]. Bar [@item2]. Baz [@item1].
+^D
+Foo.[^1] Bar.[^2] Baz.[^3]
+
+::: {#refs .references .csl-bib-body}
+::: {#ref-item1 .csl-entry}
+Olson HA, 'Codes, Costs, and Critiques: The Organization of Information
+in *Library Quarterly*, 1931--2004' (2006) 76 *Library Quarterly* 19
+:::
+
+::: {#ref-item2 .csl-entry}
+'Second Title'
+:::
+:::
+
+[^1]: Hope A Olson, 'Codes, Costs, and Critiques: The Organization of
+ Information in *Library Quarterly*, 1931--2004' (2006) 76 *Library
+ Quarterly* 19.
+
+[^2]: 'Second Title'.
+
+[^3]: Olson (n 1).
+```
diff --git a/test/command/pandoc-citeproc-312.md b/test/command/pandoc-citeproc-312.md
new file mode 100644
index 000000000..dfc4fe25c
--- /dev/null
+++ b/test/command/pandoc-citeproc-312.md
@@ -0,0 +1,171 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/apa.csl
+nocite: '@*'
+references:
+- author:
+ - literal: NN
+ id: Y
+ issued:
+ - year: 1950
+ title: 'Date: Year'
+ title-short: Date
+ type: webpage
+- author:
+ - literal: NN
+ id: Y/Y
+ issued:
+ - year: 1951
+ - year: 1952
+ title: 'Date range: Year'
+ title-short: Date range
+ type: webpage
+- author:
+ - literal: NN
+ id: YM
+ issued:
+ - month: 1
+ year: 1953
+ title: 'Date: Year+month'
+ title-short: Date
+ type: webpage
+- author:
+ - literal: NN
+ id: YM/YM
+ issued:
+ - month: 1
+ year: 1954
+ - month: 2
+ year: 1955
+ title: 'Date range: Year+month'
+ title-short: Date range
+ type: webpage
+- author:
+ - literal: NN
+ id: YM/YM_same
+ issued:
+ - month: 1
+ year: 1956
+ - month: 2
+ year: 1956
+ title: 'Date range: Year+month, same year'
+ title-short: Date range
+ type: webpage
+- author:
+ - literal: NN
+ id: YMD
+ issued:
+ - day: 15
+ month: 1
+ year: 1958
+ title: 'Date: Year+month+day'
+ title-short: Date
+ type: webpage
+- author:
+ - literal: NN
+ id: YMD/YMD
+ issued:
+ - day: 15
+ month: 1
+ year: 1959
+ - day: 16
+ month: 2
+ year: 1960
+ title: 'Date range: Year+month+day'
+ title-short: Date range
+ type: webpage
+- author:
+ - literal: NN
+ id: YMD/YMD_same
+ issued:
+ - day: 15
+ month: 1
+ year: 1961
+ - day: 16
+ month: 1
+ year: 1962
+ title: 'Date range: Year+month+day, same month'
+ title-short: Date range
+ type: webpage
+- author:
+ - literal: NN
+ id: YS
+ issued:
+ - season: 3
+ year: 1963
+ title: 'Date: Year+season'
+ title-short: Date
+ type: webpage
+- author:
+ - literal: NN
+ id: YS/YS
+ issued:
+ - season: 1
+ year: 1964
+ - season: 4
+ year: 1965
+ title: 'Date range: Year+season'
+ title-short: Date range
+ type: webpage
+- author:
+ - literal: NN
+ id: YS/YS_same
+ issued:
+ - season: 2
+ year: 1966
+ - season: 4
+ year: 1966
+ title: 'Date range: Year+season, same year'
+ title-short: Date range
+ type: webpage
+---
+
+^D
+::: {#refs .references .csl-bib-body .hanging-indent line-spacing="2"}
+::: {#ref-Y .csl-entry}
+NN. (1950). Date: Year.
+:::
+
+::: {#ref-Y/Y .csl-entry}
+NN. (1951--1952). Date range: Year.
+:::
+
+::: {#ref-YM .csl-entry}
+NN. (1953, January). Date: Year+month.
+:::
+
+::: {#ref-YM/YM .csl-entry}
+NN. (1954--1955, January--February). Date range: Year+month.
+:::
+
+::: {#ref-YM/YM_same .csl-entry}
+NN. (1956, January--February). Date range: Year+month, same year.
+:::
+
+::: {#ref-YMD .csl-entry}
+NN. (1958, January 15). Date: Year+month+day.
+:::
+
+::: {#ref-YMD/YMD .csl-entry}
+NN. (1959--1960, January 15--February 16). Date range: Year+month+day.
+:::
+
+::: {#ref-YMD/YMD_same .csl-entry}
+NN. (1961--1962, January 15--16). Date range: Year+month+day, same
+month.
+:::
+
+::: {#ref-YS .csl-entry}
+NN. (1963, Autumn). Date: Year+season.
+:::
+
+::: {#ref-YS/YS .csl-entry}
+NN. (1964--1965, Spring--Winter). Date range: Year+season.
+:::
+
+::: {#ref-YS/YS_same .csl-entry}
+NN. (1966, Summer--Winter). Date range: Year+season, same year.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-320.md b/test/command/pandoc-citeproc-320.md
new file mode 100644
index 000000000..5e6ffdb6b
--- /dev/null
+++ b/test/command/pandoc-citeproc-320.md
@@ -0,0 +1,254 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/apa.csl
+references:
+- author:
+ - family: Benjamin
+ given: A. S.
+ id: itemA1
+- author:
+ - family: Yaakov
+ given: D.
+ non-dropping-particle: ben
+ id: itemA2
+- author:
+ - family: Brown
+ given: J. R.
+ id: itemA3
+- author:
+ - family: Browning
+ given: A. R.
+ id: itemA4
+- author:
+ - family: Girard
+ given: 'J.-B.'
+ id: itemA5
+- author:
+ - family: 'Girard-Perregaux'
+ given: A. S.
+ id: itemA6
+- author:
+ - family: Ibn Abdulaziz
+ given: T.
+ id: itemA7
+- author:
+ - family: Ibn Nidal
+ given: A. K. M.
+ id: itemA8
+- author:
+ - family: López
+ given: M. E.
+ id: itemA9
+- author:
+ - family: López de Molina
+ given: G.
+ id: itemA10
+- author:
+ - family: Singh
+ given: Y.
+ id: itemA11
+- author:
+ - family: Singh Siddhu
+ given: N.
+ id: itemA12
+- author:
+ - family: Villafuerte
+ given: S. A.
+ id: itemA13
+- author:
+ - family: 'Villa-Lobos'
+ given: J.
+ id: itemA14
+- author:
+ - family: Macalister
+ given: Donald
+ id: itemB1
+- author:
+ - family: MacAlister
+ given: Paul
+ id: itemB2
+- author:
+ - family: Macauley
+ given: Catharine
+ id: itemB3
+- author:
+ - family: Macmillan
+ given: Harold
+ id: itemB4
+- author:
+ - family: Madison
+ given: James
+ id: itemB5
+- author:
+ - family: McAllister
+ given: Ward
+ id: itemB6
+- author:
+ - family: McAuley
+ given: Catherine
+ id: itemB7
+- author:
+ - family: McMillan
+ given: Edwin M.
+ id: itemB8
+- author:
+ - family: 'Sainte-Beuve'
+ given: 'Charles-Augustin'
+ id: itemC1
+- author:
+ - family: 'Saint-Gaudens'
+ given: Augustus
+ id: itemC2
+- author:
+ - family: 'Saint-Saëns'
+ given: Camille
+ id: itemC3
+- author:
+ - dropping-particle: de
+ family: San Martin
+ given: José
+ id: itemC4
+- author:
+ - family: St. Denis
+ given: Ruth
+ id: itemC5
+- author:
+ - family: St. Laurent
+ given: Louis Stephen
+ id: itemC6
+---
+
+Foo
+[@itemA1; @itemA2; @itemA3; @itemA4; @itemA5; @itemA6; @itemA7; @itemA8; @itemA9; @itemA10; @itemA11; @itemA12; @itemA13; @itemA14].
+
+Foo
+[@itemB1; @itemB2; @itemB3; @itemB4; @itemB5; @itemB6; @itemB7; @itemB8].
+
+Foo [@itemC1; @itemC2; @itemC3; @itemC4; @itemC5; @itemC6].
+^D
+Foo (ben Yaakov, n.d.; Benjamin, n.d.; Brown, n.d.; Browning, n.d.;
+Girard, n.d.; Girard-Perregaux, n.d.; Ibn Abdulaziz, n.d.; Ibn Nidal,
+n.d.; López de Molina, n.d.; López, n.d.; Singh Siddhu, n.d.; Singh,
+n.d.; Villafuerte, n.d.; Villa-Lobos, n.d.).
+
+Foo (Macalister, n.d.; MacAlister, n.d.; Macauley, n.d.; Macmillan,
+n.d.; Madison, n.d.; McAllister, n.d.; McAuley, n.d.; McMillan, n.d.).
+
+Foo (Sainte-Beuve, n.d.; Saint-Gaudens, n.d.; Saint-Saëns, n.d.; San
+Martin, n.d.; St. Denis, n.d.; St. Laurent, n.d.).
+
+::: {#refs .references .csl-bib-body .hanging-indent line-spacing="2"}
+::: {#ref-itemA2 .csl-entry}
+ben Yaakov, D. (n.d.).
+:::
+
+::: {#ref-itemA1 .csl-entry}
+Benjamin, A. S. (n.d.).
+:::
+
+::: {#ref-itemA3 .csl-entry}
+Brown, J. R. (n.d.).
+:::
+
+::: {#ref-itemA4 .csl-entry}
+Browning, A. R. (n.d.).
+:::
+
+::: {#ref-itemA5 .csl-entry}
+Girard, J.-B. (n.d.).
+:::
+
+::: {#ref-itemA6 .csl-entry}
+Girard-Perregaux, A. S. (n.d.).
+:::
+
+::: {#ref-itemA7 .csl-entry}
+Ibn Abdulaziz, T. (n.d.).
+:::
+
+::: {#ref-itemA8 .csl-entry}
+Ibn Nidal, A. K. M. (n.d.).
+:::
+
+::: {#ref-itemA10 .csl-entry}
+López de Molina, G. (n.d.).
+:::
+
+::: {#ref-itemA9 .csl-entry}
+López, M. E. (n.d.).
+:::
+
+::: {#ref-itemB1 .csl-entry}
+Macalister, D. (n.d.).
+:::
+
+::: {#ref-itemB2 .csl-entry}
+MacAlister, P. (n.d.).
+:::
+
+::: {#ref-itemB3 .csl-entry}
+Macauley, C. (n.d.).
+:::
+
+::: {#ref-itemB4 .csl-entry}
+Macmillan, H. (n.d.).
+:::
+
+::: {#ref-itemB5 .csl-entry}
+Madison, J. (n.d.).
+:::
+
+::: {#ref-itemB6 .csl-entry}
+McAllister, W. (n.d.).
+:::
+
+::: {#ref-itemB7 .csl-entry}
+McAuley, C. (n.d.).
+:::
+
+::: {#ref-itemB8 .csl-entry}
+McMillan, E. M. (n.d.).
+:::
+
+::: {#ref-itemC1 .csl-entry}
+Sainte-Beuve, C.-A. (n.d.).
+:::
+
+::: {#ref-itemC2 .csl-entry}
+Saint-Gaudens, A. (n.d.).
+:::
+
+::: {#ref-itemC3 .csl-entry}
+Saint-Saëns, C. (n.d.).
+:::
+
+::: {#ref-itemC4 .csl-entry}
+San Martin, J. de. (n.d.).
+:::
+
+::: {#ref-itemA12 .csl-entry}
+Singh Siddhu, N. (n.d.).
+:::
+
+::: {#ref-itemA11 .csl-entry}
+Singh, Y. (n.d.).
+:::
+
+::: {#ref-itemC5 .csl-entry}
+St. Denis, R. (n.d.).
+:::
+
+::: {#ref-itemC6 .csl-entry}
+St. Laurent, L. S. (n.d.).
+:::
+
+::: {#ref-itemA13 .csl-entry}
+Villafuerte, S. A. (n.d.).
+:::
+
+::: {#ref-itemA14 .csl-entry}
+Villa-Lobos, J. (n.d.).
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-320a.md b/test/command/pandoc-citeproc-320a.md
new file mode 100644
index 000000000..1c3b47de0
--- /dev/null
+++ b/test/command/pandoc-citeproc-320a.md
@@ -0,0 +1,87 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: ʾUdhrī
+ given: Jamīl
+ non-dropping-particle: 'al-'
+ note: ayn
+ id: item1
+- author:
+ - family: ʿUdhrī
+ given: Jamīl
+ non-dropping-particle: 'al-'
+ note: hamza
+ id: item2
+- author:
+ - family: '\''Udhrī'
+ given: Jamīl
+ non-dropping-particle: 'al-'
+ note: straight apostrophe
+ id: item3
+- author:
+ - family: '‘Udhrī'
+ given: Jamīl
+ non-dropping-particle: 'al-'
+ note: inverted apostrophe = opening single curly quote (for ayn)
+ id: item4
+- author:
+ - family: '’Udhrī'
+ given: Jamīl
+ non-dropping-particle: 'al-'
+ note: apostrophe = closing single curly quote (for hamza)
+ id: item5
+- author:
+ - family: Uch
+ given: Ann
+ id: item6
+- author:
+ - family: Uebel
+ given: Joe
+ id: item7
+- author:
+ - family: Zzz
+ given: Zoe
+ id: item8
+---
+
+Foo [@item1; @item2; @item3; @item4; @item5; @item6; @item7; @item8].
+^D
+Foo (al-ʾUdhrī, n.d.; al-ʿUdhrī, n.d.; al-\'Udhrī, n.d.; al-'Udhrī,
+n.d.; al-'Udhrī, n.d.; Uch, n.d.; Uebel, n.d.; Zzz, n.d.).
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item6 .csl-entry}
+Uch, Ann. n.d.
+:::
+
+::: {#ref-item1 .csl-entry}
+ʾUdhrī, Jamīl al-. n.d.
+:::
+
+::: {#ref-item2 .csl-entry}
+ʿUdhrī, Jamīl al-. n.d.
+:::
+
+::: {#ref-item3 .csl-entry}
+\'Udhrī, Jamīl al-. n.d.
+:::
+
+::: {#ref-item4 .csl-entry}
+'Udhrī, Jamīl al-. n.d.
+:::
+
+::: {#ref-item5 .csl-entry}
+'Udhrī, Jamīl al-. n.d.
+:::
+
+::: {#ref-item7 .csl-entry}
+Uebel, Joe. n.d.
+:::
+
+::: {#ref-item8 .csl-entry}
+Zzz, Zoe. n.d.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-322.md b/test/command/pandoc-citeproc-322.md
new file mode 100644
index 000000000..78494f0c4
--- /dev/null
+++ b/test/command/pandoc-citeproc-322.md
@@ -0,0 +1,35 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/annales.csl
+references:
+- author:
+ - family: Timmory
+ given: François
+ container-title: 'L''Écran français'
+ id: timmory\_\_justice_1950
+ issue: 272
+ issued:
+ - day: 25
+ month: 9
+ year: 1950
+ language: 'fr-FR'
+ page: 12
+ title: '*Justice est faite* : soyons justes'
+ type: 'article-journal'
+---
+
+Foo[@timmory__justice_1950].
+^D
+Foo.[^1]
+
+::: {#refs .references .csl-bib-body}
+::: {#ref-timmory__justice_1950 .csl-entry}
+François [Timmory]{.smallcaps}, « *Justice est faite* : soyons justes »,
+*L'Écran français*, 1950, nᵒ 272, p. 12.
+:::
+:::
+
+[^1]: François [Timmory]{.smallcaps}, « *Justice est faite* : soyons
+ justes », *L'Écran français*, 1950, nᵒ 272, p. 12.
+```
diff --git a/test/command/pandoc-citeproc-325.md b/test/command/pandoc-citeproc-325.md
new file mode 100644
index 000000000..e8f2f7e8e
--- /dev/null
+++ b/test/command/pandoc-citeproc-325.md
@@ -0,0 +1,30 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: Smith
+ given: John
+ id: item1
+ type: book
+- author:
+ - family: Smith
+ given: John
+ id: item2
+ type: book
+---
+
+[@item1; @item2]
+^D
+(Smith, n.d.a, n.d.b)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+Smith, John. n.d.a.
+:::
+
+::: {#ref-item2 .csl-entry}
+---------. n.d.b.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-327.md b/test/command/pandoc-citeproc-327.md
new file mode 100644
index 000000000..54265dcc1
--- /dev/null
+++ b/test/command/pandoc-citeproc-327.md
@@ -0,0 +1,51 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chinese-gb7714-2005-numeric.csl'
+references:
+- ISSN: '1003-1111'
+ URL: 'http://kns.cnki.net/kns/detail/detail.aspx?QueryID=4&CurRec=4&recid=&FileName=CHAN201706006&DbName=CJFDLAST2018&DbCode=CJFQ&yx=Y&pr=&URLID=21.1110.S.20171129.1725.006'
+ abstract: '为了解辽东湾海域底栖动物次级生产力水平和时空分布特点,根据2007年的4月和10月辽东湾海域大型底栖动物调查数据,运用Brey经验公式计算大型底栖动物次级生产力和P/B值,并结合海洋生物指数方法对辽东湾海域进行生境适宜性评价。分析结果表明,该海域大型底栖动物年平均次级生产力为5.59g/(m\~2·年),年平均P/B值为3.16,辽东湾大型底栖动物次级生产力空间分布呈现出自沿岸向中部递增的趋势,P/B值空间分布与底栖动物次级生产力相反,呈现出自沿岸向中部递减的趋势,群落组成中以个体小、生活史短、代谢快的底栖动物为主。'
+ accessed:
+ - day: 27
+ month: 3
+ year: 2018
+ author:
+ - family: 李
+ given: 轶平
+ - family: 于
+ given: 旭光
+ - family: 孙
+ given: 明
+ - family: 郭
+ given: 栋
+ - family: 段
+ given: 妍
+ - family: 董
+ given: 婧
+ container-title: 水产科学
+ id: LiLiaoDongWanHaiYuDiQiDongWuCiJiShengChanLiYanJiuJiShengJingGuaYiXingPingJie2017
+ issue: 06
+ issued:
+ - year: 2017
+ keyword: '次级生产力,大型底栖动物,海洋生物指数方法,AMBI,macrozoobenthos,P/B
+ value,P/B值,secondary productivity'
+ language: 中文;
+ page: '728-734'
+ title: 辽东湾海域底栖动物次级生产力研究及生境适宜性评价
+ type: 'article-journal'
+---
+
+I referenced something here
+[@LiLiaoDongWanHaiYuDiQiDongWuCiJiShengChanLiYanJiuJiShengJingGuaYiXingPingJie2017]
+^D
+I referenced something here^\[1\]^
+
+::: {#refs .references .csl-bib-body}
+::: {#ref-LiLiaoDongWanHaiYuDiQiDongWuCiJiShengChanLiYanJiuJiShengJingGuaYiXingPingJie2017 .csl-entry}
+[\[1\]]{.csl-left-margin}[李轶平, 于旭光, 孙明, 等.
+辽东湾海域底栖动物次级生产力研究及生境适宜性评价\[J\]. 水产科学,
+2017(06): 728--734.]{.csl-right-inline}
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-338.md b/test/command/pandoc-citeproc-338.md
new file mode 100644
index 000000000..3250b680e
--- /dev/null
+++ b/test/command/pandoc-citeproc-338.md
@@ -0,0 +1,35 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/din-1505-2.csl'
+lang: de
+nocite: '@*'
+pagetitle: Citation
+references:
+- ISBN: '978-3-642-32078-1'
+ author:
+ - family: Wolfinger
+ given: Christine
+ edition: '11., vollst. überarb. Aufl.'
+ id: 'item-1'
+ issued:
+ - year: 2013
+ keyword: UNIX; LINUX
+ number-of-pages: 'XVIII, 529 S. : Ill., graph. Darst.'
+ publisher: Springer Vieweg
+ publisher-place: 'Berlin \[u.a.\]'
+ title: 'Keine Angst vor Linux, Unix: ein Lehrbuch für Linux- und
+ Unix-Anwender'
+ type: book
+---
+
+^D
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item-1 .csl-entry}
+[Wolfinger, Christine]{.smallcaps}: *Keine Angst vor Linux, Unix: ein
+Lehrbuch für Linux- und Unix-Anwender*. 11., vollst. überarb. Aufl.
+Aufl. Berlin \[u.a.\] : Springer Vieweg, 2013
+--- ISBN [978-3-642-32078-1](https://worldcat.org/isbn/978-3-642-32078-1)
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-351.md b/test/command/pandoc-citeproc-351.md
new file mode 100644
index 000000000..24cc8f99f
--- /dev/null
+++ b/test/command/pandoc-citeproc-351.md
@@ -0,0 +1,27 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/zeitschrift-fur-kunstgeschichte.csl'
+references:
+- editor:
+ - family: Nietzsche
+ given: Friedrich
+ id: Nie72
+ issued:
+ - year: 1872
+ title: Die geburt
+ type: book
+---
+
+@Nie72
+^D
+Friedrich Nietzsche (ed.)[^1]
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-Nie72 .csl-entry}
+Nietzsche, Friedrich (ed.), *Die geburt*, 1872.
+:::
+:::
+
+[^1]: *Die geburt*, 1872.
+```
diff --git a/test/command/pandoc-citeproc-356.md b/test/command/pandoc-citeproc-356.md
new file mode 100644
index 000000000..4463ef63f
--- /dev/null
+++ b/test/command/pandoc-citeproc-356.md
@@ -0,0 +1,25 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: Alice
+ id: foo
+ issued:
+ - year: 2042
+ other-ids:
+ - bar
+ - doz
+ type: book
+---
+
+[@bar]
+^D
+(Alice 2042)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-foo .csl-entry}
+Alice. 2042.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-360.md b/test/command/pandoc-citeproc-360.md
new file mode 100644
index 000000000..233551304
--- /dev/null
+++ b/test/command/pandoc-citeproc-360.md
@@ -0,0 +1,35 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chicago-fullnote-bibliography.csl'
+references:
+- author:
+ - family: 'L''Estrange'
+ given: Michael
+ - family: Merchant
+ given: Stephen
+ id: lestrange2017
+ issued:
+ - day: 18
+ month: 7
+ year: 2017
+ language: 'en-US'
+ title: 2017 Independent Intelligence Review
+ title-short: Independent Intelligence Review
+ type: report
+---
+
+[@lestrange2017]
+^D
+[^1]
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-lestrange2017 .csl-entry}
+L'Estrange, Michael, and Stephen Merchant. *2017 Independent
+Intelligence Review*, July 18, 2017.
+:::
+:::
+
+[^1]: Michael L'Estrange and Stephen Merchant, *2017 Independent
+ Intelligence Review*, July 18, 2017.
+```
diff --git a/test/command/pandoc-citeproc-361.md b/test/command/pandoc-citeproc-361.md
new file mode 100644
index 000000000..d187ffc6b
--- /dev/null
+++ b/test/command/pandoc-citeproc-361.md
@@ -0,0 +1,80 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/locators.csl
+references:
+- id: citekey
+ title: Title
+ type: 'article-journal'
+- id: other
+ title: Other
+ type: 'article-journal'
+suppress-bibliography: true
+---
+
+Content[@citekey]
+
+Content[@citekey, 1]
+
+Content[@citekey, 2]
+
+Content[@citekey, 2]
+
+Content[@citekey 2]
+
+Content[@citekey, p. 2]
+
+Content[@citekey p. 2]
+
+Content[@citekey]
+
+Content[@other]
+
+Content[@citekey, 3]
+
+Content[@citekey, 3]
+^D
+Content[^1]
+
+Content[^2]
+
+Content[^3]
+
+Content[^4]
+
+Content[^5]
+
+Content[^6]
+
+Content[^7]
+
+Content[^8]
+
+Content[^9]
+
+Content[^10]
+
+Content[^11]
+
+[^1]: Title.
+
+[^2]: Ibid-with-locator {1}.
+
+[^3]: Ibid-with-locator {2}.
+
+[^4]: Ibid.
+
+[^5]: Ibid.
+
+[^6]: Ibid.
+
+[^7]: Ibid.
+
+[^8]: Subsequent.
+
+[^9]: Other.
+
+[^10]: Subsequent {3}.
+
+[^11]: Ibid.
+```
diff --git a/test/command/pandoc-citeproc-365.md b/test/command/pandoc-citeproc-365.md
new file mode 100644
index 000000000..8d43ab659
--- /dev/null
+++ b/test/command/pandoc-citeproc-365.md
@@ -0,0 +1,39 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/le-tapuscrit-note.csl'
+references:
+- ISBN: '978-2-912573-52-0'
+ author:
+ - family: Le Gras
+ given: Gwénaëlle
+ call-number: 'Tolbiac - Rez de Jardin - Littérature et art - Magasin -
+ 2010-82178'
+ collection-title: 'Jeux d''acteurs'
+ id: legras_michel_2010
+ issued:
+ - year: 2010
+ language: fre
+ number-of-pages: 128
+ publisher: Scope
+ publisher-place: Paris
+ source: 'BnF Catalogue général (http://catalogue.bnf.fr)'
+ title: 'Michel Simon : l''art de la disgrâce'
+ title-short: Michel Simon
+ type: book
+---
+
+Foo [@legras_michel_2010].
+^D
+Foo.[^1]
+
+::: {#refs .references .csl-bib-body}
+::: {#ref-legras_michel_2010 .csl-entry}
+[Le Gras]{.smallcaps} Gwénaëlle, *Michel Simon : l'art de la disgrâce*,
+Paris, Scope (coll. « Jeux d'acteurs »), 2010, 128 p.
+:::
+:::
+
+[^1]: Gwénaëlle Le Gras, *Michel Simon : l'art de la disgrâce*, Paris,
+ Scope, 2010, 128 p.
+```
diff --git a/test/command/pandoc-citeproc-371.md b/test/command/pandoc-citeproc-371.md
new file mode 100644
index 000000000..c080b25c1
--- /dev/null
+++ b/test/command/pandoc-citeproc-371.md
@@ -0,0 +1,41 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: Doe
+ given: Jane
+ id: item1
+ status: in press
+ title: Title one
+ type: book
+- author:
+ - family: Doe
+ given: Jane
+ id: item2
+ issued:
+ - year: 2018
+ title: Title two
+ type: book
+---
+
+Foo [@item2; @item1].
+
+References {#references .unnumbered}
+==========
+^D
+Foo (Doe 2018, in press).
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item2 .csl-entry}
+Doe, Jane. 2018. *Title Two*.
+:::
+
+::: {#ref-item1 .csl-entry}
+---------. In press. *Title One*.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-38.md b/test/command/pandoc-citeproc-38.md
new file mode 100644
index 000000000..fae4e49fd
--- /dev/null
+++ b/test/command/pandoc-citeproc-38.md
@@ -0,0 +1,29 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: Doe
+ given: Ann
+ - family: Doe
+ given: Ben
+ - family: Roe
+ given: Ron
+ id: a
+ issued:
+ date-parts:
+ - - 2007
+ title: Title
+ type: 'article-journal'
+---
+
+@a
+^D
+Doe, Doe, and Roe (2007)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-a .csl-entry}
+Doe, Ann, Ben Doe, and Ron Roe. 2007. "Title."
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-386.md b/test/command/pandoc-citeproc-386.md
new file mode 100644
index 000000000..6fab96c07
--- /dev/null
+++ b/test/command/pandoc-citeproc-386.md
@@ -0,0 +1,35 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/advanced-optical-materials.csl'
+references:
+- DOI: 10.1038/lsa.2012.20
+ ISSN: '2047-7538'
+ author:
+ - family: Ding
+ given: K.
+ - family: Ning
+ given: C. Z.
+ container-title: Light Sci. Appl.
+ id: ding_metallic_2012
+ issue: 7
+ issued:
+ - month: 7
+ year: 2012
+ page: 'e20-e20'
+ title: 'Metallic subwavelength-cavity semiconductor nanolasers'
+ type: 'article-journal'
+ volume: 1
+---
+
+@ding_metallic_2012
+^D
+^\[1\]^
+
+::: {#refs .references .csl-bib-body line-spacing="2"}
+::: {#ref-ding_metallic_2012 .csl-entry}
+[\[1\]]{.csl-left-margin}[K. Ding, C. Z. Ning, *Light Sci. Appl.*
+**2012**, *1*, e20.]{.csl-right-inline}
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-392.md b/test/command/pandoc-citeproc-392.md
new file mode 100644
index 000000000..5b0be6eb7
--- /dev/null
+++ b/test/command/pandoc-citeproc-392.md
@@ -0,0 +1,29 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/vancouver.csl
+references:
+- author:
+ - family: James
+ given: M.R.C.E.L.
+ id: james
+- author:
+ - family: MacFarlane
+ given: J. G.
+ id: macfarlane
+---
+
+@james; @macfarlane
+^D
+(1); (2)
+
+::: {#refs .references .csl-bib-body}
+::: {#ref-james .csl-entry}
+[1. ]{.csl-left-margin}[James MRCEL. ]{.csl-right-inline}
+:::
+
+::: {#ref-macfarlane .csl-entry}
+[2. ]{.csl-left-margin}[MacFarlane JG. ]{.csl-right-inline}
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-399.md b/test/command/pandoc-citeproc-399.md
new file mode 100644
index 000000000..0c0840c70
--- /dev/null
+++ b/test/command/pandoc-citeproc-399.md
@@ -0,0 +1,45 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/style399.csl
+references:
+- author:
+ - family: One
+ id: one
+- author:
+ - family: Two
+ id: two
+- author:
+ - family: Three
+ id: three
+- author:
+ - family: Four
+ id: four
+- author:
+ - family: Five
+ id: five
+- author:
+ - family: Six
+ id: six
+- author:
+ - family: Seven
+ id: seven
+- author:
+ - family: Eight
+ id: eight
+- author:
+ - family: Nine
+ id: nine
+- author:
+ - family: Ten
+ id: ten
+- author:
+ - family: Eleven
+ id: eleven
+---
+
+Inline citation
+[@one; @two; @three; @four; @five; @six; @seven; @eight; @nine; @ten; @eleven].
+^D
+Inline citation \[1,2,3,4,5,6,7,8,9,10,11\].
+```
diff --git a/test/command/pandoc-citeproc-401.md b/test/command/pandoc-citeproc-401.md
new file mode 100644
index 000000000..b5c36334e
--- /dev/null
+++ b/test/command/pandoc-citeproc-401.md
@@ -0,0 +1,59 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- id: haslanger2012SocialConstructionDebunking
+ type: chapter
+ author:
+ - family: Haslanger
+ given: Sally
+ issued:
+ - year: 2012
+ original-date:
+ - year: 2003
+ title: 'Social Construction: The ‘Debunking’ Project'
+ title-short: Social Construction
+ container-title: 'Resisting Reality: Social Construction and Social Critique'
+ publisher: Oxford University Press
+ publisher-place: Oxford
+ event-place: Oxford
+ page: 113–138
+ ISBN: 978-0-19-989262-4
+
+- id: haslanger2012FeminismMetaphysicsNegotiating
+ type: chapter
+ author:
+ - family: Haslanger
+ given: Sally
+ issued:
+ - year: 2012
+ original-date:
+ - year: 2000
+ title: 'Feminism in Metaphysics: Negotiating the Natural'
+ container-title: 'Resisting Reality: Social Construction and Social Critique'
+ publisher: Oxford University Press
+ publisher-place: Oxford
+ event-place: Oxford
+ page: 139–157
+ ISBN: 978-0-19-989262-4
+ language: en
+...
+
+Haslanger [-@haslanger2012SocialConstructionDebunking; @haslanger2012FeminismMetaphysicsNegotiating] says...
+^D
+Haslanger (\[2003\] 2012, \[2000\] 2012) says...
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-haslanger2012FeminismMetaphysicsNegotiating .csl-entry}
+Haslanger, Sally. (2000) 2012. "Feminism in Metaphysics: Negotiating the
+Natural." In *Resisting Reality: Social Construction and Social
+Critique*, 139--57. Oxford: Oxford University Press.
+:::
+
+::: {#ref-haslanger2012SocialConstructionDebunking .csl-entry}
+---------. (2003) 2012. "Social Construction: The 'Debunking' Project."
+In *Resisting Reality: Social Construction and Social Critique*,
+113--38. Oxford: Oxford University Press.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-408.md b/test/command/pandoc-citeproc-408.md
new file mode 100644
index 000000000..8e3571aeb
--- /dev/null
+++ b/test/command/pandoc-citeproc-408.md
@@ -0,0 +1,39 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- id: smith1
+ type: article-journal
+ author:
+ - family: Smith
+ given: Mary
+ issued:
+ - year: 2019
+ title: Foo
+
+- id: smithsmith
+ type: article-journal
+ author:
+ - family: Smith
+ given: Mary
+ - family: Smith
+ given: John
+ issued:
+ - year: 2019
+ title: Foo bar
+...
+
+[@smithsmith; @smith1]
+^D
+(Smith and Smith 2019; Smith 2019)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-smith1 .csl-entry}
+Smith, Mary. 2019. "Foo."
+:::
+
+::: {#ref-smithsmith .csl-entry}
+Smith, Mary, and John Smith. 2019. "Foo Bar."
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-416.md b/test/command/pandoc-citeproc-416.md
new file mode 100644
index 000000000..e34401118
--- /dev/null
+++ b/test/command/pandoc-citeproc-416.md
@@ -0,0 +1,61 @@
+```
+% pandoc --citeproc -t markdown-citations
+Blah blah [@item1; @item2; @item3].
+
+# References {-}
+
+---
+title: The Title
+references:
+- id: item1
+ type: article-newspaper
+ author:
+ - family: Doe
+ given: J.
+ issued:
+ - year: 2010
+ month: 12
+ day: 13
+ title: The title
+- id: item2
+ type: article-newspaper
+ author:
+ - family: Doe
+ given: J.
+ issued:
+ - year: 2007
+ month: 12
+ day: 12
+ - year: 2007
+ month: 12
+ day: 13
+ title: The title
+- id: item3
+ type: article-newspaper
+ author:
+ - family: Doe
+ given: J.
+ issued:
+ - year: 2008
+ title: The title
+...
+^D
+Blah blah (Doe 2010, 2007, 2008).
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item2 .csl-entry}
+Doe, J. 2007. "The Title," December 12--13, 2007.
+:::
+
+::: {#ref-item3 .csl-entry}
+---------. 2008. "The Title," 2008.
+:::
+
+::: {#ref-item1 .csl-entry}
+---------. 2010. "The Title," December 13, 2010.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-437.md b/test/command/pandoc-citeproc-437.md
new file mode 100644
index 000000000..91b3cbbcf
--- /dev/null
+++ b/test/command/pandoc-citeproc-437.md
@@ -0,0 +1,23 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/issue437.csl
+references:
+- author:
+ - family: Smith
+ given: John
+ id: hirt2009
+ issued:
+ - year: 2009
+ publisher: Publishing House
+ publisher-place: Lausanne
+ title: Some Book
+ type: book
+---
+
+> Here is a quote. [@hirt2009]
+^D
+> Here is a quote.[^1]
+
+[^1]: John Smith, Some Book, Lausanne, 2009
+```
diff --git a/test/command/pandoc-citeproc-47.md b/test/command/pandoc-citeproc-47.md
new file mode 100644
index 000000000..478a54bf3
--- /dev/null
+++ b/test/command/pandoc-citeproc-47.md
@@ -0,0 +1,113 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: Doe
+ given: A.
+ id: doe
+ issued:
+ date-parts:
+ - - 2000
+ title: Title
+ type: book
+- author:
+ - family: Doe
+ given: A.
+ - family: Poe
+ given: A.
+ id: doepoe
+ issued:
+ date-parts:
+ - - 2000
+ title: Title
+ type: book
+- editor:
+ - family: Doe
+ given: A.
+ id: 'doe-ed'
+ issued:
+ date-parts:
+ - - 2000
+ title: Title
+ type: book
+- author:
+ - family: Doe
+ given: A.
+ - family: Loe
+ given: A.
+ - family: Toe
+ given: A.
+ id: doeloetoe
+ issued:
+ date-parts:
+ - - 2000
+ title: Title
+ type: book
+---
+
+Foo [@doe]. Bar [@doepoe]. Foo [@doe-ed]. Bar [@doeloetoe].
+
+Expected output:
+
+> Doe, A. 2000a. Title.
+>
+> ---------, ed. 2000b. Title.
+>
+> Doe, A., A. Loe, and A. Toe. 2000. Title.
+>
+> Doe, A., and A. Poe. 2000. Title.
+
+(See CMoS, 16e, 15.16, "Single author versus several authors---reference
+list order": "Successive entries by two or more authors in which only
+the first author's name is the same are alphabetized according to the
+coauthors' last names (regardless of how many coauthors there are)." and
+15.18, "The 3-em dash with edited, translated, or compiled works": "The
+chronological order is maintained, regardless of the added abbreviation.
+\[ed., trans., comp., or whatever\]"
+
+References {#references .unnumbered}
+==========
+^D
+Foo (Doe 2000a). Bar (Doe and Poe 2000). Foo (Doe 2000b). Bar (Doe, Loe,
+and Toe 2000).
+
+Expected output:
+
+> Doe, A. 2000a. Title.
+>
+> ---------, ed. 2000b. Title.
+>
+> Doe, A., A. Loe, and A. Toe. 2000. Title.
+>
+> Doe, A., and A. Poe. 2000. Title.
+
+(See CMoS, 16e, 15.16, "Single author versus several authors---reference
+list order": "Successive entries by two or more authors in which only
+the first author's name is the same are alphabetized according to the
+coauthors' last names (regardless of how many coauthors there are)." and
+15.18, "The 3-em dash with edited, translated, or compiled works": "The
+chronological order is maintained, regardless of the added abbreviation.
+\[ed., trans., comp., or whatever\]"
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-doe .csl-entry}
+Doe, A. 2000a. *Title*.
+:::
+
+::: {#ref-doe-ed .csl-entry}
+---------, ed. 2000b. *Title*.
+:::
+
+::: {#ref-doeloetoe .csl-entry}
+Doe, A., A. Loe, and A. Toe. 2000. *Title*.
+:::
+
+::: {#ref-doepoe .csl-entry}
+Doe, A., and A. Poe. 2000. *Title*.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-51.md b/test/command/pandoc-citeproc-51.md
new file mode 100644
index 000000000..fc7dc2bb1
--- /dev/null
+++ b/test/command/pandoc-citeproc-51.md
@@ -0,0 +1,45 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: Doe
+ given: John
+ container-title: Journal of Something
+ id: item1
+ issued:
+ date-parts:
+ - - 1987
+ - - 1988
+ page: '12-34'
+ title: The title
+ type: 'article-journal'
+ volume: 3
+- author:
+ - family: Roe
+ given: Ron
+ container-title: Journal of Something
+ id: item2
+ issued:
+ date-parts:
+ - - 1987
+ page: '12-34'
+ title: The title
+ type: 'article-journal'
+ volume: 4
+---
+
+@item1; @item2
+^D
+Doe (1987--1988); Roe (1987)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+Doe, John. 1987--1988. "The Title." *Journal of Something* 3: 12--34.
+:::
+
+::: {#ref-item2 .csl-entry}
+Roe, Ron. 1987. "The Title." *Journal of Something* 4: 12--34.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-53.md b/test/command/pandoc-citeproc-53.md
new file mode 100644
index 000000000..295f52049
--- /dev/null
+++ b/test/command/pandoc-citeproc-53.md
@@ -0,0 +1,54 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/archeologie-medievale.csl
+references:
+- title: Work A
+ id: a
+ issued:
+ date-parts:
+ - - 2000
+ author:
+ - given: John
+ family: Doe
+ type: book
+- title: Work B
+ id: b
+ issued:
+ date-parts:
+ - - 1990
+ author:
+ - given: Jane
+ family: Roe
+ type: book
+---
+@a @a @b @b @a @a @b @b
+^D
+Doe[^1] Doe[^2] Roe[^3] Roe[^4] Doe[^5] Doe[^6] Roe[^7] Roe[^8]
+
+::: {#refs .references .csl-bib-body}
+::: {#ref-a .csl-entry}
+[[Doe J.]{.smallcaps} ]{.csl-block}[2000, *Work A*,.]{.csl-left-margin}
+:::
+
+::: {#ref-b .csl-entry}
+[[Roe J.]{.smallcaps} ]{.csl-block}[1990, *Work B*,.]{.csl-left-margin}
+:::
+:::
+
+[^1]: 2000
+
+[^2]: *Ibid.*
+
+[^3]: 1990
+
+[^4]: *Ibid.*
+
+[^5]: 2000
+
+[^6]: *Ibid.*
+
+[^7]: 1990
+
+[^8]: *Ibid.*
+```
diff --git a/test/command/pandoc-citeproc-57.md b/test/command/pandoc-citeproc-57.md
new file mode 100644
index 000000000..4232e1ef8
--- /dev/null
+++ b/test/command/pandoc-citeproc-57.md
@@ -0,0 +1,38 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chicago-author-date-with-original-date-and-status.csl'
+references:
+- author:
+ - family: Faraday
+ given: Carry
+ container-title: Seven Trips beyond the Asteroid Belt
+ editor:
+ - family: Oring
+ given: James
+ id: 'Faraday-forthcoming'
+ publisher: Launch Press
+ publisher-place: 'Cape Canaveral, FL'
+ status: forthcoming
+ title: Protean photography
+ type: chapter
+---
+
+[@Faraday-forthcoming]
+
+References
+==========
+^D
+(Faraday, forthcoming)
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-Faraday-forthcoming .csl-entry}
+Faraday, Carry. Forthcoming. "Protean Photography." In *Seven Trips
+Beyond the Asteroid Belt*, edited by James Oring. Cape Canaveral, FL:
+Launch Press.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-58.md b/test/command/pandoc-citeproc-58.md
new file mode 100644
index 000000000..764533173
--- /dev/null
+++ b/test/command/pandoc-citeproc-58.md
@@ -0,0 +1,33 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/issue58.csl
+references:
+- id: stanze
+ issued:
+ date-parts:
+ - - 1547
+ language: 'it-IT'
+ publisher-place: Florence
+ title: Stanze in lode della donna brutta
+ type: book
+---
+
+In this item, the title replaces the (unknown) author (see 14.79)
+[@stanze, p. 12].
+
+References
+==========
+^D
+In this item, the title replaces the (unknown) author (see 14.79)
+(*Stanze in lode della donna brutta* 1547, 12).
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-stanze .csl-entry}
+*Stanze in lode della donna brutta*. 1547. Florence.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-61.md b/test/command/pandoc-citeproc-61.md
new file mode 100644
index 000000000..e96e93be7
--- /dev/null
+++ b/test/command/pandoc-citeproc-61.md
@@ -0,0 +1,79 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/modern-humanities-research-association.csl'
+references:
+- author:
+ - family: Doe
+ given: John
+ id: doe
+ issued:
+ date-parts:
+ - - 1985
+ publisher: Publisher
+ title: Title
+ type: book
+- author:
+ - family: Roe
+ given: Rob
+ id: roe
+ issued:
+ date-parts:
+ - - 1985
+ publisher: Publisher
+ title: Title
+ type: book
+---
+
+Text
+====
+
+Foo [@doe, VIII, 89]
+
+Foo [@roe, III, 89]
+
+Foo [@doe, LVIII, 89]
+
+Foo [@roe, MVIII, 89]
+
+Foo [@doe, CL, 89]
+
+References
+==========
+^D
+Text
+====
+
+Foo[^1]
+
+Foo[^2]
+
+Foo[^3]
+
+Foo[^4]
+
+Foo[^5]
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-doe .csl-entry}
+Doe, John, *Title* (Publisher, 1985)
+:::
+
+::: {#ref-roe .csl-entry}
+Roe, Rob, *Title* (Publisher, 1985)
+:::
+:::
+
+[^1]: John Doe, *Title* (Publisher, 1985), VIII, 89.
+
+[^2]: Rob Roe, *Title* (Publisher, 1985), III, 89.
+
+[^3]: Doe, LVIII, 89.
+
+[^4]: Roe, MVIII, 89.
+
+[^5]: Doe, CL, 89.
+```
diff --git a/test/command/pandoc-citeproc-64.md b/test/command/pandoc-citeproc-64.md
new file mode 100644
index 000000000..277b3756d
--- /dev/null
+++ b/test/command/pandoc-citeproc-64.md
@@ -0,0 +1,24 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+bibliography:
+- command/biblio.bib
+nocite: '[@*]'
+---
+
+^D
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+Doe, John. 2005. *First Book*. Cambridge: Cambridge University Press.
+:::
+
+::: {#ref-item2 .csl-entry}
+---------. 2006. "Article." *Journal of Generic Studies* 6: 33--34.
+:::
+
+::: {#ref-пункт3 .csl-entry}
+Doe, John, and Jenny Roe. 2007. "Why Water Is Wet." In *Third Book*,
+edited by Sam Smith. Oxford: Oxford University Press.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-65.md b/test/command/pandoc-citeproc-65.md
new file mode 100644
index 000000000..7b07f7ecf
--- /dev/null
+++ b/test/command/pandoc-citeproc-65.md
@@ -0,0 +1,38 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- ISBN: 3406493556
+ author:
+ - family: Stotz
+ given: Peter
+ call-number: 'PA25 PA2616 .H24 Abt. 2, T. 5, Bd. 2, etc'
+ collection-number: 2.5
+ collection-title: Handbuch der Altertumswissenschaft
+ event-place: Munich
+ first-reference-note-number: 1
+ id: 'stotz:1996handbuch'
+ issued:
+ literal: 1996_2004
+ language: German
+ number-of-volumes: 5
+ publisher: Beck
+ publisher-place: Munich
+ source: Library of Congress ISBN
+ title: Handbuch zur lateinischen Sprache des Mittelalters
+ title-short: Handbuch
+ type: book
+---
+
+[@stotz:1996handbuch]
+^D
+(Stotz 1996--2004)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-stotz:1996handbuch .csl-entry}
+Stotz, Peter. 1996--2004. *Handbuch zur lateinischen Sprache des
+Mittelalters*. 5 vols. Handbuch der Altertumswissenschaft 2.5. Munich:
+Beck.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-68.md b/test/command/pandoc-citeproc-68.md
new file mode 100644
index 000000000..d384f0e69
--- /dev/null
+++ b/test/command/pandoc-citeproc-68.md
@@ -0,0 +1,56 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chicago-fullnote-bibliography.csl'
+references:
+- ISBN: 0888441088
+ author:
+ - family: Goering
+ given: Joseph
+ call-number: BV4009 .W55 1992
+ collection-number: 108
+ collection-title: Studies and Texts
+ event-place: Toronto
+ first-reference-note-number: 1
+ id: 'goering:1992william'
+ issued:
+ date-parts:
+ - - 1992
+ publisher: Pontifical Institute of Mediaeval Studies
+ publisher-place: Toronto
+ source: toroprod.library.utoronto.ca Library Catalog
+ title: 'William de Montibus (c. 1140--1213): The Schools and the
+ Literature of Pastoral Care'
+ title-short: William de Montibus
+ type: book
+---
+
+\... a prose commentary [the text of fol. 9r is printed in
+@goering:1992william, pp. 501--3]. \... a collection of verses with a
+formal prose commentary [excerpts from this text were previously printed
+in @goering:1992william, p. 508--14; it was also briefly described in
+@goering:1992william, pp. 141--42] \... and finally a note starting with
+a citation [@goering:1992william, pp. 141-42].
+^D
+\... a prose commentary.[^1] \... a collection of verses with a formal
+prose commentary[^2] \... and finally a note starting with a
+citation.[^3]
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-goering:1992william .csl-entry}
+Goering, Joseph. *William de Montibus (c. 1140--1213): The Schools and
+the Literature of Pastoral Care*. Studies and Texts 108. Toronto:
+Pontifical Institute of Mediaeval Studies, 1992.
+:::
+:::
+
+[^1]: The text of fol. 9r is printed in Joseph Goering, *William de
+ Montibus (c. 1140--1213): The Schools and the Literature of Pastoral
+ Care*, Studies and Texts 108 (Toronto: Pontifical Institute of
+ Mediaeval Studies, 1992), 501--3.
+
+[^2]: Excerpts from this text were previously printed in ibid., 508--14;
+ it was also briefly described in ibid., 141--42.
+
+[^3]: Goering, *William de Montibus*, 141--42.
+```
diff --git a/test/command/pandoc-citeproc-7.md b/test/command/pandoc-citeproc-7.md
new file mode 100644
index 000000000..7d68ff566
--- /dev/null
+++ b/test/command/pandoc-citeproc-7.md
@@ -0,0 +1,31 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ family: Author
+ given:
+ - Ann
+ container-title: Journal
+ id: item1
+ issued:
+ - day: 24
+ month: 9
+ year: 2011
+ - day: 26
+ month: 9
+ year: 2011
+ title: Title
+ type: 'article-magazine'
+---
+
+@item1
+^D
+Author (2011)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+Author, Ann. 2011. "Title." *Journal*, September 24--26, 2011.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-70.md b/test/command/pandoc-citeproc-70.md
new file mode 100644
index 000000000..fb96add82
--- /dev/null
+++ b/test/command/pandoc-citeproc-70.md
@@ -0,0 +1,73 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- ISBN: 9782503531465
+ author:
+ - family: 'Dinkova-Bruun'
+ given: Greti
+ call-number: CB351 .F564 2009
+ collection-number: 50
+ collection-title: Textes et études du moyen âge
+ container-title: 'Florilegium mediaevale: Études offertes à Jacqueline
+ Hamesse à l''occasion de son éméritat'
+ editor:
+ - family: Meirinhos
+ given: José Francisco
+ - family: Weijers
+ given: Olga
+ event-place: 'Louvain-la-Neuve'
+ first-reference-note-number: 1
+ id: 'bruun:2009samuel'
+ issued:
+ date-parts:
+ - - 2009
+ language: French
+ page: '155--174'
+ publisher: 'Fédération Internationale des Instituts d''Études
+ Médiévales'
+ publisher-place: 'Louvain-la-Neuve'
+ source: Library of Congress ISBN
+ title: 'Samuel Presbyter and the Glosses to His Versification of Psalm
+ 1: An Anti-Church Invective?'
+ title-short: Samuel Presbyter
+ type: chapter
+- ISSN: '0362-1529'
+ author:
+ - family: Thorndike
+ given: Lynn
+ container-title: Traditio
+ first-reference-note-number: 1
+ id: 'thorndike:1955unde'
+ issued:
+ date-parts:
+ - - 1955
+ language: Latin
+ note: 'ArticleType: research-article / Full publication date: 1955 /
+ Copyright © 1955 Fordham University'
+ page: '163--193'
+ source: JSTOR
+ title: Unde versus
+ type: 'article-journal'
+ volume: 11
+---
+
+[@thorndike:1955unde; @bruun:2009samuel]
+^D
+(Thorndike 1955; Dinkova-Bruun 2009)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-bruun:2009samuel .csl-entry}
+Dinkova-Bruun, Greti. 2009. "Samuel Presbyter and the Glosses to His
+Versification of Psalm 1: An Anti-Church Invective?" In *Florilegium
+mediaevale: Études offertes à Jacqueline Hamesse à l'occasion de son
+éméritat*, edited by José Francisco Meirinhos and Olga Weijers, 155--74.
+Textes et études du moyen âge 50. Louvain-la-Neuve: Fédération
+Internationale des Instituts d'Études Médiévales.
+:::
+
+::: {#ref-thorndike:1955unde .csl-entry}
+Thorndike, Lynn. 1955. "Unde versus." *Traditio* 11: 163--93.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-75.md b/test/command/pandoc-citeproc-75.md
new file mode 100644
index 000000000..0771fa971
--- /dev/null
+++ b/test/command/pandoc-citeproc-75.md
@@ -0,0 +1,67 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/apa.csl
+references:
+- author:
+ - family: Doe
+ given: John
+ id: test
+ issued:
+ date-parts:
+ - - 2006
+ title: Test
+ type: 'article-journal'
+ volume: 81
+---
+
+[@test, p. 6]
+
+[@test, chap. 6]
+
+[@test, n. 6]
+
+[@test, pp. 34-36, 38-39]
+
+[@test, sec. 3]
+
+[@test, p.3]
+
+[@test, 33-35, 38-39]
+
+[@test, 14]
+
+[@test bk. VI]
+
+[@test, no. 6]
+
+[@test, nos. 6 and 7]
+^D
+(Doe, 2006, p. 6)
+
+(Doe, 2006, Chapter 6)
+
+(Doe, 2006, n. 6)
+
+(Doe, 2006, pp. 34--36, 38--39)
+
+(Doe, 2006, sec. 3)
+
+(Doe, 2006, p. 3)
+
+(Doe, 2006, pp. 33--35, 38--39)
+
+(Doe, 2006, p. 14)
+
+(Doe, 2006, bk. VI)
+
+(Doe, 2006, no. 6)
+
+(Doe, 2006, no. 6 and 7)
+
+::: {#refs .references .csl-bib-body .hanging-indent line-spacing="2"}
+::: {#ref-test .csl-entry}
+Doe, J. (2006). Test, *81*.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-76.md b/test/command/pandoc-citeproc-76.md
new file mode 100644
index 000000000..a184b3e79
--- /dev/null
+++ b/test/command/pandoc-citeproc-76.md
@@ -0,0 +1,64 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ - family: Author
+ given: Al
+ id: item1
+ issued:
+ date-parts:
+ - - 1998
+ title: 'foo bar baz: bazbaz bar foo'
+ type: 'article-journal'
+- author:
+ - family: Author
+ given: Al
+ id: item2
+ issued:
+ date-parts:
+ - - 1998
+ title: 'foo bar baz: the bazbaz bar foo'
+ type: 'article-journal'
+- author:
+ - family: Author
+ given: Al
+ id: item3
+ issued:
+ date-parts:
+ - - 1998
+ title: 'foo bar baz: a bazbaz bar foo'
+ type: 'article-journal'
+- author:
+ - family: Author
+ given: Al
+ id: item4
+ issued:
+ date-parts:
+ - - 1998
+ title: 'foo bar baz: an abazbaz bar foo'
+ type: 'article-journal'
+---
+
+@item1, @item2, @item3, @item4
+^D
+Author (1998c), Author (1998d), Author (1998a), Author (1998b)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item3 .csl-entry}
+Author, Al. 1998a. "Foo Bar Baz: A Bazbaz Bar Foo."
+:::
+
+::: {#ref-item4 .csl-entry}
+---------. 1998b. "Foo Bar Baz: An Abazbaz Bar Foo."
+:::
+
+::: {#ref-item1 .csl-entry}
+---------. 1998c. "Foo Bar Baz: Bazbaz Bar Foo."
+:::
+
+::: {#ref-item2 .csl-entry}
+---------. 1998d. "Foo Bar Baz: The Bazbaz Bar Foo."
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-77.md b/test/command/pandoc-citeproc-77.md
new file mode 100644
index 000000000..d7090edb4
--- /dev/null
+++ b/test/command/pandoc-citeproc-77.md
@@ -0,0 +1,67 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chicago-fullnote-bibliography.csl'
+references:
+- author:
+ - family: Doe
+ given: 'John, III'
+ parse-names: true
+ id: item1
+ type: book
+- author:
+ - family: van Gogh
+ given: Vincent
+ parse-names: true
+ id: item2
+ type: book
+- author:
+ - family: Humboldt
+ given: Alexander von
+ parse-names: true
+ id: item3
+ type: book
+- author:
+ - family: Bennett
+ given: 'Frank G.,! Jr.'
+ parse-names: true
+ id: item4
+ type: book
+- author:
+ - family: Dumboldt
+ given: 'Ezekiel, III'
+ parse-names: true
+ id: item5
+ type: book
+---
+
+[@item1; @item2; @item3; @item4; @item5]
+^D
+[^1]
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item4 .csl-entry}
+Bennett, Frank G., Jr., n.d.
+:::
+
+::: {#ref-item1 .csl-entry}
+Doe, John, III, n.d.
+:::
+
+::: {#ref-item5 .csl-entry}
+Dumboldt, Ezekiel, III, n.d.
+:::
+
+::: {#ref-item3 .csl-entry}
+Humboldt, Alexander von, n.d.
+:::
+
+::: {#ref-item2 .csl-entry}
+van Gogh, Vincent, n.d.
+:::
+:::
+
+[^1]: John Doe III, n.d.; Vincent van Gogh, n.d.; Alexander von
+ Humboldt, n.d.; Frank G. Bennett, Jr., n.d.; Ezekiel Dumboldt III,
+ n.d.
+```
diff --git a/test/command/pandoc-citeproc-82.md b/test/command/pandoc-citeproc-82.md
new file mode 100644
index 000000000..3464ae063
--- /dev/null
+++ b/test/command/pandoc-citeproc-82.md
@@ -0,0 +1,40 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chicago-annotated-bibliography.csl'
+references:
+- URL: 'https://www.worldcat.org/'
+ accessed:
+ date-parts:
+ - - 2014
+ - 9
+ - 19
+ author:
+ - literal: OCLC
+ first-reference-note-number: 1
+ id: OCLC_i1099
+ title: WorldCat
+ type: webpage
+---
+
+Title
+=====
+
+Some text.[^1]
+
+[^1]: Comment regarding text, supported by citation [@OCLC_i1099]
+^D
+Title
+=====
+
+Some text.[^1]
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-OCLC_i1099 .csl-entry}
+OCLC. "WorldCat." Accessed September 19, 2014.
+<https://www.worldcat.org/>.
+:::
+:::
+
+[^1]: Comment regarding text, supported by citation (OCLC, "WorldCat.")
+```
diff --git a/test/command/pandoc-citeproc-87.md b/test/command/pandoc-citeproc-87.md
new file mode 100644
index 000000000..1a736ca51
--- /dev/null
+++ b/test/command/pandoc-citeproc-87.md
@@ -0,0 +1,157 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- URL: 'http://www.example.com'
+ author:
+ - family: Doe
+ given: John
+ container-title: The Web Site
+ id: item1
+ issued:
+ date-parts:
+ - - 2006
+ - 10
+ - 26
+ title: Title
+ type: webpage
+- URL: 'http://www.example.com'
+ author:
+ - family: Doe
+ given: John
+ container-title: The Web Site
+ id: item2
+ issued:
+ date-parts:
+ - - 2006
+ - 10
+ - 26
+ - - 2006
+ - 11
+ - 27
+ title: Title
+ type: webpage
+- URL: 'http://www.example.com'
+ author:
+ - family: Doe
+ given: John
+ container-title: The Web Site
+ id: item2a
+ issued:
+ date-parts:
+ - - 2006
+ - 10
+ - - 2006
+ - 11
+ title: Title
+ type: webpage
+- URL: 'http://www.example.com'
+ author:
+ - family: Doe
+ given: John
+ container-title: The Web Site
+ id: item2b
+ issued:
+ date-parts:
+ - - 2006
+ - 12
+ - 31
+ - - 2007
+ - 1
+ - 1
+ title: Title
+ type: webpage
+- URL: 'http://www.example.com'
+ author:
+ - family: Doe
+ given: John
+ container-title: The Newspaper
+ id: item3
+ issued:
+ date-parts:
+ - - 2006
+ - 10
+ - 26
+ - - 2006
+ - 11
+ - 27
+ title: Title
+ type: 'article-newspaper'
+- URL: 'http://www.example.com'
+ author:
+ - family: Doe
+ given: John
+ container-title: The Newspaper
+ id: item3b
+ issued:
+ date-parts:
+ - - 2006
+ - 10
+ - - 2006
+ - 11
+ title: Title
+ type: 'article-newspaper'
+---
+
+@item1 -- webpage, date
+
+@item2 -- webpage, date range
+
+@item2a -- webpage, date range YM
+
+@item2b -- webpage, date range across years
+
+@item3 -- article-newspaper
+
+@item3b -- article-newspaper YM
+
+References
+==========
+^D
+Doe (2006c) -- webpage, date
+
+Doe (2006d) -- webpage, date range
+
+Doe (2006a) -- webpage, date range YM
+
+Doe (2006--2007) -- webpage, date range across years
+
+Doe (2006e) -- article-newspaper
+
+Doe (2006b) -- article-newspaper YM
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item2a .csl-entry}
+Doe, John. 2006a. "Title." The Web Site. October--November 2006.
+<http://www.example.com>.
+:::
+
+::: {#ref-item3b .csl-entry}
+---------. 2006b. "Title." *The Newspaper*, October--November 2006.
+<http://www.example.com>.
+:::
+
+::: {#ref-item1 .csl-entry}
+---------. 2006c. "Title." The Web Site. October 26, 2006.
+<http://www.example.com>.
+:::
+
+::: {#ref-item2 .csl-entry}
+---------. 2006d. "Title." The Web Site. October 26--November 27, 2006.
+<http://www.example.com>.
+:::
+
+::: {#ref-item3 .csl-entry}
+---------. 2006e. "Title." *The Newspaper*, October 26--November 27,
+2006. <http://www.example.com>.
+:::
+
+::: {#ref-item2b .csl-entry}
+---------. 2006--2007. "Title." The Web Site. December 31, 2006--January
+1, 2007. <http://www.example.com>.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-chicago-author-date.md b/test/command/pandoc-citeproc-chicago-author-date.md
new file mode 100644
index 000000000..2840f4435
--- /dev/null
+++ b/test/command/pandoc-citeproc-chicago-author-date.md
@@ -0,0 +1,111 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+bibliography: command/biblio.bib
+link-citations: true
+---
+
+Pandoc with citeproc-hs
+=======================
+
+[@nonexistent]
+
+@nonexistent
+
+@item1 says blah.
+
+@item1 [p. 30] says blah.
+
+@item1 [p. 30, with suffix] says blah.
+
+@item1 [-@item2 p. 30; see also @пункт3] says blah.
+
+In a note.[^1]
+
+A citation group [see @item1 chap. 3; also @пункт3 p. 34-35].
+
+Another one [see @item1 p. 34-35].
+
+And another one in a note.[^2]
+
+Citation with a suffix and locator [@item1 pp. 33, 35-37, and nowhere
+else].
+
+Citation with suffix only [@item1 and nowhere else].
+
+Now some modifiers.[^3]
+
+With some markup [*see* @item1 p. **32**].
+
+References {#references .unnumbered}
+==========
+
+[^1]: @пункт3 [p. 12] and a citation without locators [@пункт3].
+
+[^2]: Some citations [see @item1 chap. 3; @пункт3; @item2].
+
+[^3]: Like a citation without author: [-@item1], and now Doe with a
+ locator [-@item2 p. 44].
+^D
+[WARNING] Citeproc: citation nonexistent not found
+Pandoc with citeproc-hs
+=======================
+
+([**nonexistent?**](#ref-nonexistent))
+
+([**nonexistent?**](#ref-nonexistent))
+
+[Doe](#ref-item1) ([2005](#ref-item1)) says blah.
+
+[Doe](#ref-item1) ([2005, 30](#ref-item1)) says blah.
+
+[Doe](#ref-item1) ([2005, 30](#ref-item1), with suffix) says blah.
+
+[Doe](#ref-item1) ([2005](#ref-item1), [2006, 30](#ref-item2); see also
+[Doe and Roe 2007](#ref-пункт3)) says blah.
+
+In a note.[^1]
+
+A citation group (see [Doe 2005, chap. 3](#ref-item1); also [Doe and Roe
+2007, 34--35](#ref-пункт3)).
+
+Another one (see [Doe 2005, 34--35](#ref-item1)).
+
+And another one in a note.[^2]
+
+Citation with a suffix and locator ([Doe 2005, 33, 35--37](#ref-item1),
+and nowhere else).
+
+Citation with suffix only ([Doe 2005](#ref-item1) and nowhere else).
+
+Now some modifiers.[^3]
+
+With some markup (*see* [Doe 2005, 32](#ref-item1)).
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+Doe, John. 2005. *First Book*. Cambridge: Cambridge University Press.
+:::
+
+::: {#ref-item2 .csl-entry}
+---------. 2006. "Article." *Journal of Generic Studies* 6: 33--34.
+:::
+
+::: {#ref-пункт3 .csl-entry}
+Doe, John, and Jenny Roe. 2007. "Why Water Is Wet." In *Third Book*,
+edited by Sam Smith. Oxford: Oxford University Press.
+:::
+:::
+
+[^1]: [Doe and Roe](#ref-пункт3) ([2007, 12](#ref-пункт3)) and a
+ citation without locators ([Doe and Roe 2007](#ref-пункт3)).
+
+[^2]: Some citations (see [Doe 2005, chap. 3](#ref-item1); [Doe and Roe
+ 2007](#ref-пункт3); [Doe 2006](#ref-item2)).
+
+[^3]: Like a citation without author: ([2005](#ref-item1)), and now Doe
+ with a locator ([2006, 44](#ref-item2)).
+```
diff --git a/test/command/pandoc-citeproc-chicago-fullnote-bibliography.md b/test/command/pandoc-citeproc-chicago-fullnote-bibliography.md
new file mode 100644
index 000000000..ef690d91d
--- /dev/null
+++ b/test/command/pandoc-citeproc-chicago-fullnote-bibliography.md
@@ -0,0 +1,134 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+bibliography: command/biblio.bib
+csl: 'command/chicago-fullnote-bibliography.csl'
+link-citations: true
+---
+
+Pandoc with citeproc-hs
+=======================
+
+[@nonexistent]
+
+@nonexistent
+
+@item1 says blah.
+
+@item1 [p. 30] says blah.
+
+@item1 [p. 30, with suffix] says blah.
+
+@item1 [-@item2 p. 30; see also @пункт3] says blah.
+
+In a note.[^1]
+
+A citation group [see @item1 chap. 3; also @пункт3 p. 34-35].
+
+Another one [see @item1 p. 34-35].
+
+And another one in a note.[^2]
+
+Citation with a suffix and locator [@item1 pp. 33, 35-37, and nowhere
+else].
+
+Citation with suffix only [@item1 and nowhere else].
+
+Now some modifiers.[^3]
+
+With some markup [*see* @item1 p. **32**].
+
+References {#references .unnumbered}
+==========
+
+[^1]: @пункт3 [p. 12] and a citation without locators [@пункт3].
+
+[^2]: Some citations [see @item1 chap. 3; @пункт3; @item2].
+
+[^3]: Like a citation without author: [-@item1], and again
+ [-@item1], and now Doe with a locator [-@item2 p. 44].
+^D
+[WARNING] Citeproc: citation nonexistent not found
+Pandoc with citeproc-hs
+=======================
+
+[^1]
+
+[^2]
+
+[Doe](#ref-item1)[^3] says blah.
+
+[Doe](#ref-item1)[^4] says blah.
+
+[Doe](#ref-item1)[^5] says blah.
+
+[Doe](#ref-item1)[^6] says blah.
+
+In a note.[^7]
+
+A citation group.[^8]
+
+Another one.[^9]
+
+And another one in a note.[^10]
+
+Citation with a suffix and locator.[^11]
+
+Citation with suffix only.[^12]
+
+Now some modifiers.[^13]
+
+With some markup.[^14]
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item2 .csl-entry}
+Doe, John. "Article." *Journal of Generic Studies* 6 (2006): 33--34.
+:::
+
+::: {#ref-item1 .csl-entry}
+---------. *First Book*. Cambridge: Cambridge University Press, 2005.
+:::
+
+::: {#ref-пункт3 .csl-entry}
+Doe, John, and Jenny Roe. "Why Water Is Wet." In *Third Book*, edited by
+Sam Smith. Oxford: Oxford University Press, 2007.
+:::
+:::
+
+[^1]: [**Nonexistent?**](#ref-nonexistent)
+
+[^2]: [**Nonexistent?**](#ref-nonexistent)
+
+[^3]: [2005](#ref-item1).
+
+[^4]: [Ibid., 30](#ref-item1).
+
+[^5]: [Ibid.](#ref-item1), with suffix.
+
+[^6]: [2005](#ref-item1); [2006, 30](#ref-item2); see also [Doe and
+ Roe](#ref-пункт3).
+
+[^7]: [Doe and Roe](#ref-пункт3) ([12](#ref-пункт3)) and a citation
+ without locators ([Doe and Roe](#ref-пункт3)).
+
+[^8]: See [Doe, 2005, chap. 3](#ref-item1); also [Doe and Roe,
+ 34--35](#ref-пункт3).
+
+[^9]: See [Doe, 2005, 34--35](#ref-item1).
+
+[^10]: Some citations (See [ibid., chap. 3](#ref-item1); [Doe and
+ Roe](#ref-пункт3); [Doe, 2006](#ref-item2)).
+
+[^11]: [Doe, 2005, 33, 35--37](#ref-item1), and nowhere else.
+
+[^12]: [Doe, 2005](#ref-item1) and nowhere else.
+
+[^13]: Like a citation without author: ([Ibid.](#ref-item1)), and again
+ ([Ibid.](#ref-item1)), and now Doe with a locator ([2006,
+ 44](#ref-item2)).
+
+[^14]: *See* [Doe, 2005, 32](#ref-item1).
+```
diff --git a/test/command/pandoc-citeproc-ieee.md b/test/command/pandoc-citeproc-ieee.md
new file mode 100644
index 000000000..653e1e0b5
--- /dev/null
+++ b/test/command/pandoc-citeproc-ieee.md
@@ -0,0 +1,115 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+bibliography: command/biblio.bib
+csl: command/ieee.csl
+link-citations: true
+---
+
+Pandoc with citeproc-hs
+=======================
+
+[@nonexistent]
+
+@nonexistent
+
+@item1 says blah.
+
+@item1 [p. 30] says blah.
+
+@item1 [p. 30, with suffix] says blah.
+
+@item1 [-@item2 p. 30; see also @пункт3] says blah.
+
+In a note.[^1]
+
+A citation group [see @item1 chap. 3; also @пункт3 p. 34-35].
+
+Another one [see @item1 p. 34-35].
+
+And another one in a note.[^2]
+
+Citation with a suffix and locator [@item1 pp. 33, 35-37, and nowhere
+else].
+
+Citation with suffix only [@item1 and nowhere else].
+
+Now some modifiers.[^3]
+
+With some markup [*see* @item1 p. **32**].
+
+References {#references .unnumbered}
+==========
+
+[^1]: @пункт3 [p. 12] and a citation without locators [@пункт3].
+
+[^2]: Some citations [see @item1 chap. 3; @пункт3; @item2].
+
+[^3]: Like a citation without author: [-@item1], and now Doe with a
+ locator [-@item2 p. 44].
+^D
+[WARNING] Citeproc: citation nonexistent not found
+Pandoc with citeproc-hs
+=======================
+
+[**nonexistent?**](#ref-nonexistent)
+
+[**nonexistent?**](#ref-nonexistent)
+
+[\[1\]](#ref-item1) says blah.
+
+[\[1, p. 30\]](#ref-item1) says blah.
+
+[\[1, p. 30\]](#ref-item1), with suffix says blah.
+
+[\[1\]](#ref-item1), [\[2, p. 30\]](#ref-item2), see also
+[\[3\]](#ref-пункт3) says blah.
+
+In a note.[^1]
+
+A citation group see [\[1, Ch. 3\]](#ref-item1), also [\[3, pp.
+34--35\]](#ref-пункт3).
+
+Another one see [\[1, pp. 34--35\]](#ref-item1).
+
+And another one in a note.[^2]
+
+Citation with a suffix and locator [\[1, pp. 33, 35--37\]](#ref-item1),
+and nowhere else.
+
+Citation with suffix only [\[1\]](#ref-item1) and nowhere else.
+
+Now some modifiers.[^3]
+
+With some markup *see* [\[1, p. 32\]](#ref-item1).
+
+References {#references .unnumbered}
+==========
+
+::: {#refs .references .csl-bib-body}
+::: {#ref-item1 .csl-entry}
+[\[1\]]{.csl-left-margin}[J. Doe, *First book*. Cambridge: Cambridge
+University Press, 2005.]{.csl-right-inline}
+:::
+
+::: {#ref-item2 .csl-entry}
+[\[2\]]{.csl-left-margin}[J. Doe, "Article," *Journal of Generic
+Studies*, vol. 6, pp. 33--34, 2006.]{.csl-right-inline}
+:::
+
+::: {#ref-пункт3 .csl-entry}
+[\[3\]]{.csl-left-margin}[J. Doe and J. Roe, "Why water is wet," in
+*Third book*, S. Smith, Ed. Oxford: Oxford University Press,
+2007.]{.csl-right-inline}
+:::
+:::
+
+[^1]: [\[3, p. 12\]](#ref-пункт3) and a citation without locators
+ [\[3\]](#ref-пункт3).
+
+[^2]: Some citations see [\[1, Ch. 3\]](#ref-item1),
+ [\[2\]](#ref-item2), [\[3\]](#ref-пункт3).
+
+[^3]: Like a citation without author: [\[1\]](#ref-item1), and now Doe
+ with a locator [\[2, p. 44\]](#ref-item2).
+```
diff --git a/test/command/pandoc-citeproc-locators-delimited.md b/test/command/pandoc-citeproc-locators-delimited.md
new file mode 100644
index 000000000..97db169b9
--- /dev/null
+++ b/test/command/pandoc-citeproc-locators-delimited.md
@@ -0,0 +1,127 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/locators.csl
+references:
+- id: citekey
+ title: Title
+ type: 'article-journal'
+suppress-bibliography: true
+---
+
+See <https://github.com/jgm/pandoc-citeproc/pull/362>.
+
+Standard page range[@citekey {35-89, 102}]
+
+Alphanumeric[@citekey {abcdefg1234}]
+
+Kitchen sink[@citekey, {123(4)a-8(\[a\]12.398{8})}]
+
+Empty braces inside[@citekey, {{}}]
+
+Label specified[@citekey {p. a}]
+
+Should it work outside? No. [@citekey, p. {(a)}]
+
+Empty locator [@citekey, {}]
+
+Empty locator to force suffix[@citekey {} 123-35 numbers are suffix]
+
+Suffix generally [@citekey {123-35} numbers not, but text is suffix]
+
+With preceding comma[@citekey, {p. VI}]
+
+No commas before label[@citekey, {, p. (p. is not recognised)}]
+
+Trim white space[@citekey, { p. 9 }]
+
+Without delimiters[@citekey, suffix]
+
+With rendering label[@citekey {ss IV div 4 s 128L(7)(a)(i)-(iv), 129(5),
+130(b)}]
+
+The text is apparently NOT verbatim; it is lightly processed as page
+numbers. [@citekey {no comma, no label, no nothing}]
+
+AGLC-style page \[para\] [@citekey {584 \[78\]}]
+
+Unbalanced curly { breaks the parse[@citekey {p. suffix{suffix}suffix]
+
+Unbalanced curly } ends early[@citekey {green}suffix}suffix]
+^D
+See <https://github.com/jgm/pandoc-citeproc/pull/362>.
+
+Standard page range[^1]
+
+Alphanumeric[^2]
+
+Kitchen sink[^3]
+
+Empty braces inside[^4]
+
+Label specified[^5]
+
+Should it work outside? No.[^6]
+
+Empty locator[^7]
+
+Empty locator to force suffix[^8]
+
+Suffix generally[^9]
+
+With preceding comma[^10]
+
+No commas before label[^11]
+
+Trim white space[^12]
+
+Without delimiters[^13]
+
+With rendering label[^14]
+
+The text is apparently NOT verbatim; it is lightly processed as page
+numbers.[^15]
+
+AGLC-style page \[para\][^16]
+
+Unbalanced curly { breaks the parse[^17]
+
+Unbalanced curly } ends early[^18]
+
+[^1]: Title {35--89, 102}.
+
+[^2]: Ibid-with-locator {abcdefg1234}.
+
+[^3]: Ibid-with-locator {123(4)a--8(\[a\]12.398{8})}.
+
+[^4]: Ibid-with-locator {{}}.
+
+[^5]: Ibid-with-locator {a}.
+
+[^6]: Subsequent, p. {(a)}.
+
+[^7]: Ibid-with-locator.
+
+[^8]: Ibid 123-35 numbers are suffix.
+
+[^9]: Ibid-with-locator {123--35} numbers not, but text is suffix.
+
+[^10]: Ibid-with-locator {VI}.
+
+[^11]: Ibid-with-locator {, p. (p. is not recognised)}.
+
+[^12]: Ibid-with-locator {9}.
+
+[^13]: Subsequent, suffix.
+
+[^14]: Ibid-with-locator ss {IV div 4 s 128L(7)(a)(i)--(iv), 129(5),
+ 130(b)}.
+
+[^15]: Ibid-with-locator {no comma, no label, no nothing}.
+
+[^16]: Ibid-with-locator {584 \[78\]}.
+
+[^17]: Subsequent {p. suffix{suffix}suffix.
+
+[^18]: Ibid-with-locator {green}suffix}suffix.
+```
diff --git a/test/command/pandoc-citeproc-locators-integrated.md b/test/command/pandoc-citeproc-locators-integrated.md
new file mode 100644
index 000000000..64490e376
--- /dev/null
+++ b/test/command/pandoc-citeproc-locators-integrated.md
@@ -0,0 +1,159 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: command/locators.csl
+references:
+- id: citekey
+ title: Title
+ type: 'article-journal'
+suppress-bibliography: true
+---
+
+See <https://github.com/jgm/pandoc-citeproc/pull/362>.
+
+[@citekey, 89, and suffix]
+
+[@citekey, 89, perfect Ibid with suffix]
+
+[@citekey, 123-79, and suffix]
+
+[@citekey, xi, will be entirely suffix]
+
+[@citekey, p. xi, gives you a (page) locator xi]
+
+[@citekey, pp. VII, 89, gives you a (pages) locator VII, 89]
+
+[@citekey, p. VI, VII, VIII-IX, explicit romans]
+
+[@citekey \[89\]]
+
+[@citekey, p. \[89\]]
+
+[@citekey and nothing else].
+
+[@citekey, 123(4)\[5\]6, and suffix]
+
+[@citekey, 3(a), 4.4.8, \[7.6\], 7A(2)(a)(i)-(iv)]
+
+[@citekey, 4B.2a.i(3.4), and suffix]
+
+[@citekey, IV.2A, and suffix]
+
+[@citekey, \[28\], and suffix]
+
+[@citekey, \[39-52\], and suffix]
+
+[@citekey, \[39\]-\[52\], and suffix]
+
+[@citekey, s 123(4)(a)(iv), and suffix]
+
+[@citekey, ss 123(4)-(6), and suffix]
+
+[@citekey, \[13\], and suffix]
+
+[@citekey, p.3, and suffix]
+
+[@citekey, (13 entirely suffix]
+
+[@citekey, p.a entirely suffix]
+
+[@citekey, s (a) entirely suffix]
+^D
+See <https://github.com/jgm/pandoc-citeproc/pull/362>.
+
+[^1]
+
+[^2]
+
+[^3]
+
+[^4]
+
+[^5]
+
+[^6]
+
+[^7]
+
+[^8]
+
+[^9]
+
+.[^10]
+
+[^11]
+
+[^12]
+
+[^13]
+
+[^14]
+
+[^15]
+
+[^16]
+
+[^17]
+
+[^18]
+
+[^19]
+
+[^20]
+
+[^21]
+
+[^22]
+
+[^23]
+
+[^24]
+
+[^1]: Title {89}, and suffix.
+
+[^2]: Ibid, perfect Ibid with suffix.
+
+[^3]: Ibid-with-locator {123--79}, and suffix.
+
+[^4]: Subsequent, xi, will be entirely suffix.
+
+[^5]: Ibid-with-locator {xi}, gives you a (page) locator xi.
+
+[^6]: Ibid-with-locator {VII, 89}, gives you a (pages) locator VII, 89.
+
+[^7]: Ibid-with-locator {VI, VII, VIII--IX}, explicit romans.
+
+[^8]: Ibid-with-locator {\[89\]}.
+
+[^9]: Ibid.
+
+[^10]: Subsequent and nothing else.
+
+[^11]: Ibid-with-locator {123(4)\[5\]6}, and suffix.
+
+[^12]: Ibid-with-locator {3(a), 4.4.8, \[7.6\], 7A(2)(a)(i)--(iv)}.
+
+[^13]: Ibid-with-locator {4B.2a.i(3.4)}, and suffix.
+
+[^14]: Ibid-with-locator {IV.2A}, and suffix.
+
+[^15]: Ibid-with-locator {\[28\]}, and suffix.
+
+[^16]: Ibid-with-locator {\[39--52\]}, and suffix.
+
+[^17]: Ibid-with-locator {\[39\]--\[52\]}, and suffix.
+
+[^18]: Ibid-with-locator s {123(4)(a)(iv)}, and suffix.
+
+[^19]: Ibid-with-locator ss {123(4)--(6)}, and suffix.
+
+[^20]: Ibid-with-locator {\[13\]}, and suffix.
+
+[^21]: Ibid-with-locator {3}, and suffix.
+
+[^22]: Subsequent, (13 entirely suffix.
+
+[^23]: Ibid, p.a entirely suffix.
+
+[^24]: Ibid, s (a) entirely suffix.
+```
diff --git a/test/command/pandoc-citeproc-move-period-inside-quote.md b/test/command/pandoc-citeproc-move-period-inside-quote.md
new file mode 100644
index 000000000..e08c6b00f
--- /dev/null
+++ b/test/command/pandoc-citeproc-move-period-inside-quote.md
@@ -0,0 +1,53 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chicago-fullnote-bibliography.csl'
+references:
+- DOI: 10.1038/171737a0
+ URL: 'http://www.nature.com/nature/journal/v171/n4356/abs/171737a0.html'
+ accessed:
+ day: 17
+ month: 6
+ year: 2008
+ author:
+ - family: Watson
+ given: J. D.
+ - family: Crick
+ given: F. H. C.
+ container-title: Nature
+ custom4: custom4
+ id: WatsonCrick1953
+ issue: 4356
+ issued:
+ date-parts:
+ - - 1953
+ - 4
+ - 25
+ language: 'en-US'
+ note: this is a note
+ original-date:
+ year: 1951
+ page: '737-738'
+ title: 'Molecular structure of nucleic acids: a structure for
+ deoxyribose nucleic acid'
+ title-short: Molecular structure of nucleic acids
+ type: 'article-journal'
+ volume: 171
+suppress-bibliography: true
+---
+
+Here is a "test citation" [@WatsonCrick1953].
+
+Here is a test citation [@WatsonCrick1953].
+^D
+Here is a "test citation."[^1]
+
+Here is a test citation.[^2]
+
+[^1]: J. D. Watson and F. H. C. Crick, "Molecular Structure of Nucleic
+ Acids: A Structure for Deoxyribose Nucleic Acid," *Nature* 171, no.
+ 4356 (April 25, 1953): 737--38,
+ doi:[10.1038/171737a0](https://doi.org/10.1038/171737a0).
+
+[^2]: Ibid.
+```
diff --git a/test/command/pandoc-citeproc-no-author.md b/test/command/pandoc-citeproc-no-author.md
new file mode 100644
index 000000000..fb832d446
--- /dev/null
+++ b/test/command/pandoc-citeproc-no-author.md
@@ -0,0 +1,73 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- container-title: Magazine
+ id: item1
+ issued:
+ year: 2012
+ title: Title A
+ type: 'article-magazine'
+- container-title: Magazine
+ id: item2
+ issued:
+ year: 2012
+ title: Title B
+ type: 'article-magazine'
+- container-title: Magazine
+ id: item3
+ issued:
+ year: 2012
+ title: Title C
+ type: 'article-magazine'
+- container-title: Magazine
+ id: item4
+ issued:
+ year: 2012
+ title: Title D
+ type: 'article-magazine'
+- container-title: Newspaper
+ id: item5
+ issued:
+ year: 2012
+ title: Title E
+ type: 'article-magazine'
+- container-title: Newspaper
+ id: item6
+ issued:
+ year: 2012
+ title: Title F
+ type: 'article-magazine'
+---
+
+@item1 [p. 3], @item2, @item3, @item4, @item5, @item6
+^D
+*Magazine* (2012a, 3), *Magazine* (2012b), *Magazine* (2012c),
+*Magazine* (2012d), *Newspaper* (2012a), *Newspaper* (2012b)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+*Magazine*. 2012a. "Title A," 2012.
+:::
+
+::: {#ref-item2 .csl-entry}
+---------. 2012b. "Title B," 2012.
+:::
+
+::: {#ref-item3 .csl-entry}
+---------. 2012c. "Title C," 2012.
+:::
+
+::: {#ref-item4 .csl-entry}
+---------. 2012d. "Title D," 2012.
+:::
+
+::: {#ref-item5 .csl-entry}
+*Newspaper*. 2012a. "Title E," 2012.
+:::
+
+::: {#ref-item6 .csl-entry}
+---------. 2012b. "Title F," 2012.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-number-of-volumes.md b/test/command/pandoc-citeproc-number-of-volumes.md
new file mode 100644
index 000000000..2ac5866e2
--- /dev/null
+++ b/test/command/pandoc-citeproc-number-of-volumes.md
@@ -0,0 +1,29 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+references:
+- author:
+ family: Author
+ given:
+ - Al
+ id: item1
+ issued:
+ year: 2013
+ language: 'en-US'
+ number-of-volumes: 2
+ publisher: Publisher
+ publisher-place: Location
+ title: Title
+ type: book
+---
+
+@item1
+^D
+Author (2013)
+
+::: {#refs .references .csl-bib-body .hanging-indent}
+::: {#ref-item1 .csl-entry}
+Author, Al. 2013. *Title*. 2 vols. Location: Publisher.
+:::
+:::
+```
diff --git a/test/command/pandoc-citeproc-page-range.md b/test/command/pandoc-citeproc-page-range.md
new file mode 100644
index 000000000..5a46c5f03
--- /dev/null
+++ b/test/command/pandoc-citeproc-page-range.md
@@ -0,0 +1,32 @@
+```
+% pandoc --citeproc -t markdown-citations
+---
+csl: 'command/chicago-fullnote-bibliography.csl'
+references:
+- URL: 'https://johnmacfarlane.net/vagueness.pdf'
+ id: test1
+- URL: 'https://pandoc.org'
+ id: test2
+- URL: 'https://johnmacfarlane.net'
+ id: test3
+suppress-bibliography: true
+---
+
+Test 1 [@test1, pp. 93--101].
+
+Test 2 [@test2, pp. 93--101].
+
+Test 3 [@test3, pp. 93-101].
+^D
+Test 1.[^1]
+
+Test 2.[^2]
+
+Test 3.[^3]
+
+[^1]: 93--101, <https://johnmacfarlane.net/vagueness.pdf>.
+
+[^2]: 93--101, <https://pandoc.org>.
+
+[^3]: 93--101, <https://johnmacfarlane.net>.
+```
diff --git a/test/command/sage-harvard.csl b/test/command/sage-harvard.csl
new file mode 100644
index 000000000..2798c086a
--- /dev/null
+++ b/test/command/sage-harvard.csl
@@ -0,0 +1,202 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="never" default-locale="en-GB">
+ <info>
+ <title>SAGE - Harvard</title>
+ <id>http://www.zotero.org/styles/sage-harvard</id>
+ <link href="http://www.zotero.org/styles/sage-harvard" rel="self"/>
+ <link href="http://www.zotero.org/styles/the-open-university-harvard" rel="template"/>
+ <link href="http://www.uk.sagepub.com/repository/binaries/pdf/SAGE_Harvard_reference_style.pdf" rel="documentation"/>
+ <author>
+ <name>Joseph Reagle</name>
+ </author>
+ <category citation-format="author-date"/>
+ <category field="generic-base"/>
+ <summary>The SAGE Harvard author-date style</summary>
+ <updated>2012-09-27T22:06:38+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en-GB">
+ <terms>
+ <term name="editor" form="short">
+ <single>ed.</single>
+ <multiple>eds</multiple>
+ </term>
+ </terms>
+ </locale>
+ <macro name="editor">
+ <names variable="editor" delimiter=", ">
+ <name and="text" initialize-with="" delimiter=", " sort-separator=" " name-as-sort-order="all"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ </names>
+ </macro>
+ <macro name="author">
+ <names variable="author">
+ <name initialize-with="" name-as-sort-order="all" and="text" sort-separator=" " delimiter=", " delimiter-precedes-last="never" form="long"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text variable="container-title" font-style="italic"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="author-count">
+ <names variable="author">
+ <name form="count"/>
+ <substitute>
+ <names variable="editor"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="author-short">
+ <names variable="author">
+ <name form="short" and="text" delimiter=", " delimiter-precedes-last="never" initialize-with=""/>
+ <substitute>
+ <names variable="editor"/>
+ <names variable="translator"/>
+ <text variable="container-title" font-style="italic"/>
+ <text macro="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="access">
+ <choose>
+ <if variable="URL">
+ <text value="Available from: "/>
+ <text variable="URL"/>
+ <group prefix=" (" delimiter=" " suffix=")">
+ <text term="accessed"/>
+ <date variable="accessed">
+ <date-part name="day" suffix=" "/>
+ <date-part name="month" suffix=" "/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="bill book graphic legal_case motion_picture report song" match="any">
+ <text variable="title" font-style="italic"/>
+ </if>
+ <else>
+ <text variable="title"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <group delimiter=": ">
+ <text variable="publisher-place"/>
+ <text variable="publisher"/>
+ </group>
+ </macro>
+ <macro name="year-date">
+ <choose>
+ <if variable="issued">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </if>
+ <else>
+ <text term="no date" form="short"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="locator">
+ <choose>
+ <if type="article-journal">
+ <text variable="volume"/>
+ <text variable="issue" prefix="(" suffix=")"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="published-date">
+ <choose>
+ <if type="article-newspaper">
+ <date variable="issued">
+ <date-part name="day" form="ordinal" suffix=" "/>
+ <date-part name="month" form="long"/>
+ </date>
+ </if>
+ </choose>
+ </macro>
+ <macro name="pages">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <group delimiter=" " prefix=", ">
+ <label variable="page" form="short" suffix=" "/>
+ <text variable="page"/>
+ </group>
+ </if>
+ <else-if type="article-journal">
+ <text variable="page" prefix=": "/>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" suffix="."/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="container-prefix">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text term="in" text-case="capitalize-first" suffix=": "/>
+ </if>
+ </choose>
+ </macro>
+ <citation et-al-min="3" et-al-use-first="1" disambiguate-add-year-suffix="true" disambiguate-add-names="true" disambiguate-add-givenname="true" collapse="year">
+ <sort>
+ <key macro="author-short"/>
+ <key macro="year-date"/>
+ </sort>
+ <layout prefix="(" suffix=")" delimiter="; ">
+ <group delimiter=": ">
+ <group delimiter=", ">
+ <text macro="author-short"/>
+ <text macro="year-date"/>
+ </group>
+ <text variable="locator"/>
+ </group>
+ </layout>
+ </citation>
+ <bibliography hanging-indent="true" et-al-min="4" et-al-use-first="3">
+ <sort>
+ <key macro="author" names-min="1" names-use-first="1"/>
+ <key macro="author-count" names-min="3" names-use-first="3"/>
+ <key macro="author" names-min="3" names-use-first="1"/>
+ <key macro="year-date"/>
+ <key variable="title"/>
+ </sort>
+ <layout suffix=".">
+ <group delimiter=" ">
+ <text macro="author"/>
+ <text macro="year-date" prefix="(" suffix=")"/>
+ <text macro="title" suffix="."/>
+ <text macro="edition"/>
+ <text macro="container-prefix"/>
+ <group delimiter=", ">
+ <text macro="editor"/>
+ <text variable="container-title" font-style="italic"/>
+ <text variable="collection-title"/>
+ <text variable="genre"/>
+ <text macro="publisher"/>
+ <text macro="published-date"/>
+ </group>
+ <text macro="locator"/>
+ </group>
+ <text macro="pages"/>
+ <text macro="access" prefix=". "/>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/science.csl b/test/command/science.csl
new file mode 100644
index 000000000..2a9864cb2
--- /dev/null
+++ b/test/command/science.csl
@@ -0,0 +1,245 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="sort-only" default-locale="en-US">
+ <info>
+ <title>Science</title>
+ <id>http://www.zotero.org/styles/science</id>
+ <link href="http://www.zotero.org/styles/science" rel="self"/>
+ <link href="http://www.sciencemag.org/about/authors/prep/res/refs.dtl" rel="documentation"/>
+ <author>
+ <name>Julian Onions</name>
+ <email>julian.onions@gmail.com</email>
+ </author>
+ <contributor>
+ <name>Sebastian Karcher</name>
+ </contributor>
+ <contributor>
+ <name>Greg Barendt</name>
+ </contributor>
+ <category citation-format="numeric"/>
+ <category field="science"/>
+ <issn>0036-8075</issn>
+ <eissn>1095-9203</eissn>
+ <summary>The Science journal style.</summary>
+ <updated>2014-06-18T08:06:38+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <macro name="editor">
+ <names variable="editor" delimiter=", ">
+ <name initialize-with=". " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", " text-case="capitalize-first"/>
+ </names>
+ </macro>
+ <macro name="author">
+ <names variable="author">
+ <name sort-separator=", " initialize-with=". " delimiter=", " delimiter-precedes-last="always"/>
+ <label form="short" prefix=", " text-case="capitalize-first"/>
+ <et-al font-style="italic"/>
+ <substitute>
+ <names variable="editor"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="access">
+ <choose>
+ <if variable="page" match="none">
+ <text macro="access-value"/>
+ </if>
+ <else-if is-numeric="page" match="none">
+ <text macro="access-value"/>
+ </else-if>
+ </choose>
+ </macro>
+ <macro name="access-value">
+ <choose>
+ <if variable="DOI">
+ <text variable="DOI" prefix=", doi:"/>
+ </if>
+ <else>
+ <group prefix=" (" suffix=")">
+ <text value="available at "/>
+ <text variable="URL"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title">
+ <choose>
+ <if type="bill book graphic legal_case legislation motion_picture report song" match="any">
+ <text variable="title" font-style="italic"/>
+ </if>
+ <else>
+ <text variable="title"/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="article-details">
+ <group delimiter=", ">
+ <group delimiter=". ">
+ <text macro="title"/>
+ <text form="short" variable="container-title" font-style="italic"/>
+ <text variable="volume" font-weight="bold"/>
+ </group>
+ <text variable="page"/>
+ </group>
+ <text macro="issued" prefix=" (" suffix=")"/>
+ <text macro="access"/>
+ </macro>
+ <macro name="publisher">
+ <group delimiter=", ">
+ <text variable="publisher"/>
+ <text variable="publisher-place"/>
+ </group>
+ </macro>
+ <macro name="volume">
+ <text variable="volume" prefix="vol. "/>
+ </macro>
+ <macro name="pages">
+ <label variable="page" form="short" suffix=" "/>
+ <text variable="page" form="short"/>
+ </macro>
+ <macro name="issued">
+ <date variable="issued" delimiter=" ">
+ <date-part name="year"/>
+ </date>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <text term="edition" form="short"/>
+ <number variable="edition" form="numeric"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" suffix="."/>
+ </else>
+ </choose>
+ </macro>
+ <citation collapse="citation-number">
+ <sort>
+ <key variable="citation-number"/>
+ </sort>
+ <layout prefix="(" suffix=")" delimiter=", ">
+ <text variable="citation-number" font-style="italic"/>
+ </layout>
+ </citation>
+ <bibliography et-al-min="6" et-al-use-first="1" second-field-align="flush">
+ <layout suffix=".">
+ <text variable="citation-number" suffix=". "/>
+ <group delimiter=", ">
+ <text macro="author"/>
+ <choose>
+ <if type="thesis">
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <group>
+ <!-- Always print, even if no university given -->
+ <text value="thesis"/>
+ </group>
+ <text macro="publisher"/>
+ </group>
+ <text macro="issued" prefix="(" suffix=")"/>
+ </group>
+ </if>
+ <else-if type="bill book graphic legal_case legislation motion_picture song chapter paper-conference" match="any">
+ <group delimiter=" ">
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text term="in"/>
+ <text variable="container-title" font-style="italic"/>
+ </group>
+ <text macro="editor"/>
+ </group>
+ </if>
+ <else>
+ <text macro="title"/>
+ </else>
+ </choose>
+ <group prefix="(" suffix=")" delimiter="; ">
+ <group delimiter=", ">
+ <text macro="publisher"/>
+ <text macro="edition"/>
+ <text macro="issued"/>
+ </group>
+ <text variable="URL"/>
+ </group>
+ </group>
+ <group delimiter=" of ">
+ <group>
+ <label variable="volume" form="short" suffix=" "/>
+ <number variable="volume"/>
+ </group>
+ <text variable="collection-title" font-style="italic"/>
+ </group>
+ <choose>
+ <if type="chapter paper-conference" match="any">
+ <text macro="pages"/>
+ </if>
+ </choose>
+ </else-if>
+ <else-if type="article-journal">
+ <choose>
+ <if variable="page">
+ <choose>
+ <if is-numeric="page" match="none">
+ <group>
+ <group delimiter=", ">
+ <text variable="container-title" form="short" font-style="italic"/>
+ <group>
+ <text term="in press"/>
+ </group>
+ </group>
+ <text macro="access"/>
+ </group>
+ </if>
+ <else>
+ <text macro="article-details"/>
+ </else>
+ </choose>
+ </if>
+ <else>
+ <text macro="article-details"/>
+ </else>
+ </choose>
+ </else-if>
+ <else-if type="report">
+ <group>
+ <group delimiter=", ">
+ <text variable="title" quotes="true"/>
+ <text variable="collection-title" font-style="italic"/>
+ </group>
+ <group prefix=" (" suffix=")" delimiter=", ">
+ <group delimiter=" ">
+ <text variable="genre" form="short"/>
+ <number variable="number"/>
+ </group>
+ <text variable="publisher"/>
+ <text variable="publisher-place"/>
+ <text macro="issued"/>
+ </group>
+ </group>
+ <text macro="pages"/>
+ <text macro="access"/>
+ </else-if>
+ <else>
+ <group>
+ <group delimiter=", ">
+ <text macro="editor"/>
+ <group delimiter=". ">
+ <text macro="title"/>
+ <text form="short" variable="container-title" font-style="italic"/>
+ <text variable="volume" font-weight="bold"/>
+ </group>
+ </group>
+ <text macro="issued" prefix=" (" suffix=")"/>
+ </group>
+ <text macro="pages"/>
+ <text macro="access"/>
+ </else>
+ </choose>
+ </group>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/style399.csl b/test/command/style399.csl
new file mode 100644
index 000000000..41a81f4e4
--- /dev/null
+++ b/test/command/style399.csl
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="never" default-locale="en-US">
+ <citation>
+ <sort>
+ <key variable="citation-number"/>
+ </sort>
+ <layout prefix="[" suffix="]" delimiter=",">
+ <text variable="citation-number"/>
+ </layout>
+ </citation>
+</style>
+
diff --git a/test/command/vancouver.csl b/test/command/vancouver.csl
new file mode 100644
index 000000000..edbb69b41
--- /dev/null
+++ b/test/command/vancouver.csl
@@ -0,0 +1,351 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="sort-only" page-range-format="minimal">
+ <info>
+ <title>Vancouver</title>
+ <id>http://www.zotero.org/styles/vancouver</id>
+ <link href="http://www.zotero.org/styles/vancouver" rel="self"/>
+ <link href="http://www.nlm.nih.gov/bsd/uniform_requirements.html" rel="documentation"/>
+ <author>
+ <name>Michael Berkowitz</name>
+ <email>mberkowi@gmu.edu</email>
+ </author>
+ <contributor>
+ <name>Sean Takats</name>
+ <email>stakats@gmu.edu</email>
+ </contributor>
+ <contributor>
+ <name>Sebastian Karcher</name>
+ </contributor>
+ <category citation-format="numeric"/>
+ <category field="medicine"/>
+ <summary>Vancouver style as outlined by International Committee of Medical Journal Editors Uniform Requirements for Manuscripts Submitted to Biomedical Journals: Sample References</summary>
+ <updated>2014-09-06T16:03:01+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="en">
+ <date form="text" delimiter=" ">
+ <date-part name="year"/>
+ <date-part name="month" form="short" strip-periods="true"/>
+ <date-part name="day"/>
+ </date>
+ <terms>
+ <term name="collection-editor" form="long">
+ <single>editor</single>
+ <multiple>editors</multiple>
+ </term>
+ <term name="presented at">presented at</term>
+ <term name="available at">available from</term>
+ <term name="section" form="short">sect.</term>
+ </terms>
+ </locale>
+ <locale xml:lang="fr">
+ <date form="text" delimiter=" ">
+ <date-part name="day"/>
+ <date-part name="month" form="short" strip-periods="true"/>
+ <date-part name="year"/>
+ </date>
+ </locale>
+ <macro name="author">
+ <names variable="author">
+ <name sort-separator=" " initialize-with="" name-as-sort-order="all" delimiter=", " delimiter-precedes-last="always"/>
+ <label form="long" prefix=", "/>
+ <substitute>
+ <names variable="editor"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="editor">
+ <names variable="editor" suffix=".">
+ <name sort-separator=" " initialize-with="" name-as-sort-order="all" delimiter=", " delimiter-precedes-last="always"/>
+ <label form="long" prefix=", "/>
+ </names>
+ </macro>
+ <macro name="chapter-marker">
+ <choose>
+ <if type="chapter paper-conference entry-dictionary entry-encyclopedia" match="any">
+ <text term="in" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="publisher">
+ <choose>
+ <!--discard publisher info for articles-->
+ <if type="article-journal article-magazine article-newspaper" match="none">
+ <group delimiter=": " suffix=";">
+ <choose>
+ <if type="thesis">
+ <text variable="publisher-place" prefix="[" suffix="]"/>
+ </if>
+ <else-if type="speech"/>
+ <else>
+ <text variable="publisher-place"/>
+ </else>
+ </choose>
+ <text variable="publisher"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="access">
+ <choose>
+ <if variable="URL">
+ <group delimiter=": ">
+ <text term="available at" text-case="capitalize-first"/>
+ <text variable="URL"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="accessed-date">
+ <choose>
+ <if variable="URL">
+ <group prefix="[" suffix="]" delimiter=" ">
+ <text term="cited" text-case="lowercase"/>
+ <date variable="accessed" form="text"/>
+ </group>
+ </if>
+ </choose>
+ </macro>
+ <macro name="container-title">
+ <choose>
+ <if type="article-journal article-magazine chapter paper-conference article-newspaper review review-book entry-dictionary entry-encyclopedia" match="any">
+ <group suffix="." delimiter=" ">
+ <choose>
+ <if type="article-journal review review-book" match="any">
+ <text variable="container-title" form="short" strip-periods="true"/>
+ </if>
+ <else>
+ <text variable="container-title" strip-periods="true"/>
+ </else>
+ </choose>
+ <choose>
+ <if variable="URL">
+ <text term="internet" prefix="[" suffix="]" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ </group>
+ <text macro="edition" prefix=" "/>
+ </if>
+ <!--add event-name and event-place once they become available-->
+ <else-if type="bill legislation" match="any">
+ <group delimiter=", ">
+ <group delimiter=". ">
+ <text variable="container-title"/>
+ <group delimiter=" ">
+ <text term="section" form="short" text-case="capitalize-first"/>
+ <text variable="section"/>
+ </group>
+ </group>
+ <text variable="number"/>
+ </group>
+ </else-if>
+ <else-if type="speech">
+ <group delimiter=": " suffix=";">
+ <group delimiter=" ">
+ <text variable="genre" text-case="capitalize-first"/>
+ <text term="presented at"/>
+ </group>
+ <text variable="event"/>
+ </group>
+ </else-if>
+ <else>
+ <group delimiter=", " suffix=".">
+ <choose>
+ <if variable="collection-title" match="none">
+ <group delimiter=" ">
+ <label variable="volume" form="short" text-case="capitalize-first"/>
+ <text variable="volume"/>
+ </group>
+ </if>
+ </choose>
+ <text variable="container-title"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="title">
+ <text variable="title"/>
+ <choose>
+ <if type="article-journal article-magazine chapter paper-conference article-newspaper review review-book entry-dictionary entry-encyclopedia" match="none">
+ <choose>
+ <if variable="URL">
+ <text term="internet" prefix=" [" suffix="]" text-case="capitalize-first"/>
+ </if>
+ </choose>
+ <text macro="edition" prefix=". "/>
+ </if>
+ </choose>
+ <choose>
+ <if type="thesis">
+ <text variable="genre" prefix=" [" suffix="]"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="edition">
+ <choose>
+ <if is-numeric="edition">
+ <group delimiter=" ">
+ <number variable="edition" form="ordinal"/>
+ <text term="edition" form="short"/>
+ </group>
+ </if>
+ <else>
+ <text variable="edition" suffix="."/>
+ </else>
+ </choose>
+ </macro>
+ <macro name="date">
+ <choose>
+ <if type="article-journal article-magazine article-newspaper review review-book" match="any">
+ <group suffix=";" delimiter=" ">
+ <date variable="issued" form="text"/>
+ <text macro="accessed-date"/>
+ </group>
+ </if>
+ <else-if type="bill legislation" match="any">
+ <group delimiter=", ">
+ <date variable="issued" delimiter=" ">
+ <date-part name="month" form="short" strip-periods="true"/>
+ <date-part name="day"/>
+ </date>
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </group>
+ </else-if>
+ <else-if type="report">
+ <date variable="issued" delimiter=" ">
+ <date-part name="year"/>
+ <date-part name="month" form="short" strip-periods="true"/>
+ </date>
+ <text macro="accessed-date" prefix=" "/>
+ </else-if>
+ <else-if type="patent">
+ <group suffix=".">
+ <group delimiter=", ">
+ <text variable="number"/>
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ </group>
+ <text macro="accessed-date" prefix=" "/>
+ </group>
+ </else-if>
+ <else-if type="speech">
+ <group delimiter="; ">
+ <group delimiter=" ">
+ <date variable="issued" delimiter=" ">
+ <date-part name="year"/>
+ <date-part name="month" form="short" strip-periods="true"/>
+ <date-part name="day"/>
+ </date>
+ <text macro="accessed-date"/>
+ </group>
+ <text variable="event-place"/>
+ </group>
+ </else-if>
+ <else>
+ <group suffix=".">
+ <date variable="issued">
+ <date-part name="year"/>
+ </date>
+ <text macro="accessed-date" prefix=" "/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="pages">
+ <choose>
+ <if type="article-journal article-magazine article-newspaper review review-book" match="any">
+ <text variable="page" prefix=":"/>
+ </if>
+ <else-if type="book" match="any">
+ <text variable="number-of-pages" prefix=" "/>
+ <choose>
+ <if is-numeric="number-of-pages">
+ <label variable="number-of-pages" form="short" prefix=" " plural="never"/>
+ </if>
+ </choose>
+ </else-if>
+ <else>
+ <group prefix=" " delimiter=" ">
+ <label variable="page" form="short" plural="never"/>
+ <text variable="page"/>
+ </group>
+ </else>
+ </choose>
+ </macro>
+ <macro name="journal-location">
+ <choose>
+ <if type="article-journal article-magazine review review-book" match="any">
+ <text variable="volume"/>
+ <text variable="issue" prefix="(" suffix=")"/>
+ </if>
+ </choose>
+ </macro>
+ <macro name="collection-details">
+ <choose>
+ <if type="article-journal article-magazine article-newspaper review review-book" match="none">
+ <choose>
+ <if variable="collection-title">
+ <group delimiter=" " prefix="(" suffix=")">
+ <names variable="collection-editor" suffix=".">
+ <name sort-separator=" " initialize-with="" name-as-sort-order="all" delimiter=", " delimiter-precedes-last="always"/>
+ <label form="long" prefix=", "/>
+ </names>
+ <group delimiter="; ">
+ <text variable="collection-title"/>
+ <group delimiter=" ">
+ <label variable="volume" form="short"/>
+ <text variable="volume"/>
+ </group>
+ </group>
+ </group>
+ </if>
+ </choose>
+ </if>
+ </choose>
+ </macro>
+ <macro name="report-details">
+ <choose>
+ <if type="report">
+ <text variable="number" prefix="Report No.: "/>
+ </if>
+ </choose>
+ </macro>
+ <citation collapse="citation-number">
+ <sort>
+ <key variable="citation-number"/>
+ </sort>
+ <layout prefix="(" suffix=")" delimiter=",">
+ <text variable="citation-number"/>
+ </layout>
+ </citation>
+ <bibliography et-al-min="7" et-al-use-first="6" second-field-align="flush">
+ <layout>
+ <text variable="citation-number" suffix=". "/>
+ <group delimiter=". " suffix=". ">
+ <text macro="author"/>
+ <text macro="title"/>
+ </group>
+ <group delimiter=" " suffix=". ">
+ <group delimiter=": ">
+ <text macro="chapter-marker"/>
+ <group delimiter=" ">
+ <text macro="editor"/>
+ <text macro="container-title"/>
+ </group>
+ </group>
+ <text macro="publisher"/>
+ <group>
+ <text macro="date"/>
+ <text macro="journal-location"/>
+ <text macro="pages"/>
+ </group>
+ </group>
+ <text macro="collection-details" suffix=". "/>
+ <text macro="report-details" suffix=". "/>
+ <text macro="access"/>
+ </layout>
+ </bibliography>
+</style>
diff --git a/test/command/zeitschrift-fur-kunstgeschichte.csl b/test/command/zeitschrift-fur-kunstgeschichte.csl
new file mode 100644
index 000000000..14f30ae53
--- /dev/null
+++ b/test/command/zeitschrift-fur-kunstgeschichte.csl
@@ -0,0 +1,346 @@
+<?xml version="1.0" encoding="utf-8"?>
+<style xmlns="http://purl.org/net/xbiblio/csl" class="note" version="1.0" demote-non-dropping-particle="sort-only">
+ <info>
+ <title>Zeitschrift für Kunstgeschichte</title>
+ <title-short>ZfK</title-short>
+ <id>http://www.zotero.org/styles/zeitschrift-fur-kunstgeschichte</id>
+ <link href="http://www.zotero.org/styles/zeitschrift-fur-kunstgeschichte" rel="self"/>
+ <link href="http://www.zotero.org/styles/kritische-ausgabe" rel="template"/>
+ <link href="http://www.uni-bielefeld.de/geschichte/abteilung/arbeitsbereiche/bildwissenschaft/zfk/documents/Sylesheet-(ger)-Zeitschrift-fur-Kunstgeschichte.pdf" rel="documentation"/>
+ <link href="https://github.com/citation-style-language/styles/pull/1861" rel="documentation"/>
+ <author>
+ <name>Philipp Zumstein</name>
+ <uri>https://github.com/zuphilip/</uri>
+ </author>
+ <contributor>
+ <name>Anna Simon</name>
+ <email>simonanna@gmx.net</email>
+ </contributor>
+ <category citation-format="note"/>
+ <category field="humanities"/>
+ <category field="history"/>
+ <issn>0044-2992</issn>
+ <summary>From the editors: "Die Herausgeber werden im Falle von Editionen, Lexika und Ausstellungskatalogen dem Titel nachgestellt [use encyclopedia articles with or without container-title for that]. Bei gewöhnlichen Sammelbänden werden die Herausgeber dem Titel vorangestellt [use book for that]." Multilingual style; the information for exhibition catalogues should be entered in the field collection-title; locators may use the word "here" or "hier" in front of the page refering to which must be entered individually (the style outputs the locator as it is entered w/o any label or additional text).</summary>
+ <updated>2016-02-03T17:41:02+00:00</updated>
+ <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
+ </info>
+ <locale xml:lang="de">
+ <terms>
+ <term name="note">wie Anm.</term>
+ <term name="et-al">et al.</term>
+ <term name="editor" form="short">Hg.</term>
+ <term name="editortranslator" form="verb-short">hg. und übers. von</term>
+ <term name="accessed">letzter Zugriff am</term>
+ </terms>
+ </locale>
+ <locale xml:lang="en">
+ <terms>
+ <term name="note">as note</term>
+ <term name="editortranslator" form="verb-short">ed. and trans. by</term>
+ </terms>
+ </locale>
+ <macro name="author-short">
+ <names variable="author">
+ <name form="short" delimiter="/" and="text" delimiter-precedes-et-al="never"/>
+ <substitute>
+ <choose>
+ <if type="entry-encyclopedia" match="none">
+ <names variable="editor"/>
+ </if>
+ </choose>
+ <text variable="title" form="short"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="author">
+ <names variable="author" delimiter=", ">
+ <name and="text" delimiter-precedes-et-al="never" delimiter-precedes-last="never"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ <substitute>
+ <choose>
+ <if type="entry-encyclopedia" match="none">
+ <names variable="editor"/>
+ </if>
+ </choose>
+ <text variable="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="author-bibliography">
+ <names variable="author" delimiter=", ">
+ <name and="text" delimiter-precedes-et-al="never" delimiter-precedes-last="never" name-as-sort-order="first"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ <substitute>
+ <choose>
+ <if type="entry-encyclopedia" match="none">
+ <names variable="editor"/>
+ </if>
+ </choose>
+ <text variable="title"/>
+ </substitute>
+ </names>
+ </macro>
+ <macro name="editor">
+ <names variable="editor translator" delimiter=", ">
+ <name and="text" delimiter-precedes-et-al="never" delimiter-precedes-last="never"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ </names>
+ </macro>
+ <macro name="editor-encyclopedia">
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb-short" suffix=" "/>
+ <name and="text" delimiter-precedes-et-al="never" delimiter-precedes-last="never"/>
+ </names>
+ </macro>
+ <macro name="volume">
+ <choose>
+ <if type="article-journal">
+ <text variable="volume" prefix=" "/>
+ <text variable="issue" prefix="/"/>
+ </if>
+ <else>
+ <choose>
+ <if variable="volume">
+ <group delimiter=" ">
+ <number variable="volume" form="long-ordinal" text-case="capitalize-first"/>
+ <text term="volume" form="short" text-case="capitalize-first"/>
+ </group>
+ </if>
+ <else>
+ <group>
+ <number variable="number-of-volumes" form="numeric"/>
+ <text term="volume" form="short" prefix=" " plural="true"/>
+ </group>
+ </else>
+ </choose>
+ </else>
+ </choose>
+ </macro>
+ <macro name="year-date">
+ <date variable="issued" date-parts="year" form="numeric"/>
+ </macro>
+ <macro name="collection-with-number">
+ <group delimiter=", " prefix="(" suffix=")">
+ <text variable="collection-title"/>
+ <text variable="collection-number"/>
+ </group>
+ </macro>
+ <macro name="translator">
+ <names variable="editor translator" delimiter=", ">
+ <label form="verb-short"/>
+ <name prefix=" " and="text" delimiter-precedes-et-al="never" delimiter-precedes-last="never"/>
+ </names>
+ </macro>
+ <citation et-al-min="3" et-al-use-first="1" disambiguate-add-names="true">
+ <layout delimiter="; " suffix=".">
+ <choose>
+ <if position="ibid-with-locator">
+ <group delimiter=", ">
+ <text term="ibid"/>
+ <text variable="locator" prefix=" "/>
+ </group>
+ </if>
+ <else-if position="ibid">
+ <text term="ibid"/>
+ </else-if>
+ <else-if position="subsequent">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text macro="author-short"/>
+ <text macro="year-date"/>
+ <group delimiter=" " prefix="(" suffix=")">
+ <text term="note"/>
+ <text variable="first-reference-note-number"/>
+ </group>
+ </group>
+ <text variable="locator"/>
+ </group>
+ </else-if>
+ <else>
+ <group delimiter=", ">
+ <text macro="author"/>
+ <choose>
+ <if match="any" variable="container-title">
+ <text variable="title"/>
+ <group delimiter=" ">
+ <text term="in" suffix=": "/>
+ <choose>
+ <if type="entry-encyclopedia" match="any">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text variable="container-title" font-style="italic"/>
+ <text macro="collection-with-number"/>
+ <text macro="volume"/>
+ </group>
+ <text macro="editor-encyclopedia"/>
+ </group>
+ </if>
+ <else>
+ <text macro="editor" suffix=","/>
+ <text variable="container-title" font-style="italic"/>
+ <text macro="collection-with-number"/>
+ <text macro="volume"/>
+ </else>
+ </choose>
+ </group>
+ </if>
+ <else>
+ <choose>
+ <if type="entry-encyclopedia" match="any">
+ <group delimiter=" ">
+ <text variable="title" font-style="italic"/>
+ <text macro="collection-with-number"/>
+ </group>
+ <text macro="editor-encyclopedia"/>
+ </if>
+ <else-if match="any" variable="translator">
+ <choose>
+ <if match="none" variable="author">
+ <names variable="editor">
+ <name and="text" delimiter-precedes-et-al="never" delimiter-precedes-last="never"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ </names>
+ </if>
+ </choose>
+ <group delimiter=" ">
+ <text variable="title" font-style="italic" suffix=","/>
+ <text macro="collection-with-number"/>
+ </group>
+ </else-if>
+ <else>
+ <choose>
+ <if match="none" variable="author">
+ <names variable="editor">
+ <name and="text" delimiter-precedes-et-al="never" delimiter-precedes-last="never"/>
+ <label form="short" prefix=" (" suffix=")"/>
+ </names>
+ </if>
+ </choose>
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <text variable="title" font-style="italic"/>
+ <text macro="translator"/>
+ </group>
+ <text macro="collection-with-number"/>
+ </group>
+ </else>
+ </choose>
+ </else>
+ </choose>
+ <choose>
+ <if type="thesis">
+ <text variable="publisher" prefix="Diss., "/>
+ </if>
+ </choose>
+ <group delimiter=" ">
+ <text variable="publisher-place"/>
+ <group>
+ <text variable="edition" vertical-align="sup"/>
+ <text macro="year-date"/>
+ </group>
+ </group>
+ <text variable="page" prefix=" "/>
+ <text variable="locator" prefix=" "/>
+ </group>
+ </else>
+ </choose>
+ <choose>
+ <if variable="URL" match="any">
+ <group>
+ <text variable="URL" prefix=", "/>
+ <text term="accessed" prefix=" ("/>
+ <date variable="accessed" prefix=" " delimiter="." suffix=")">
+ <date-part name="day"/>
+ <date-part name="month" form="numeric"/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </if>
+ </choose>
+ </layout>
+ </citation>
+ <bibliography et-al-min="3" et-al-use-first="1" subsequent-author-substitute="&#8212;&#8212;&#8212;" entry-spacing="0" hanging-indent="true">
+ <sort>
+ <key macro="author-bibliography"/>
+ <key macro="year-date"/>
+ <key variable="title"/>
+ </sort>
+ <layout suffix=".">
+ <group delimiter=", ">
+ <text macro="author-bibliography"/>
+ <choose>
+ <if match="any" variable="container-title">
+ <text variable="title"/>
+ <group delimiter=" ">
+ <text term="in" suffix=": "/>
+ <choose>
+ <if type="entry-encyclopedia" match="any">
+ <group delimiter=", ">
+ <group delimiter=" ">
+ <text variable="container-title" font-style="italic"/>
+ <text macro="collection-with-number"/>
+ <text macro="volume"/>
+ </group>
+ <text macro="editor-encyclopedia"/>
+ </group>
+ </if>
+ <else>
+ <text macro="editor" suffix=","/>
+ <text variable="container-title" font-style="italic"/>
+ <text macro="collection-with-number"/>
+ <text macro="volume"/>
+ </else>
+ </choose>
+ </group>
+ </if>
+ <else>
+ <choose>
+ <if type="entry-encyclopedia" match="any">
+ <group delimiter=" ">
+ <text variable="title" font-style="italic"/>
+ <text macro="collection-with-number"/>
+ </group>
+ <text macro="editor-encyclopedia"/>
+ </if>
+ <else>
+ <group delimiter=" ">
+ <group delimiter=", ">
+ <text variable="title" font-style="italic"/>
+ <text macro="editor"/>
+ </group>
+ <text macro="collection-with-number"/>
+ </group>
+ </else>
+ </choose>
+ </else>
+ </choose>
+ <choose>
+ <if type="thesis">
+ <text variable="publisher" prefix="Diss., "/>
+ </if>
+ </choose>
+ <group delimiter=" ">
+ <text variable="publisher-place"/>
+ <group>
+ <text variable="edition" vertical-align="sup"/>
+ <text macro="year-date"/>
+ </group>
+ </group>
+ <text variable="page" prefix=" "/>
+ </group>
+ <choose>
+ <if variable="URL" match="any">
+ <group>
+ <text variable="URL" prefix=", "/>
+ <text term="accessed" prefix=" ("/>
+ <date variable="accessed" prefix=" " delimiter="." suffix=")">
+ <date-part name="day"/>
+ <date-part name="month" form="numeric"/>
+ <date-part name="year"/>
+ </date>
+ </group>
+ </if>
+ </choose>
+ </layout>
+ </bibliography>
+</style>