Vitepress doc sync

From fritzprix/libr-agent · View interactive version

Vitepress doc sync is an AI agent skill from the GitHub repository fritzprix/libr-agent. Analyze recent git commits and codebase changes to update, synchronize, and align VitePress documentation (docs/user/ and website/). Use when the user requests to update documentation from git diffs, sync VitePress docs, audit doc gaps, or update user guides after code changes. Triggers on "vitepres

How to use this skill

Skill file

VitePress Doc Sync

Analyze recent Git commits, PRs, and codebase diffs to detect outdated, missing, or inconsistent user-facing documentation in VitePress (docs/user/ and website/), and synchronize them to reflect the latest state of the codebase.


Workflow Decision Tree

1. Run Gap Analysis Script
   └─ python .agents/skills/vitepress-doc-sync/scripts/detect_doc_gaps.py --since <GIT_REF>
2. Inspect Code Changes
   └─ Review git log / diff & consult references/git_diff_analysis_guide.md
3. Update Target Docs
   └─ Edit corresponding Korean (docs/user/*.md) and English (docs/user/en/*.md) pages
4. Sync VitePress Config
   └─ If new files added, update website/.vitepress/config.ts (koSidebar & enSidebar)
5. Build & Validate
   └─ Run pnpm --filter website build or pnpm refactor:validate

Step 1: Detect Documentation Gaps

Run the automated gap detection script to inspect recent git commits and find unindexed markdown files:

python .agents/skills/vitepress-doc-sync/scripts/detect_doc_gaps.py --since HEAD~10

This generates .agents/skills/vitepress-doc-sync/doc_gaps_report.json summarizing:


Step 2: Analyze Git Diffs & Map to Docs

Inspect changed codebase files and map them to their target documentation files:

  1. Consult Mapping Guide: Read references/git_diff_analysis_guide.md for domain-specific mappings (e.g. MCP tools → guides/builtin-tools.md, Skills → guides/skills.md).
  2. Identify Impact:

Step 3: Edit & Update Documentation Pages

Follow VitePress formatting guidelines in references/vitepress_formatting_guide.md:


Step 4: Sync VitePress Sidebar & Navigation

If new .md files were created in docs/user/ or existing files were reorganized:

  1. Open website/.vitepress/config.ts.
  2. Register the new page under the appropriate category in koSidebar:

```typescript

{ text: '새 기능 제목', link: '/guides/new-feature' }

```

  1. Register the corresponding English page in enSidebar:

```typescript

{ text: 'New Feature Title', link: '/en/guides/new-feature' }

```


Step 5: Validate VitePress Site Build

Verify that VitePress compiles cleanly without dead links or syntax errors:

pnpm --filter website build

Or perform full project validation:

pnpm refactor:validate
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.