Skip to main content

platen

In a printing press, the platen presses paper against inked type.

Platen is a Python package and command-line tool that presses structured data into documents.

Requirements

  • Python 3.14 or later.

Installation

To install Platen as a package to use in your own Python project, install platen from PyPI with your package manager of choice and read the user guide.

To use platen as a command-line tool, install it via pipx:

pipx install platen

Usage

platen --template FILE \
       --values   FILE \
       --out      FILE \
       [--watch] [--serve]

platen --templates DIRECTORY \
       --values    FILE      \
       --out       DIRECTORY \
       [--watch] [--serve]

--template and --templates are the same option, so either one can name a file or a directory.

For example, say you have values in values.yaml:

name: Bob

And a Jinja template, hello.md:

# Hello, {{ name }}!

Press the values into the template:

platen --template hello.md --values values.yaml --out build/hello.md

Platen creates build/hello.md:

# Hello, Bob!

To press every template in a directory, name that directory with --templates and the directory to press into with --out:

platen --templates templates --values values.yaml --out build

To press again whenever the templates or values change, add --watch. Platen prints a line for every press, and keeps watching until you press Ctrl+C, even when a press fails:

platen --template hello.md --values values.yaml --out build/hello.md --watch

See Watching for changes in the user guide for what's watched, and what isn't.

To see your pages in a browser while you work, add --serve instead. Platen serves at http://localhost:1440/, re-presses when the templates or values change, and reloads open HTML pages automatically:

platen --templates templates --values values.yaml --out build --serve

See Serving with live reload in the user guide for what's served, and how.

Contributing

See Contributing in the user guide to set up the project and run its checks.

Metadata

Release files for platen 0.7.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for platen 0.7.0
File Size Uploaded Provenance Actions
platen-0.7.0.tar.gz 104.1 kB With provenance Details for platen-0.7.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for platen 0.7.0
File Interpreter ABI Platform Actions
platen-0.7.0-py3-none-any.whl Python 3 none any Details for platen-0.7.0-py3-none-any.whl

Total release size: 138.4 kB

Release files / platen-0.7.0.tar.gz

Download URL platen-0.7.0.tar.gz
Size 104.1 kB
Tags Source
SHA-256 checksum
How to use checksums
5979d7e46cf6bdfdd5fd942847629f9b6cb20a441b153a524239ef528a70af4b
BLAKE2b-256 checksum
How to use checksums
5fe824602d51469b8a6a99a7a81d25ee5505c9b18683624b5348ad43282a4357
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 8, 2026.

Transparency log

Release files / platen-0.7.0-py3-none-any.whl

Download URL platen-0.7.0-py3-none-any.whl
Size 34.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
56e2ebdb544c116529c583df34d3a738022ad2b37b240f8378a4a2f4380d0adf
BLAKE2b-256 checksum
How to use checksums
f687eb9434a0ff1fc13dad432952974b0200ff4f7acbacde71e60be34f78bb7a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 8, 2026.

Transparency log

Security for platen 0.7.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for platen-0.7.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 8, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page