fix(base): default pandoc typst template font so PDF export works without -V mainfont
Lint workflows / actionlint (push) Successful in 21s
Lint workflows / actionlint (push) Successful in 21s
pandoc's bundled typst template defaults the document font to an empty tuple (font: ()), so a naked `pandoc --pdf-engine=typst` fails with "font fallback list must not be empty". Patch the template default to Libertinus Serif (typst's own bundled default) at build time so PDF export works out of the box. Document usage in README and note the fix in CHANGELOG (Unreleased). Base-affecting.
This commit is contained in:
@@ -11,6 +11,23 @@ Pre-v1.0.0 tags followed the pi npm version (`v{pi_version}[letter]`).
|
||||
|
||||
---
|
||||
|
||||
## Unreleased
|
||||
|
||||
### Fixed
|
||||
|
||||
- **`pandoc --pdf-engine=typst` now works without `-V mainfont`.** pandoc's
|
||||
bundled typst template (`/usr/share/pandoc/data/templates/template.typst`)
|
||||
defaults the document font to an empty tuple (`font: ()`), so a naked
|
||||
`pandoc --pdf-engine=typst` (and `studio_export_pdf` in some cases) failed
|
||||
with `error: font fallback list must not be empty` unless the caller passed
|
||||
`-V mainfont="..."`. The base now patches that template default to
|
||||
`Libertinus Serif` (typst's own bundled default font) at build time, so PDF
|
||||
export works out of the box. Base-affecting (`Dockerfile.base` RUN), rebuilds
|
||||
`base-<hash>`. README gains a "Generating a PDF with pandoc + typst" section
|
||||
with the working command and how to override the font via `-V mainfont`.
|
||||
|
||||
---
|
||||
|
||||
## v1.4.0 — 2026-07-11
|
||||
|
||||
Minor release. Headline: **PDF export works out of the box** — the base now
|
||||
|
||||
Reference in New Issue
Block a user