logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

pandoc-citeproc-preamble - insert a preamble before Pandoc's bibliography

Author

       Sean Whitton <spwhitton@spwhitton.name>

Description

pandoc-citeproc-preamble is a JSON filter for pandoc(1) which inserts a preamble before the output that
       Pandoc's citeproc filter appends to the document.  This preamble might include a heading (e.g.
       "Bibliography") and/or raw markup to format the bibliography for the output format.

Files

~/.pandoc/citeproc-preamble/default.FORMAT
           Default citeproc preamble for Pandoc output format FORMAT (e.g. "latex").

       To override this, you can set document metadata like this:

           % pandoc ... --filter pandoc-citeproc-preamble \
               -M citeproc-preamble=~/mypreamble.tex ...

Name

       pandoc-citeproc-preamble - insert a preamble before Pandoc's bibliography

Rationale

       One motivation for authoring with Pandoc is that one's input files are agnostic with regard to the output
       format  to  which  they  will eventually be compiled.  For example, it should not be necessary to include
       LaTeX code in one's input file in order to format  the  bibliography.   The  input  file  might  also  be
       compiled to HTML.

       However,  when  compiling  to  PDF,  formatting  code is usually required in order to have the entries of
       Pandoc's bibliography line up with each other; by default, all entries except the first will be indented.
       Another common customisation is to set up a hanging indent for bibliography entries.

       Since Pandoc's citeproc filter doesn't provide any facility to add formatting control code to its output,
       pandoc-citeproc-preamble is necessary to avoid the user being forced to add their control code to the end
       of their input files, thereby losing the input file's agnosticity with regard to output format.

See Also

pandoc(1)

perl v5.38.2                                       2024-03-21                      PANDOC-CITEPROC-PREAMBLE.1(1)

Synopsis

pandoc-citeproc-preamble

Usage

       Add --filterpandoc-citeproc-preamble somewhere after --citeproc, e.g.

           % pandoc -s --citeproc --bibliography=~/doc/mine.bib \
               --filter pandoc-citeproc-preamble \
               ~/doc/my_essay.mdwn -o ~/my_essay.pdf
return

See Also