Skip to content

codesoda/make-pdf

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

make-pdf

Your coding agent can write docs, but it can't hand you a PDF. make-pdf fixes that — one skill turns any markdown or text file into a clean, typeset PDF without leaving your editor.

Why?

Agents are great at generating markdown. Getting that into a shareable PDF usually means leaving the terminal, opening a browser tool, or installing a full TeX distribution. make-pdf uses pandoc + tectonic so the agent handles the whole thing in one step — no TeX install, no manual export.

  • One command/make-pdf report.md and you're done
  • Zero TeX setup — tectonic auto-downloads only the packages it needs
  • Font choice — serif (Palatino) or sans-serif (Helvetica), the skill asks if you don't specify
  • Configurable — font size, margins, output path via env knobs

Quick Start

Install via curl

curl -sSf https://raw.githubusercontent.com/codesoda/make-pdf/main/install.sh | sh

Install from local clone

git clone git@github.com:codesoda/make-pdf.git
cd make-pdf
sh install.sh

Local installs use symlinks so edits to the repo are immediately reflected. The installer will offer to brew install missing dependencies if Homebrew is available.

Use directly (no install)

path/to/make-pdf/skills/make-pdf/scripts/make-pdf.sh document.md

Usage

In a Claude Code session:

/make-pdf document.md

Or naturally:

Convert my README to a PDF

The skill identifies the file, asks serif or sans-serif, runs the conversion, and reports the output path and file size.

Direct script usage

# Basic
scripts/make-pdf.sh document.md

# Serif font
FONT_FAMILY=serif scripts/make-pdf.sh document.md

# Custom output path
OUTPUT=~/Desktop/report.pdf scripts/make-pdf.sh document.md

# All options
FONT_FAMILY=serif FONT_SIZE=12pt MARGIN=0.75in scripts/make-pdf.sh report.md

Environment Knobs

Variable Default Description
FONT_FAMILY sans sans or serif
FONT_SIZE 11pt Font size (10pt, 11pt, 12pt)
MARGIN 1in Page margins (0.75in, 1in, 1.5in)
OUTPUT <input>.pdf Override output file path
MAX_LINES 40 Max error lines printed
KEEP_DIR 0 Keep temp log dir on success

Output Format

------------------------------------------------------------
Step: convert
Input:  document.md
Output: document.pdf
Font:   sans (helvet)
Size:   11pt
Margin: 1in
Size:   24318 bytes

Result: PASS
Full log: /tmp/make-pdf.abc123/pandoc.log
Time: 3s
------------------------------------------------------------
Overall: PASS
Logs: /tmp/make-pdf.abc123

On PASS, temp logs are cleaned up automatically. On FAIL (or KEEP_DIR=1), logs are preserved and the path is printed so the agent can inspect them.

License

MIT

About

Claude Code skill — convert markdown to typeset PDF in one command (pandoc + tectonic)

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages