From md-to-docx
Convert Markdown files to Word (.docx) format using pandoc. Use when the user asks to convert a markdown file to Word, docx, or document format, or wants to export markdown as a Word document.
How this skill is triggered — by the user, by Claude, or both
Slash command
/md-to-docx:md-to-docxThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Converts `.md` files to `.docx` using **pandoc**, which is available in the
Converts .md files to .docx using pandoc, which is available in the
environment at /usr/bin/pandoc.
| Situation | Action |
|---|---|
| Single file, default style | Basic conversion |
| Single file, custom style | Conversion with --reference-doc |
| Multiple files / batch | Loop conversion |
| File uploaded by user | Copy from /mnt/user-data/uploads/ first |
/mnt/user-data/uploads/<filename>.md.docx extension/mnt/user-data/outputs/Basic (no custom style):
pandoc input.md -o output.docx
With a reference style template:
pandoc input.md --reference-doc=template.docx -o output.docx
Batch (convert all .md in a directory):
for f in *.md; do
pandoc "$f" -o "${f%.md}.docx"
done
After conversion, confirm the file exists and is non-empty:
ls -lh output.docx
Use the present_files tool pointing to the output path so the user can
download the .docx file.
| Option | Purpose |
|---|---|
--reference-doc=template.docx | Apply custom styles from a Word template |
--toc | Add a table of contents |
--toc-depth=N | Depth of TOC headings (default: 3) |
-V geometry:margin=1in | Set page margins |
--highlight-style=tango | Syntax highlighting for code blocks |
/mnt/user-data/uploads//usr/bin/pandoc; use full path if neededcd to the file's directory before running pandocpandoc file1.md file2.md -o combined.docx
--reference-doc is provideddocx skill after conversionCreates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.
npx claudepluginhub gyovana-prado/claude-skills --plugin md-to-docx