md-to-pdf
MarkdownからPDFを生成する。md-to-pdf(Puppeteer)を使用。GitHub風スタイル、日本語・カラー絵文字対応。
Why use this skill?
Convert Markdown files into professional PDFs using Puppeteer. Supports GitHub-style CSS, Japanese text, and color emojis. Perfect for automated documentation and reporting.
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/hiroakiyoshikura/md-to-pdfWhat This Skill Does
The md-to-pdf skill empowers OpenClaw agents to transform raw Markdown documents into polished, professional-grade PDF files. By utilizing md-to-pdf powered by a headless Chromium (Puppeteer), this skill ensures that the generated documents maintain high fidelity to web-based rendering standards. It is particularly effective for users who require GitHub-flavored aesthetic layouts, comprehensive support for Japanese characters, and native rendering of color emojis. The skill is highly customizable, allowing users to define CSS styles and PDF metadata via YAML front-matter, making it ideal for reports, documentation, and formal exports.
Installation
To integrate this skill into your OpenClaw environment, execute the following command in your terminal:
clawhub install openclaw/skills/skills/hiroakiyoshikura/md-to-pdf
Ensure that your system environment is capable of running Puppeteer/Chromium, as the headless browser engine is required for the rendering process.
Use Cases
- Documentation Generation: Automatically converting technical notes or project specifications into shareable PDF manuals.
- Reporting: Creating visually appealing, data-rich reports with tables and formatted text for stakeholders or team updates.
- Content Creation: Drafting blog posts or long-form articles in Markdown and exporting them as formatted previews for review.
- Educational Materials: Preparing handouts or reference sheets that require precise formatting, including page breaks and custom headers.
Example Prompts
- "Convert the technical documentation I just wrote in the temporary directory into a professional PDF with GitHub-style formatting and save it to /tmp/manual.pdf."
- "Take my meeting notes from /tmp/notes.md and turn them into a PDF, ensuring page breaks are inserted between the agenda and the action items list."
- "Generate a formal report from this Markdown content, using the provided YAML front-matter to include a specific header and footer with page numbers."
Tips & Limitations
- Performance: Always use
timeout 30to prevent the Chromium process from hanging. If a timeout occurs, simply retry the operation. - Security: For stability and security, avoid using
--no-sandboxflags or external CDN imports within your CSS, as external network dependencies can cause significant latency or process hangs. - Storage: Strictly use the
/tmp/directory for file operations. Ensure that the generated files are properly handled or transmitted via the agent’s communication interface immediately after creation. - Formatting: Utilize the
<div class="page-break"></div>tag to manage document structure across multiple pages effectively.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-hiroakiyoshikura-md-to-pdf": {
"enabled": true,
"auto_update": true
}
}
}Tags(AI)
Flags: file-write, file-read, code-execution