md-to-pdf
Skill0 starsChanged 3 months agoMITView on GitHub
Convert a Markdown file into a beautifully typeset PDF via a pandoc → Typst pipeline. Ships with claude-white themes (warm white page, terracotta accents, serif typography). Trigger when the user says "turn this md into a pdf", "export X.md as pdf", "make X.md printable", or any request to produce a nicely formatted PDF from a Markdown file. Requires pandoc and typst installed. Fonts are bundled inside the skill directory — no system font installation needed.
17 other projects use a version of this.
Adopted by
Most recently taken up by
- StevenZhao666/hermes-kitstheir own version, first seen Nov 8, 2026
- Mathews-Tom/armorytheir own version, first seen Nov 1, 2026
- sanoakr/ai-skillstheir own version, first seen Oct 20, 2026
- wearekanso/agent-skillstheir own version, first seen Oct 20, 2026
- yo61/claude-plugin-reportlab-pdftheir own version, first seen Oct 13, 2026
- TbusOS/sky-skillstheir own version, first seen Oct 11, 2026
Used with
Projects with it also use skill-creator.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
SentrySkillskill-creator
Create new agent skills following the Agent Skills specification. Use when asked to "create a skill", "add a new skill", "write a skill", "make a skill", "build a skill", or scaffold a new skill with SKILL.md. Guides through requirements, writing, registration, and verification.
Also in 4 projects that use this
Other versions17 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 17
- Mathews-Tom/armory★ 340same name
- huangserva/servasyy_skills★ 168same name
- hamzafarooq/claude-code-starter★ 145same name
- madebyecho/agent-skills★ 8same name
- wearekanso/agent-skills★ 8same name
- allenyan513/open-investor-skills★ 5same name
- TbusOS/sky-skills★ 3same name
- StevenZhao666/hermes-kits★ 2same name
- luochang212/skills★ 1same name
- sanoakr/ai-skills★ 1same name
7 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repositoryOne other file it gives its agents.
- AGENTS.mdAGENTS.md
The file
We split this skill into the rules it gives an agent
4 rules. 0 are common, 3 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 11 edited versions we read keep these.
3
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 75
Write theme.typ: translate color tokens / typography / components into Typst #set + #show rules
- Distinctive: line 76
Write README.md: record typography table and key decisions
- Distinctive: line 97
If either binary is missing the script exits with a clear error (no silent fallback).
- Distinctive: line 101
Keep one canonical checkout and link both Codex and Claude Code to it:
“Common” is measured: kept by at least 6 in 10 of the 11 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
md-to-pdf
Convert Markdown into beautifully typeset PDFs. Use this skill whenever the user wants a polished PDF out of a Markdown source.
Usage
./scripts/md_to_pdf.sh <input.md> <output.pdf> [theme]Arguments:
input.md: path to the Markdown file (absolute or relative)output.pdf: destination PDF paththeme: theme name, defaults toclaude-white. Available:claude-white(recommended),claude-white-bold
On success, the script prints [OK] /absolute/path.pdf.
Architecture
md-to-pdf/
├── SKILL.md # this file
├── scripts/
│ └── md_to_pdf.sh # main pipeline: pandoc → sed → typst compile
├── themes/
│ ├── claude-white/ # default theme (recommended)
│ │ ├── DESIGN.md # design reference
│ │ ├── README.md # theme notes (typography, color tokens)
│ │ └── theme.typ # Typst template (show / set / color tokens)
│ └── claude-white-bold/ # variant with stronger synthetic bold
│ ├── DESIGN.md
│ ├── README.md
│ └── theme.typ
└── fonts/ # bundled fonts loaded via typst --font-pathPipeline
pandoc input.md --to typst→body.typ(Typst body fragment, no template)perlreplacescolumns: N,withcolumns: (1fr,)*N,so Markdown tables span the page widthcat theme.typ body.typ > run.typ(must concatenate, not#include—#includeisolates scope and the body would lose access to#let horizontalruleand other theme definitions)typst compile --font-path <skill>/fonts run.typ output.pdf
Markdown elements styled by the theme
| Markdown | pandoc output | theme.typ |
# H1 | = ... | centered, 24pt bold |
## H2 / ### H3 / #### H4 | == / === / ==== | bold, decreasing size, warming color |
**bold** | #strong[...] | bold weight (or stroked synthetic bold in the -bold variant) |
*italic* | #emph[...] | italic style |
`code` | `code` | peach background + terracotta text |
```lang ``` | raw block | ivory background, rounded corners |
> quote | #quote(block: true)[...] | warm-sand background, terracotta left bar |
- item / + item | - ... / + ... | untouched |
[link](url) | #link(...)[...] | terracotta + underline |
--- | #horizontalrule | thin warm-gray rule (defined via #let horizontalrule = ...) |
| table | #figure(align(center)[#table(...)], kind: table) | 1fr equal columns, 0.4pt warm borders, 1.2pt terracotta header underline |
Adding a new theme
To add a new theme (e.g. vercel / notion / mintlify):
- Create
themes/<name>/ - Optionally add
DESIGN.md(design reference to translate from) - Write
theme.typ: translate color tokens / typography / components into Typst#set+#showrules - Write
README.md: record typography table and key decisions - Run:
./scripts/md_to_pdf.sh input.md output.pdf <name>
theme.typ must include:
- all
#letcolor tokens #set page(...)(with fill + footer)#set text(...)(font stack + size + color)#set par(...)(leading + justify)#show heading.where(level: N): ...for each heading level#show strong / emph / link: ...#show raw.where(block: false/true): ...(inline / block code)#show quote.where(block: true): ...#set table(...)+#set table.hline(...)+#show figure.where(kind: table): ...#let horizontalrule = ...(pandoc emits#horizontalrule, which Typst does not provide built-in)
Dependencies
- pandoc ≥ 3.2 — on PATH (tested with 3.9.0.2). The Typst writer was added in pandoc 3.2.
- typst — on PATH (tested with 0.14.2)
- fonts — bundled under
fonts/; the script passes them viatypst compile --font-path
If either binary is missing the script exits with a clear error (no silent fallback).
Installing this skill
Keep one canonical checkout and link both Codex and Claude Code to it:
git clone https://github.com/WeAIClub/md-to-pdf ~/Documents/Projects/md-to-pdf
bash ~/Documents/Projects/md-to-pdf/scripts/setup_new_mac.shThe setup script creates ~/.agents/skills/md-to-pdf and ~/.claude/skills/md-to-pdf symlinks. Restart the agent after installation. Do not maintain copied Skill directories; they drift from the repository.
Known limitations
- pandoc's Typst writer does not support every Markdown extension (comments, custom block containers, etc.)
- The bundled serif font has no native 700-weight glyphs, so Typst synthesizes bold from the 500-weight — it reads slightly lighter than a true bold. Use the
-boldvariant for stronger emphasis (stroke-based synthetic bold). - Tables have no manual column-width control (uniform 1fr). For custom ratios, edit the intermediate
body.typmanually.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

