This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
This is the documentation website for Capa (Cloud Application API) - a Mecha architecture-based multi-runtime SDK for Java applications. The site is built with Hugo using the Docsy theme and published to GitHub Pages.
- Live site: https://capa.rxcloud.group/
- Repository: https://github.com/capa-cloud/capa.io
- Default language: Chinese (zh), with English support
- Hugo (extended version, v0.88.1+ recommended)
- Node.js and npm (for PostCSS/Autoprefixer)
- Git submodules (for Docsy theme)
# Initialize git submodules (required for Docsy theme)
git submodule update --init --recursive
# Install npm dependencies
npm install# Run Hugo development server
hugo server
# Run with draft content included
hugo server -D
# Run with live reload (default binds to localhost:1313)
hugo server --bind 0.0.0.0# Build the site (output goes to docs/ directory)
hugo --gc
# Build for production
HUGO_ENV="production" hugo --gc# Run using Docker Compose
docker-compose up
# Or build and run manually
docker build -t capa-docs .
docker run -p 1313:1313 -v $(pwd):/src capa-docs server- Config file:
config.toml - Theme: Docsy (git submodule at
themes/docsy/) - Content directory:
content/(organized by language:zh/,en/) - Default content language: Chinese (
zh) - Output directory:
docs/(configured for GitHub Pages)
Content is organized under content/zh/ and content/en/:
content/
├── zh/ # Chinese content (default)
│ ├── _index.html # Homepage
│ ├── docs/ # Documentation
│ │ ├── Overview/ # Overview section
│ │ ├── GettingStarted/ # Getting started guides
│ │ ├── Concepts/ # Concept documentation
│ │ ├── Tasks/ # Task guides
│ │ ├── Examples/ # Examples
│ │ ├── Reference/ # API reference
│ │ └── ContributionGuidelines/
│ ├── blog/ # Blog posts
│ ├── about/ # About page
│ ├── community/ # Community page
│ └── search.md # Search page
└── en/ # English content (mirrors zh structure)
- Base URL:
https://capa.rxcloud.group/ - GitHub repo links: Point to
https://github.com/capa-cloud/capa - Search: Uses Google Custom Search Engine (gcs_engine_id)
- Syntax highlighting: Uses Chroma with "tango" style
- Markdown engine: Goldmark with unsafe HTML enabled
- Images:
content/images/or page bundles - Logo: Configure in
assets/icons/logo.svg(navbar_logo is currently false) - Featured background:
content/zh/featured-background.jpg
The site is deployed to GitHub Pages via GitHub Actions (.github/workflows/deploy.yml):
- Push to
mastertriggers the workflow - Hugo builds the site with
--gc --minify --destination docs peaceiris/actions-gh-pages@v3deploys to thegh-pagesbranch- Custom domain:
capa.rxcloud.group(configured viastatic/CNAME)
- Create a new
.mdfile in the appropriate section undercontent/zh/docs/ - Add front matter with title, description, and weight (for ordering)
- Create corresponding English version under
content/en/docs/if needed
- Create a new folder under
content/zh/blog/with anindex.mdfile - Use front matter with date, title, description, and author
# Update Docsy theme to latest version
git submodule update --remote --merge- The site uses a bilingual setup with Chinese as the default language
- The
docs/directory contains the built site and should be regenerated withhugo --gcbefore committing - The Docsy theme is included as a git submodule - ensure it's initialized when cloning
- Some feature images are generated by Hugo's image processing (stored in
resources/)