Sign inSign up

costantinicarlo/panpreposterous

By costantinicarlo

•Updated 3 months ago

tags: scientific publishing, LaTeX, Pandoc, reproducible research, Docker, CI/CD

Image
Integration & delivery
0

990

costantinicarlo/panpreposterous repository overview

panpreposterous logo

⁠Panpreposterous

Panpreposterous is a containerized command-line application for turning Markdown manuscripts into reproducible preprint and postprint PDFs.

It is designed for researchers who want a plain-text manuscript workflow: write the article in Markdown, keep references in BibTeX, choose a CSL citation style, and run one Docker command to produce a formatted PDF with Pandoc, XeLaTeX, a bundled article template, and Lua filters.

⁠What It Does

Panpreposterous takes an article folder containing files such as:

article/
  manuscript.md
  references.bib
  journal.csl
  figs/
    fig1.svg
  tables/
    table1.tex

and produces a formatted PDF such as:

article/
  manuscript-preprint.pdf

The build runs inside the container, so Pandoc, XeLaTeX, the template, Lua filters, and TeX dependencies travel together in one reproducible environment.

⁠Requirements

You need Docker installed and running.

Docker Desktop is one common option on macOS and Windows. On Linux, a standard Docker Engine installation is sufficient.

⁠Pull the Image

docker pull costantinicarlo/panpreposterous:latest

⁠Basic Use

Open a terminal in the folder containing your manuscript files, then run:

docker run --rm -v "$PWD":/work costantinicarlo/panpreposterous:latest \
  panpreposterous manuscript.md --bibliography references.bib --csl journal.csl -o manuscript.pdf

This command:

  • mounts your current folder into the container as /work
  • reads your manuscript, bibliography, CSL file, figures, and tables
  • runs Pandoc with XeLaTeX and citeproc
  • applies the bundled template and Lua filters
  • writes the output PDF to manuscript.pdf

⁠Recommended Article Folder Layout

article/
  manuscript.md
  references.bib
  journal.csl
  figs/
    fig1.svg
    s1.png
  tables/
    table1.tex
  output/

Example build command:

docker run --rm -v "$PWD":/work costantinicarlo/panpreposterous:latest \
  panpreposterous manuscript.md --bibliography references.bib --csl journal.csl -o output/manuscript-preprint.pdf

⁠Minimal Manuscript Skeleton

---
title: "Example Manuscript"
author:
  - name: "First Author"
    affiliation: [1]
    corresponding: true
affiliations:
  - id: 1
    name: "Department of Biology"
running_title: "Example"
doc_version: "Preprint"
twocolumn: true
correspondence:
  - [email protected] (F. Author)
---

# Introduction

This is a citation [@Smith2024].

![Main figure](figs/fig1.svg){#fig:main width=0.9\\columnwidth}

# References {-}
::: {#refs}
:::

Common YAML options include:

  • twocolumn: true
  • running_title: "Short title"
  • doc_version: "Preprint" or doc_version: "Postprint"
  • correspondence: ["[email protected] (A. Smith)"]
  • csl_entry_spacing_extra: 0.25
  • preprint_doi, preprint_doi_label
  • published_doi, published_doi_label

⁠Supplementary Materials

Wrap supplementary content in a fenced Div:

::: supplementary
**Supplementary note text.**

![Supplementary figure legend.](figs/s1.png){#fig:s1 width=0.9\\columnwidth}

Table: **Supplementary table legend.**
:::

The supplementary filter moves supplementary content to the end of the PDF, creates lists of supplementary figures and tables when applicable, and starts supplementary figures/tables on separate pages.

⁠Tables

For complex tables, especially in two-column layouts, use a LaTeX table file and include it from Markdown:

::: {.texinclude src="tables/table1.tex"}
:::

In two-column mode, Markdown tables are suppressed by default unless explicitly allowed. Use .onecol for a one-column table island or .allowmd to render a Markdown table inline.

⁠Local Development Build

To build the image locally from the source repository:

docker build -t panpreposterous -f Dockerfile .

Then use panpreposterous instead of costantinicarlo/panpreposterous:latest in docker run commands.

⁠Source Repository

Source code, examples, documentation, and release notes are available at:

https://github.com/costantinicarlo/panpreposterous⁠

⁠License and Attribution

Panpreposterous is licensed under Creative Commons Attribution 4.0 International (CC BY 4.0).

This project is adapted from:

The upstream source notes that it was forked and modified from:

Tag summary

Content type

Image

Digest

sha256:30e721aef…

Size

859 MB

Last updated

3 months ago

docker pull costantinicarlo/panpreposterous