← ClaudeAtlas

md2pdf-typoralisted

Convert a Markdown file to PDF that closely matches Typora's PDF export with the Whitey theme using pandoc and headless Chrome. Preserves MathJax math, code styling, and typography. Use when the user asks to convert Markdown to PDF, generate a PDF report from a .md file, export markdown in Typora style, or render styled documents to PDF.
Axect/skills · ★ 3 · Data & Documents · score 76
Install: claude install-skill Axect/skills
# Markdown to PDF (Typora-style) Convert a Markdown file to PDF that closely matches Typora's PDF export with the **Whitey** theme. pandoc handles MD to HTML, Chrome headless handles HTML to PDF. **Run the bundled script. Do not reconstruct the pipeline inline.** The pipeline used to live in this file as a bash-plus-python template that the caller retyped every run, and the retyping was the instability. See "History" at the bottom for what that cost. ## Usage ```bash bash <skill-dir>/scripts/md2pdf.sh <input.md> [options] # e.g., bash ~/Documents/Project/AI_Project/skills/md2pdf-typora/scripts/md2pdf.sh <input.md> [options] ``` | Option | Effect | |---|---| | `--output <path>` | Output PDF path. Default: same directory as the input, `.pdf` extension | | `--dropbox [subfolder]` | Also copy the PDF into `~/Dropbox/Magi/<subfolder>/` | | `--no-toc` | Omit the table of contents. It is included by default | | `--toc` | Accepted for compatibility; the TOC is already on by default | | `--break-on-hr` | Force a page break at every `---`. Default is a thin rule, which is what Typora does | | `--paper <A4\|Letter>` | Page size. Default `A4` | | `--font <px>` | Root font size. Default `14` | | `--keep-html` | Keep the intermediate HTML for debugging | The script exits non-zero with a specific message on any failure, so a broken run is never mistaken for a good one. `--send-telegram` is not a script option, because bash cannot reach the Telegram MCP tool. Run the script, then pass