deploy-docs

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Deploy Documentation Command

部署文档命令

Validate the documentation site and prepare it for GitHub Pages deployment.
验证文档站点并为GitHub Pages部署做好准备。

Step 1: Validate Documentation

步骤1:验证文档

Run these checks:
bash
undefined
运行以下检查:
bash
undefined

Count components

Count components

echo "Agents: $(ls plugins/compound-engineering/agents/.md | wc -l)" echo "Skills: $(ls -d plugins/compound-engineering/skills// 2>/dev/null | wc -l)"
echo "Agents: $(ls plugins/compound-engineering/agents/.md | wc -l)" echo "Skills: $(ls -d plugins/compound-engineering/skills// 2>/dev/null | wc -l)"

Validate JSON

Validate JSON

cat .claude-plugin/marketplace.json | jq . > /dev/null && echo "✓ marketplace.json valid" cat plugins/compound-engineering/.claude-plugin/plugin.json | jq . > /dev/null && echo "✓ plugin.json valid"
cat .claude-plugin/marketplace.json | jq . > /dev/null && echo "✓ marketplace.json valid" cat plugins/compound-engineering/.claude-plugin/plugin.json | jq . > /dev/null && echo "✓ plugin.json valid"

Check all HTML files exist

Check all HTML files exist

for page in index agents commands skills mcp-servers changelog getting-started; do if [ -f "plugins/compound-engineering/docs/pages/${page}.html" ] || [ -f "plugins/compound-engineering/docs/${page}.html" ]; then echo "✓ ${page}.html exists" else echo "✗ ${page}.html MISSING" fi done
undefined
for page in index agents commands skills mcp-servers changelog getting-started; do if [ -f "plugins/compound-engineering/docs/pages/${page}.html" ] || [ -f "plugins/compound-engineering/docs/${page}.html" ]; then echo "✓ ${page}.html exists" else echo "✗ ${page}.html MISSING" fi done
undefined

Step 2: Check for Uncommitted Changes

步骤2:检查未提交的变更

bash
git status --porcelain plugins/compound-engineering/docs/
If there are uncommitted changes, warn the user to commit first.
bash
git status --porcelain plugins/compound-engineering/docs/
如果存在未提交的变更,提醒用户先提交。

Step 3: Deployment Instructions

步骤3:部署说明

Since GitHub Pages deployment requires a workflow file with special permissions, provide these instructions:
由于GitHub Pages部署需要带有特殊权限的工作流文件,请遵循以下说明:

First-time Setup

首次设置

  1. Create
    .github/workflows/deploy-docs.yml
    with the GitHub Pages workflow
  2. Go to repository Settings > Pages
  3. Set Source to "GitHub Actions"
  1. 创建
    .github/workflows/deploy-docs.yml
    文件,写入GitHub Pages工作流内容
  2. 进入仓库设置 > Pages页面
  3. 将源设置为"GitHub Actions"

Deploying

部署操作

After merging to
main
, the docs will auto-deploy. Or:
  1. Go to Actions tab
  2. Select "Deploy Documentation to GitHub Pages"
  3. Click "Run workflow"
合并到
main
分支后,文档将自动部署。或者手动操作:
  1. 进入Actions标签页
  2. 选择"Deploy Documentation to GitHub Pages"工作流
  3. 点击"Run workflow"

Workflow File Content

工作流文件内容

yaml
name: Deploy Documentation to GitHub Pages

on:
  push:
    branches: [main]
    paths:
      - 'plugins/compound-engineering/docs/**'
  workflow_dispatch:

permissions:
  contents: read
  pages: write
  id-token: write

concurrency:
  group: "pages"
  cancel-in-progress: false

jobs:
  deploy:
    environment:
      name: github-pages
      url: ${{ steps.deployment.outputs.page_url }}
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: actions/configure-pages@v4
      - uses: actions/upload-pages-artifact@v3
        with:
          path: 'plugins/compound-engineering/docs'
      - uses: actions/deploy-pages@v4
yaml
name: Deploy Documentation to GitHub Pages

on:
  push:
    branches: [main]
    paths:
      - 'plugins/compound-engineering/docs/**'
  workflow_dispatch:

permissions:
  contents: read
  pages: write
  id-token: write

concurrency:
  group: "pages"
  cancel-in-progress: false

jobs:
  deploy:
    environment:
      name: github-pages
      url: ${{ steps.deployment.outputs.page_url }}
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: actions/configure-pages@v4
      - uses: actions/upload-pages-artifact@v3
        with:
          path: 'plugins/compound-engineering/docs'
      - uses: actions/deploy-pages@v4

Step 4: Report Status

步骤4:状态报告

Provide a summary:
undefined
提供以下总结:
undefined

Deployment Readiness

Deployment Readiness

✓ All HTML pages present ✓ JSON files valid ✓ Component counts match
✓ All HTML pages present ✓ JSON files valid ✓ Component counts match

Next Steps

Next Steps

undefined
undefined