This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
Personal blog built with VitePress, deployed to GitHub Pages. Posts are markdown files under docs/YYYY/MM/DD/ with YAML frontmatter (title, date, tags, categories).
npm run docs:dev— Start local dev server with hot-reloadnpm run docs:build— Build static site todocs/.vitepress/distnpm run docs:preview— Preview built site locallybash deploy.sh— Build + force-push togh-pagesbranch (master)bash scripts/sync-index.sh— Scan all posts and auto-update home page features, sidebar, and archives page
- Create a new
.mdfile underdocs/YYYY/MM/DD/with proper frontmatter (title, date, tags, categories) - Insert
<!-- more -->after the intro paragraph to control excerpt shown on home page - Run
bash scripts/sync-index.shto update index/sidebar/archives - Run
npm run docs:buildto verify build passes - Run
bash deploy.shto deploy
docs/— All site content (markdown files + VitePress config)docs/.vitepress/config.mjs— Site config (nav, sidebar, social links, footer)docs/index.md— Home page with hero + features (auto-updated by sync-index.sh)docs/archives.md— Archive listing (auto-updated by sync-index.sh)docs/tags.md— Tags pagedocs/about.md— About page
scripts/sync-index.sh— Automation: parses frontmatter from all posts and regenerates index.md features, config.mjs sidebar, and archives.mddeploy.sh— Builds then force-pushes togit@github.com:GonChen/gonchen.github.com.gitmaster branch