markdown-to-pdf

Convert markdown reports to PDF using pandoc and the xelatex engine.

Updated Sep 9, 2026
One-click install
npx skills add https://github.com/lyndonkl/hermesworld --skill markdown-to-pdf-lyndonkl
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: markdown-to-pdf
Source: https://github.com/lyndonkl/hermesworld/tree/main/packages/product-strategist/skills/writing/markdown-to-pdf
Command: npx skills add https://github.com/lyndonkl/hermesworld --skill markdown-to-pdf-lyndonkl

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Turning a finished markdown report into a print-quality PDF usually means hand-tuning pandoc flags, LaTeX variables, and toolchain setup. This Skill provides a fixed, tested pandoc-plus-xelatex invocation with analyst-style formatting (letter paper, 1-inch margins, 11pt body, black links) and explicit failure handling when the toolchain is missing. ## Core Features & Use Cases - Fixed render pipeline: Runs one exact pandoc command with xelatex, footnote support, and YAML title-block rendering, with no pre-processing of the source markdown. - Toolchain verification: Checks that pandoc and xelatex are on PATH before rendering and prints exact per-platform install commands (macOS, Linux, Windows) if either is missing. - Use Case: After finishing a strategy report in markdown with pandoc-style footnotes and a YAML title block, render it to a polished PDF as the final step of the report pipeline, without modifying the source file. ## Quick Start Render my finished report.md file to a PDF using the markdown-to-pdf skill and tell me the output path.

Frequently Asked Questions about markdown-to-pdf

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I convert markdown to PDF with pandoc?

Run pandoc with --pdf-engine=xelatex, specifying the input markdown file and output PDF path. This Skill uses a fixed invocation with letter paper, 1-inch margins, 11pt font, and black hyperlinks for analyst-style output.

What LaTeX engine does pandoc need for PDF output?

This workflow uses xelatex as the PDF engine. On macOS install basictex via Homebrew and add xetex with tlmgr; on Debian/Ubuntu install texlive-xetex and texlive-fonts-recommended; on Windows use MiKTeX.

Does pandoc markdown to PDF support footnotes?

Yes, when the markdown uses pandoc-style footnotes ([^1] markers with definitions later in the file) and the --from markdown+footnotes extension is enabled. Inline [Source: ...] markers do not render as LaTeX footnotes.

Why does pandoc PDF rendering fail with xelatex not found?

The failure means pandoc is installed but the LaTeX engine is missing from PATH. Install xelatex for your platform, open a new shell so the binary is on PATH, then re-run the render command.

Can this skill install pandoc or LaTeX automatically?

No. Auto-installation is explicitly out of scope; the skill never modifies the user's machine. If the toolchain is missing it prints the exact install commands for the platform and stops.