| File | Purpose |
|---|---|
DESIGN.md |
Brand design system (colors, typography, spacing) — read before designing pages |
This is an Astro static site deployed to Cloudflare Pages (MDX-based).
npm run dev— Start local dev servernpm run build— Build static site todist/npm run preview— Preview built site locally
See ~/.hermes/AGENTS-BASE.md — shared across all blogs.
Run bash ~/.hermes/scripts/deploy-hermes-tutorials.sh — runs quality check, builds, and deploys to Cloudflare Pages.
If deploy is blocked:
- New untracked post →
git add -A && git diff --cached --quiet - MDX parse error → check for HTML comments (
<!-- -->) — use{/* */}instead - Build error → check
npm run buildoutput
| Symptom | Root Cause | Cause | Fix |
|---|---|---|---|
| Build error | MDX files don't accept raw HTML — comments (<!-- -->) or injection output breaks the parser silently, or frontmatter field mismatch |
Missing import, broken frontmatter, HTML comments in MDX | Check npm run build output — use {/* */} not <!-- --> |
| Deploy blocked (no changes) | CI requires staged changes — new files need git add -A before git diff catches them |
git add -A not run before diff |
Run git add -A && git diff --cached --quiet |
| Feature image 404 | R2 upload raced with deploy, or slug doesn't match uploaded filename | heroImage URL not uploaded | Generate via gen-image-verified.sh, verify HTTP 200 |
- Content freshness — Add
lastVerified: YYYY-MM-DDto post frontmatter when you verify the post content is still accurate. The quality ratchet can flag posts without recentlastVerifieddates for review. | Quality gate blocked | New post below blog floor for word count or citations | Content metrics dropped below floor | Improve post (add citations, word count) | | Cross-link injection failed |inject-crosslinks.pywrites HTML<!-- -->syntax into.mdxfiles, which MDX parser rejects | HTML comments from injection in MDX | Ensure inject-crosslinks.py uses{/* */}syntax for MDX blogs |
Blog posts live in src/content/blog/ as .mdx files.
Post frontmatter: title, description, pubDate, tags, heroImage (mandatory).
CRITICAL: Do NOT use HTML comments (<!-- -->) in .mdx files — they break the MDX parser. Use {/* crosslinks */} syntax instead.
- No HTML comments in MDX —
<!-- -->breaks the build. Use{/* */}. - Cross-links verified —
inject-crosslinks.pyruns at deploy; verify it completes.
Shared gates (no unsourced stats, minimum length, deploy guard) apply from ~/.hermes/AGENTS-BASE.md.
See ~/.hermes/AGENTS-BASE.md — shared across all blogs.
See ~/.hermes/AGENTS-BASE.md — shared across all blogs.
- Don't use HTML comments in
.mdxfiles. - Don't fabricate command outputs or configurations.
- Don't write posts under 400 words.
- Don't skip the deploy guard.
- Don't reference yourself ("as an AI").
- Don't silently degrade quality — An MDX parse failure, a broken image, or a failed build must halt deployment. Never publish with known defects. Silent degradation is worse than a clean failure.
See ~/.hermes/AGENTS-BASE.md — shared across all blogs.