Documentation
¶
Overview ¶
Package docpost transforms raw Cobra-generated markdown into Fumadocs-compatible MDX files with YAML frontmatter. Output is grouped into a nested directory structure by command family so the Fumadocs sidebar collapses the CLI reference. The generated root command page is written as agh.mdx so index.mdx can remain a hand-authored overview.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Process ¶
Process reads all agh*.md files from srcDir, transforms them into Fumadocs-compatible MDX, and writes them to dstDir using a nested directory layout: `agh` → agh.mdx, `agh_agent` → agent/index.mdx, `agh_agent_list` → agent/list.mdx, and so on.
The root-level index.mdx and meta.json of dstDir are hand-maintained and never touched by Process. Subdirectory meta.json files are regenerated on each run. Stale files from prior runs are removed before writing.
func TransformMarkdown ¶
TransformMarkdown converts raw Cobra markdown to Fumadocs MDX format. It strips boilerplate, extracts metadata, and prepends YAML frontmatter.
Types ¶
This section is empty.