diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3b45a4d..e9a4d3f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -77,3 +77,6 @@ jobs: } console.log('package.json OK:', pkg.name, 'v' + pkg.version); " + + - name: Validate install script + run: node bin/superpowers-zh.js --help diff --git a/README.md b/README.md index 81ad9f8..2119366 100644 --- a/README.md +++ b/README.md @@ -16,15 +16,36 @@ Chinese community edition of [superpowers](https://github.com/obra/superpowers), | 📦 翻译 Skills | 🇨🇳 中国特色 Skills | 🤖 支持工具 | |:---:|:---:|:---:| -| **14** | **5** | **Claude Code / Cursor / Codex / Kiro / DeerFlow / Trae / Antigravity / VS Code / Gemini / OpenClaw** | +| **14** | **6** | **Claude Code / Cursor / Codex / Kiro / DeerFlow / Trae / Antigravity / VS Code / Gemini CLI / OpenClaw / Windsurf / Aider / OpenCode / Qwen Code** | --- ## 这是什么? -[superpowers](https://github.com/obra/superpowers) 是目前最火的 AI 编程 skills 框架(99k+ stars),为 Claude Code、Cursor 等 AI 编程工具提供**系统化的工作方法论**。 +[superpowers](https://github.com/obra/superpowers) 是目前最火的 AI 编程 skills 框架(99k+ stars),为 AI 编程工具提供**系统化的工作方法论**。 -**superpowers-zh** 在完整翻译的基础上,新增了面向中国开发者的特色 skills: +**superpowers-zh** 在完整翻译的基础上,新增了面向中国开发者的特色 skills。 + +### 🤖 支持 14 款主流 AI 编程工具 + +| 工具 | 类型 | 一键安装 | 手动安装 | +|------|------|:---:|:---:| +| [Claude Code](https://claude.ai/code) | CLI | `npx superpowers-zh` | `.claude/skills/` | +| [Cursor](https://cursor.sh) | IDE | `npx superpowers-zh` | `.cursor/skills/` | +| [Windsurf](https://codeium.com/windsurf) | IDE | `npx superpowers-zh` | `.windsurf/skills/` | +| [VS Code](https://code.visualstudio.com) (Copilot) | IDE 插件 | `npx superpowers-zh` | `.github/superpowers/` | +| [Kiro](https://kiro.dev) | IDE | `npx superpowers-zh` | `.kiro/steering/` | +| [Trae](https://trae.ai) | IDE | `npx superpowers-zh` | `.trae/rules/` | +| [Aider](https://aider.chat) | CLI | `npx superpowers-zh` | `.aider/skills/` | +| [Gemini CLI](https://github.com/google-gemini/gemini-cli) | CLI | `npx superpowers-zh` | `.gemini/skills/` | +| [Codex CLI](https://github.com/openai/codex) | CLI | `npx superpowers-zh` | `.codex/skills/` | +| [DeerFlow 2.0](https://github.com/bytedance/deer-flow) | Agent 框架 | `npx superpowers-zh` | `skills/custom/` | +| [OpenClaw](https://github.com/anthropics/openclaw) | CLI | `npx superpowers-zh` | `skills/` | +| [OpenCode](https://opencode.ai) | CLI | `npx superpowers-zh` | `.opencode/skills/` | +| [Qwen Code](https://tongyi.aliyun.com/lingma) (通义灵码) | IDE 插件 | `npx superpowers-zh` | `.qwen/skills/` | +| [Antigravity](https://github.com/anthropics/antigravity) | CLI | `npx superpowers-zh` | `.antigravity/skills/` | + +> 运行 `npx superpowers-zh` 会自动检测你项目中使用的工具,将 20 个 skills 安装到正确位置。 ### 翻译的 Skills(14 个) @@ -45,7 +66,7 @@ Chinese community edition of [superpowers](https://github.com/obra/superpowers), | **编写 Skills** (writing-skills) | 创建新 skill 的方法论 | | **使用 Superpowers** (using-superpowers) | 元技能:如何调用和优先使用 skills | -### 🇨🇳 中国特色 Skills(5 个) +### 🇨🇳 中国特色 Skills(6 个) | Skill | 用途 | 上游有吗? | |-------|------|:---:| @@ -54,6 +75,7 @@ Chinese community edition of [superpowers](https://github.com/obra/superpowers), | **中文技术文档** (chinese-documentation) | 中文排版规范、中英混排、告别机翻味 | 无 | | **中文提交规范** (chinese-commit-conventions) | 适配国内团队的 commit message 规范 | 无 | | **MCP 服务器构建** (mcp-builder) | 构建生产级 MCP 工具,扩展 AI 能力边界 | 无 | +| **工作流执行器** (workflow-runner) | 在 AI 工具内运行多角色 YAML 工作流 | 无 | --- @@ -80,7 +102,13 @@ cp -r superpowers-zh/skills /your/project/.kiro/steering # Kiro cp -r superpowers-zh/skills /your/project/skills/custom # DeerFlow 2.0 cp -r superpowers-zh/skills /your/project/.trae/rules # Trae cp -r superpowers-zh/skills /your/project/.antigravity # Antigravity +cp -r superpowers-zh/skills /your/project/.github/superpowers # VS Code (Copilot) cp -r superpowers-zh/skills /your/project/skills # OpenClaw +cp -r superpowers-zh/skills /your/project/.windsurf/skills # Windsurf +cp -r superpowers-zh/skills /your/project/.gemini/skills # Gemini CLI +cp -r superpowers-zh/skills /your/project/.aider/skills # Aider +cp -r superpowers-zh/skills /your/project/.opencode/skills # OpenCode +cp -r superpowers-zh/skills /your/project/.qwen/skills # Qwen Code ``` ### 方式三:在配置文件中引用 @@ -97,8 +125,13 @@ cp -r superpowers-zh/skills /your/project/skills # OpenClaw | VS Code | `.github/copilot-instructions.md` | Copilot 自定义指令 | | Cursor | `.cursor/rules/*.md` | 项目级规则目录 | | OpenClaw | `skills/*/SKILL.md` | 工作区级 skills 目录,自动发现 | +| Windsurf | `.windsurf/skills/*/SKILL.md` | 项目级 skills 目录 | +| Gemini CLI | `.gemini/skills/*/SKILL.md` | 项目级 skills 目录 | +| Aider | `.aider/skills/*/SKILL.md` | 项目级 skills 目录 | +| OpenCode | `.opencode/skills/*/SKILL.md` | 项目级 skills 目录 | +| Qwen Code | `.qwen/skills/*/SKILL.md` | 项目级 skills 目录 | -> **详细安装指南**:[Kiro](docs/README.kiro.md) · [DeerFlow](docs/README.deerflow.md) · [Trae](docs/README.trae.md) · [Antigravity](docs/README.antigravity.md) · [VS Code](docs/README.vscode.md) · [Codex](docs/README.codex.md) · [OpenCode](docs/README.opencode.md) · [OpenClaw](docs/README.openclaw.md) +> **详细安装指南**:[Kiro](docs/README.kiro.md) · [DeerFlow](docs/README.deerflow.md) · [Trae](docs/README.trae.md) · [Antigravity](docs/README.antigravity.md) · [VS Code](docs/README.vscode.md) · [Codex](docs/README.codex.md) · [OpenCode](docs/README.opencode.md) · [OpenClaw](docs/README.openclaw.md) · [Windsurf](docs/README.windsurf.md) · [Gemini CLI](docs/README.gemini-cli.md) · [Aider](docs/README.aider.md) · [Qwen Code](docs/README.qwen.md) --- @@ -106,7 +139,7 @@ cp -r superpowers-zh/skills /your/project/skills # OpenClaw | 特性 | superpowers (英文) | superpowers-zh (中文) | |------|-------------------|----------------------| -| Skills 数量 | 14 | **19**(14 翻译 + 5 原创) | +| Skills 数量 | 14 | **20**(14 翻译 + 6 原创) | | 语言 | 英文 | 中文(技术术语保留英文) | | 代码审查规范 | 西方直接风格 | 适配国内团队沟通文化 | | Git 平台 | GitHub 为主 | GitHub + Gitee + Coding + 极狐 | diff --git a/bin/superpowers-zh.js b/bin/superpowers-zh.js index 6f58863..45e251b 100755 --- a/bin/superpowers-zh.js +++ b/bin/superpowers-zh.js @@ -20,6 +20,11 @@ const TARGETS = [ { name: 'Antigravity', dir: '.antigravity/skills', detect: '.antigravity' }, { name: 'VS Code', dir: '.github/superpowers', detect: '.github/copilot-instructions.md' }, { name: 'OpenClaw', dir: 'skills', detect: '.openclaw' }, + { name: 'Windsurf', dir: '.windsurf/skills', detect: '.windsurf' }, + { name: 'Gemini CLI', dir: '.gemini/skills', detect: 'GEMINI.md' }, + { name: 'Aider', dir: '.aider/skills', detect: '.aider' }, + { name: 'OpenCode', dir: '.opencode/skills', detect: '.opencode' }, + { name: 'Qwen Code', dir: '.qwen/skills', detect: '.qwen' }, ]; function countDirs(dir) { @@ -39,6 +44,7 @@ function showHelp() { 说明: 自动检测当前项目使用的 AI 编程工具: Claude Code / Cursor / Codex / Kiro / DeerFlow / Trae / Antigravity / VS Code / OpenClaw + Windsurf / Gemini CLI / Aider / OpenCode / Qwen Code 将 ${countDirs(SKILLS_SRC)} 个 skills 安装到对应目录。 Claude Code 还会额外安装 agents 到 .claude/agents/。 如果未检测到任何工具,默认安装到 .claude/skills/ 和 .claude/agents/。 diff --git a/docs/README.aider.md b/docs/README.aider.md new file mode 100644 index 0000000..55094a4 --- /dev/null +++ b/docs/README.aider.md @@ -0,0 +1,61 @@ +# Superpowers 中文版 — Aider 安装指南 + +在 [Aider](https://aider.chat) 中使用 superpowers-zh 的完整指南。 + +## 自动安装 + +```bash +cd /your/project +npx superpowers-zh +``` + +安装脚本会自动检测 `.aider.conf.yml` 文件并将 skills 复制到 `.aider/skills/` 目录。 + +## 手动安装 + +```bash +git clone https://github.com/jnMetaCode/superpowers-zh.git +cp -r superpowers-zh/skills /your/project/.aider/skills +``` + +## 通过 CONVENTIONS.md 引用 + +Aider 原生支持 `CONVENTIONS.md` 文件。在其中引用 skills: + +```markdown +# 项目约定 + +## 工作方法论 + +本项目使用 superpowers-zh skills 作为工作方法论。 +Skills 位于 `.aider/skills/` 目录,每个子目录的 SKILL.md 定义一个工作流。 + +- 新功能开发:先使用 brainstorming skill +- 编写代码:遵循 test-driven-development skill +- 调试问题:使用 systematic-debugging skill +``` + +## 通过 .aider.conf.yml 配置 + +在 `.aider.conf.yml` 中添加 read 配置来加载 skills: + +```yaml +read: + - .aider/skills/brainstorming/SKILL.md + - .aider/skills/test-driven-development/SKILL.md + - .aider/skills/systematic-debugging/SKILL.md +``` + +## 故障排查 + +### Skills 未生效 + +1. 确认 `.aider/skills/` 目录存在且包含 skill 文件夹 +2. 确保在 `CONVENTIONS.md` 或 `.aider.conf.yml` 中引用了 skills +3. Aider 会自动读取 `CONVENTIONS.md`,无需额外配置 + +## 获取帮助 + +- 提交 Issue:https://github.com/jnMetaCode/superpowers-zh/issues +- 项目主页:https://github.com/jnMetaCode/superpowers-zh +- Aider 文档:https://aider.chat/docs/ diff --git a/docs/README.gemini-cli.md b/docs/README.gemini-cli.md new file mode 100644 index 0000000..18ffe87 --- /dev/null +++ b/docs/README.gemini-cli.md @@ -0,0 +1,65 @@ +# Superpowers 中文版 — Gemini CLI 安装指南 + +在 [Gemini CLI](https://github.com/google-gemini/gemini-cli) 中使用 superpowers-zh 的完整指南。 + +## 自动安装 + +```bash +cd /your/project +npx superpowers-zh +``` + +安装脚本会自动检测 `.gemini/` 目录并将 skills 复制到 `.gemini/skills/` 目录。 + +## 手动安装 + +```bash +git clone https://github.com/jnMetaCode/superpowers-zh.git +cp -r superpowers-zh/skills /your/project/.gemini/skills +``` + +或作为 Gemini 扩展安装(全局): + +```bash +mkdir -p ~/.gemini/extensions/superpowers-zh/skills +cp -r superpowers-zh/skills/* ~/.gemini/extensions/superpowers-zh/skills/ +cp superpowers-zh/gemini-extension.json ~/.gemini/extensions/superpowers-zh/ +``` + +## 通过 GEMINI.md 引用 + +在项目根目录的 `GEMINI.md` 中引用 skills: + +```markdown +# 工作方法论 + +请参考 .gemini/skills/ 目录中的 SKILL.md 文件。 +遇到新功能开发时,先使用 brainstorming skill。 +编写代码时,遵循 test-driven-development skill。 +``` + +## Skill 加载优先级 + +| 位置 | 优先级 | 说明 | +|------|--------|------| +| `.gemini/skills/` | 最高 | 项目级,仅当前项目 | +| `~/.gemini/extensions/*/skills/` | 中 | 扩展级,所有项目共享 | + +## 故障排查 + +### Skills 未生效 + +1. 确认 `.gemini/skills/` 目录存在且包含 skill 文件夹 +2. 每个 skill 需要包含有效 YAML frontmatter 的 `SKILL.md` 文件 +3. 重启 Gemini CLI + +### 扩展模式未加载 + +1. 检查 `gemini-extension.json` 是否正确放在扩展目录中 +2. 确认扩展目录结构:`~/.gemini/extensions/superpowers-zh/` + +## 获取帮助 + +- 提交 Issue:https://github.com/jnMetaCode/superpowers-zh/issues +- 项目主页:https://github.com/jnMetaCode/superpowers-zh +- Gemini CLI 文档:https://github.com/google-gemini/gemini-cli diff --git a/docs/README.openclaw.md b/docs/README.openclaw.md index 50d2394..1a5f043 100644 --- a/docs/README.openclaw.md +++ b/docs/README.openclaw.md @@ -1,6 +1,6 @@ # Superpowers 中文版 — OpenClaw 安装指南 -在 [OpenClaw](https://github.com/anthropics/claude-code) 中使用 superpowers-zh 的完整指南。 +在 [OpenClaw](https://github.com/anthropics/openclaw) 中使用 superpowers-zh 的完整指南。 ## 快速安装 diff --git a/docs/README.qwen.md b/docs/README.qwen.md new file mode 100644 index 0000000..a914487 --- /dev/null +++ b/docs/README.qwen.md @@ -0,0 +1,61 @@ +# Superpowers 中文版 — Qwen Code 安装指南 + +在 [Qwen Code](https://tongyi.aliyun.com/qianwen) (通义灵码) 中使用 superpowers-zh 的完整指南。 + +## 自动安装 + +```bash +cd /your/project +npx superpowers-zh +``` + +安装脚本会自动检测 `.qwen/` 目录并将 skills 复制到 `.qwen/skills/` 目录。 + +## 手动安装 + +```bash +git clone https://github.com/jnMetaCode/superpowers-zh.git +cp -r superpowers-zh/skills /your/project/.qwen/skills +``` + +或全局安装: + +```bash +mkdir -p ~/.qwen/skills +cp -r superpowers-zh/skills/* ~/.qwen/skills/ +``` + +## Skill 加载优先级 + +| 位置 | 优先级 | 说明 | +|------|--------|------| +| `.qwen/skills/` | 最高 | 项目级,仅当前项目 | +| `~/.qwen/skills/` | 中 | 用户级,所有项目共享 | + +## 使用 + +安装完成后重启 Qwen Code,skills 会自动生效。 + +在 Qwen Code 中可以通过以下方式调用 skills: + +``` +请使用 brainstorming skill 来分析这个需求 +``` + +``` +按照 test-driven-development skill 的方法来实现这个功能 +``` + +## 故障排查 + +### Skills 未生效 + +1. 确认 `.qwen/skills/` 目录存在且包含 skill 文件夹 +2. 每个 skill 需要包含有效 YAML frontmatter 的 `SKILL.md` 文件 +3. 重启 Qwen Code 或刷新会话 + +## 获取帮助 + +- 提交 Issue:https://github.com/jnMetaCode/superpowers-zh/issues +- 项目主页:https://github.com/jnMetaCode/superpowers-zh +- 通义灵码文档:https://tongyi.aliyun.com/lingma diff --git a/docs/README.windsurf.md b/docs/README.windsurf.md new file mode 100644 index 0000000..9a0d7ce --- /dev/null +++ b/docs/README.windsurf.md @@ -0,0 +1,56 @@ +# Superpowers 中文版 — Windsurf 安装指南 + +在 [Windsurf](https://codeium.com/windsurf) 中使用 superpowers-zh 的完整指南。 + +## 自动安装 + +```bash +cd /your/project +npx superpowers-zh +``` + +安装脚本会自动检测 `.windsurf/` 目录并将 skills 复制到 `.windsurf/skills/` 目录。 + +## 手动安装 + +```bash +git clone https://github.com/jnMetaCode/superpowers-zh.git +cp -r superpowers-zh/skills /your/project/.windsurf/skills +``` + +或全局安装: + +```bash +cp -r superpowers-zh/skills ~/.windsurf/skills +``` + +## Skill 加载优先级 + +| 位置 | 优先级 | 说明 | +|------|--------|------| +| `.windsurf/skills/` | 最高 | 项目级,仅当前项目 | +| `~/.windsurf/skills/` | 中 | 用户级,所有项目共享 | + +## 使用 + +安装完成后重启 Windsurf,skills 会自动生效。 + +也可以在 `.windsurfrules` 文件中引用 skills 目录: + +``` +请参考 .windsurf/skills/ 目录中的 SKILL.md 文件作为工作方法论。 +``` + +## 故障排查 + +### Skills 未生效 + +1. 确认 `.windsurf/skills/` 目录存在且包含 skill 文件夹 +2. 每个 skill 需要包含有效 YAML frontmatter 的 `SKILL.md` 文件 +3. 重启 Windsurf + +## 获取帮助 + +- 提交 Issue:https://github.com/jnMetaCode/superpowers-zh/issues +- 项目主页:https://github.com/jnMetaCode/superpowers-zh +- Windsurf 文档:https://docs.codeium.com/windsurf diff --git a/gemini-extension.json b/gemini-extension.json index d1020a0..3caad98 100644 --- a/gemini-extension.json +++ b/gemini-extension.json @@ -1,6 +1,6 @@ { - "name": "superpowers", - "description": "Core skills library: TDD, debugging, collaboration patterns, and proven techniques", - "version": "5.0.0", + "name": "superpowers-zh", + "description": "AI 编程超能力中文版 — TDD、调试、代码审查等经过实战验证的工作方法论", + "version": "1.1.1", "contextFileName": "GEMINI.md" } diff --git a/package.json b/package.json index d26dd89..6d8aac9 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "superpowers-zh", "version": "1.1.1", - "description": "AI 编程超能力中文版 — 14 个翻译 + 6 个中国特色原创 skills", + "description": "AI 编程超能力中文版 — 20 个 skills,支持 Claude Code / Cursor / Windsurf / Copilot / Kiro / Trae / Aider / Gemini CLI / Codex / DeerFlow / OpenClaw / OpenCode / Qwen Code / Antigravity 共 14 款工具", "type": "module", "main": ".opencode/plugins/superpowers.js", "bin": { @@ -19,6 +19,7 @@ ".opencode/", "GEMINI.md", "gemini-extension.json", + "docs/", "README.md", "LICENSE" ], @@ -33,6 +34,10 @@ "trae", "antigravity", "openclaw", + "windsurf", + "aider", + "opencode", + "qwen", "vscode", "copilot", "ai-coding",