Claude Code Astro 博客写作:把活动记录整理成 MDX 草稿
EnglishClaude Code 安装步骤
- 打开 GitHub 固定提交的 `.claude/skills/blog-writing/SKILL.md`,核对内容与使用条件。
- 在自己的项目中创建 `.claude/skills/blog-writing/`,把核对后的文件保存为 `.claude/skills/blog-writing/SKILL.md`。
- 在该项目根目录启动 Claude Code,在斜杠菜单中选择 `/blog-writing`。
中文摘要
将一段已核对的活动记录写成 Astro 博客草稿。用开场吸引读者,补足脉络,交代问题,再让结语回应开场。
SKILL.md 中文导读
可复现示例
给图书馆志愿者写一篇平实的桌游归还短稿。借出清单登记了本批借出的 12 份桌游。归还箱里只有本批已归还的 1 份,清单仍显示最初借出数。用结语说明为什么应分栏记录借出和归还。
`{"batch":"volunteer-game-loans","topic":"board game returns","reader":"library volunteers","tone":"plain","date":"2026-10-23","loanSheetCount":12,"returnsBoxCountFromThisBatch":1,"point":"record loans and returns in separate columns"}`工作步骤
- 确认读者、主题与已核对的活动事实。
- 按悬念、脉络、阻力、结语排列段落,不编造数字。
- 在文章内容目录填写并核对 MDX 元数据,保留草稿标记。
验收方法
把草稿保存为 `src/content/posts/2026-10-23-board-game-returns.mdx`。`pubDate` 与文件名日期相同,`slug` 与文件名后半段相同,`draft` 保持为 `true`。 **一、归还箱里的一份** 箱里只有一份刚还回来的桌游。这一批借出去的还有多少? **二、借出清单的数字** 志愿者翻回这批桌游的借出清单,上面记着 12 份。 **三、两处各记各的** 箱子告诉我们已归还一份。清单还显示最初的借出数,单看任一处都得再核算。 **四、结语** 把借出和归还分别记在两栏,归还 1 份后,剩下 11 份待归还。 下面是可复制的 MDX 技术样例,正文使用英文。
---
title: "Board Game Returns"
pubDate: 2026-10-23
categories: ["Library"]
description: "A short note for library volunteers."
slug: board-game-returns
draft: true
---
---
## 一、One game in the box
One board game sat in the returns box. How many from this batch were still out?
---
## 二、The loan sheet
The volunteers checked the loan sheet for the same batch. It showed 12 loans.
---
## 三、Two incomplete counts
The box showed one return. The loan sheet still showed the original count, so neither place gave the number still out.
---
## 四、結語
Record loans and returns in separate columns. With one game returned, 11 remain outstanding.GitHub 原文 · 更新日期
适用环境
用 Claude Code 打开已在 `astro.config.ts` 启用 `@astrojs/mdx` 的 Astro 项目,确认文章集合读取 `src/content/posts/`。原站采用 Moeyua 的 MIT 主题 Typography。示例只制作本地 MDX 草稿。
常见问题
新稿的元数据需要核对哪些字段?
核对 MDX 文件名日期、pubDate 和 slug 是否对应。文章完成后仍按来源规约保留 draft: true,等待人工预览。