superpowers-zh 1.1.0 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/marketplace.json +3 -3
- package/.claude-plugin/plugin.json +2 -2
- package/.cursor-plugin/plugin.json +2 -2
- package/README.md +81 -13
- package/bin/superpowers-zh.js +101 -5
- package/docs/README.aider.md +61 -0
- package/docs/README.antigravity.md +93 -0
- package/docs/README.codex.md +91 -0
- package/docs/README.deerflow.md +65 -0
- package/docs/README.gemini-cli.md +65 -0
- package/docs/README.kiro.md +69 -0
- package/docs/README.openclaw.md +102 -0
- package/docs/README.opencode.md +108 -0
- package/docs/README.qwen.md +61 -0
- package/docs/README.trae.md +62 -0
- package/docs/README.vscode.md +98 -0
- package/docs/README.windsurf.md +56 -0
- package/docs/assets/RECORDING-GUIDE.md +47 -0
- package/docs/assets/demo.tape +99 -0
- package/gemini-extension.json +3 -3
- package/package.json +9 -2
- package/skills/brainstorming/SKILL.md +14 -14
- package/skills/workflow-runner/SKILL.md +172 -0
- package/skills/writing-plans/SKILL.md +19 -12
- package/skills/writing-skills/SKILL.md +2 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "superpowers-zh",
|
|
3
|
-
"description": "AI
|
|
3
|
+
"description": "AI 编程超能力中文增强版:20 个 skills,支持 OpenClaw / Claude Code / Cursor 等 14 款工具",
|
|
4
4
|
"owner": {
|
|
5
5
|
"name": "jnMetaCode",
|
|
6
6
|
"url": "https://github.com/jnMetaCode"
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
"plugins": [
|
|
9
9
|
{
|
|
10
10
|
"name": "superpowers-zh",
|
|
11
|
-
"description": "AI
|
|
12
|
-
"version": "1.
|
|
11
|
+
"description": "AI 编程超能力中文增强版:20 个 skills(14 翻译 + 6 中国原创),支持 OpenClaw / Claude Code / Cursor 等 14 款工具",
|
|
12
|
+
"version": "1.1.1",
|
|
13
13
|
"source": "./",
|
|
14
14
|
"author": {
|
|
15
15
|
"name": "jnMetaCode",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "superpowers-zh",
|
|
3
|
-
"description": "AI
|
|
4
|
-
"version": "1.
|
|
3
|
+
"description": "AI 编程超能力中文增强版:20 个 skills(14 翻译 + 6 中国原创),支持 OpenClaw / Claude Code / Cursor 等 14 款工具",
|
|
4
|
+
"version": "1.1.1",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "jnMetaCode",
|
|
7
7
|
"url": "https://github.com/jnMetaCode"
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "superpowers-zh",
|
|
3
3
|
"displayName": "Superpowers 中文版",
|
|
4
|
-
"description": "AI
|
|
5
|
-
"version": "1.
|
|
4
|
+
"description": "AI 编程超能力中文增强版:20 个 skills(14 翻译 + 6 中国原创),支持 OpenClaw / Cursor / Claude Code 等 14 款工具",
|
|
5
|
+
"version": "1.1.1",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "jnMetaCode",
|
|
8
8
|
"url": "https://github.com/jnMetaCode"
|
package/README.md
CHANGED
|
@@ -1,30 +1,78 @@
|
|
|
1
|
-
# superpowers-zh(AI 编程超能力 ·
|
|
1
|
+
# superpowers-zh(AI 编程超能力 · 中文增强版)
|
|
2
2
|
|
|
3
3
|
🌐 **简体中文** | [English (upstream)](https://github.com/obra/superpowers)
|
|
4
4
|
|
|
5
|
-
>
|
|
5
|
+
> 🦸 **superpowers(116k+ ⭐)完整汉化 + 6 个中国原创 skills** — 让 OpenClaw / Claude Code / Cursor / Windsurf / Kiro / Gemini CLI 等 **14 款 AI 编程工具**真正会干活。从头脑风暴到代码审查,从 TDD 到调试,每个 skill 都是经过实战验证的工作方法论。
|
|
6
6
|
|
|
7
|
-
Chinese community edition of [superpowers](https://github.com/obra/superpowers), including full translations and China-specific development skills.
|
|
7
|
+
Chinese community edition of [superpowers](https://github.com/obra/superpowers) — 20 skills across 14 AI coding tools, including full translations and China-specific development skills.
|
|
8
|
+
|
|
9
|
+
<!-- 效果对比 -->
|
|
10
|
+
<table>
|
|
11
|
+
<tr><td>
|
|
12
|
+
|
|
13
|
+
**没装 superpowers-zh:**
|
|
14
|
+
```
|
|
15
|
+
你:给用户模块加个批量导出功能
|
|
16
|
+
AI:好的,我来实现...(直接开始写代码)
|
|
17
|
+
export async function exportUsers() { ... }
|
|
18
|
+
你:等等,格式不对,没分页,大数据量会 OOM...
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
</td><td>
|
|
22
|
+
|
|
23
|
+
**装了 superpowers-zh:**
|
|
24
|
+
```
|
|
25
|
+
你:给用户模块加个批量导出功能
|
|
26
|
+
AI:在开始实现之前,我需要了解几个关键问题:
|
|
27
|
+
1. 导出格式是 CSV 还是 Excel?
|
|
28
|
+
2. 预计数据量多大?需要异步处理吗?
|
|
29
|
+
3. 有权限要求吗?
|
|
30
|
+
→ 给出 2-3 个方案,确认后再动手
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
</td></tr>
|
|
34
|
+
</table>
|
|
8
35
|
|
|
9
36
|
[](https://github.com/jnMetaCode/superpowers-zh)
|
|
10
37
|
[](https://www.npmjs.com/package/superpowers-zh)
|
|
11
38
|
[](https://opensource.org/licenses/MIT)
|
|
12
39
|
[](https://makeapullrequest.com)
|
|
13
|
-
[](https://qm.qq.com/q/EeNQA9xCxy)
|
|
14
41
|
|
|
15
42
|
### 📊 项目规模
|
|
16
43
|
|
|
17
44
|
| 📦 翻译 Skills | 🇨🇳 中国特色 Skills | 🤖 支持工具 |
|
|
18
45
|
|:---:|:---:|:---:|
|
|
19
|
-
| **14** | **
|
|
46
|
+
| **14** | **6** | **OpenClaw / Claude Code / Cursor / Windsurf / Kiro / Gemini CLI / Codex / Aider / Trae / VS Code (Copilot) / DeerFlow / OpenCode / Qwen Code / Antigravity** |
|
|
20
47
|
|
|
21
48
|
---
|
|
22
49
|
|
|
23
50
|
## 这是什么?
|
|
24
51
|
|
|
25
|
-
[superpowers](https://github.com/obra/superpowers) 是目前最火的 AI 编程 skills 框架(
|
|
52
|
+
[superpowers](https://github.com/obra/superpowers) 是目前最火的 AI 编程 skills 框架(116k+ stars),为 AI 编程工具提供**系统化的工作方法论**。
|
|
53
|
+
|
|
54
|
+
**superpowers-zh** 在完整翻译的基础上,新增了面向中国开发者的特色 skills。
|
|
55
|
+
|
|
56
|
+
### 🤖 支持 14 款主流 AI 编程工具
|
|
57
|
+
|
|
58
|
+
| 工具 | 类型 | 一键安装 | 手动安装 |
|
|
59
|
+
|------|------|:---:|:---:|
|
|
60
|
+
| [OpenClaw](https://github.com/anthropics/openclaw) | CLI | `npx superpowers-zh` | `skills/` |
|
|
61
|
+
| [Claude Code](https://claude.ai/code) | CLI | `npx superpowers-zh` | `.claude/skills/` |
|
|
62
|
+
| [Cursor](https://cursor.sh) | IDE | `npx superpowers-zh` | `.cursor/skills/` |
|
|
63
|
+
| [Windsurf](https://codeium.com/windsurf) | IDE | `npx superpowers-zh` | `.windsurf/skills/` |
|
|
64
|
+
| [Kiro](https://kiro.dev) | IDE | `npx superpowers-zh` | `.kiro/steering/` |
|
|
65
|
+
| [Gemini CLI](https://github.com/google-gemini/gemini-cli) | CLI | `npx superpowers-zh` | `.gemini/skills/` |
|
|
66
|
+
| [Codex CLI](https://github.com/openai/codex) | CLI | `npx superpowers-zh` | `.codex/skills/` |
|
|
67
|
+
| [Aider](https://aider.chat) | CLI | `npx superpowers-zh` | `.aider/skills/` |
|
|
68
|
+
| [Trae](https://trae.ai) | IDE | `npx superpowers-zh` | `.trae/skills/` + `.trae/rules/` |
|
|
69
|
+
| [VS Code](https://code.visualstudio.com) (Copilot) | IDE 插件 | `npx superpowers-zh` | `.github/superpowers/` |
|
|
70
|
+
| [DeerFlow 2.0](https://github.com/bytedance/deer-flow) | Agent 框架 | `npx superpowers-zh` | `skills/custom/` |
|
|
71
|
+
| [OpenCode](https://opencode.ai) | CLI | `npx superpowers-zh` | `.opencode/skills/` |
|
|
72
|
+
| [Qwen Code](https://tongyi.aliyun.com/lingma) (通义灵码) | IDE 插件 | `npx superpowers-zh` | `.qwen/skills/` |
|
|
73
|
+
| [Antigravity](https://github.com/anthropics/antigravity) | CLI | `npx superpowers-zh` | `.antigravity/skills/` |
|
|
26
74
|
|
|
27
|
-
|
|
75
|
+
> 运行 `npx superpowers-zh` 会自动检测你项目中使用的工具,将 20 个 skills 安装到正确位置。
|
|
28
76
|
|
|
29
77
|
### 翻译的 Skills(14 个)
|
|
30
78
|
|
|
@@ -45,7 +93,7 @@ Chinese community edition of [superpowers](https://github.com/obra/superpowers),
|
|
|
45
93
|
| **编写 Skills** (writing-skills) | 创建新 skill 的方法论 |
|
|
46
94
|
| **使用 Superpowers** (using-superpowers) | 元技能:如何调用和优先使用 skills |
|
|
47
95
|
|
|
48
|
-
### 🇨🇳 中国特色 Skills(
|
|
96
|
+
### 🇨🇳 中国特色 Skills(6 个)
|
|
49
97
|
|
|
50
98
|
| Skill | 用途 | 上游有吗? |
|
|
51
99
|
|-------|------|:---:|
|
|
@@ -54,6 +102,7 @@ Chinese community edition of [superpowers](https://github.com/obra/superpowers),
|
|
|
54
102
|
| **中文技术文档** (chinese-documentation) | 中文排版规范、中英混排、告别机翻味 | 无 |
|
|
55
103
|
| **中文提交规范** (chinese-commit-conventions) | 适配国内团队的 commit message 规范 | 无 |
|
|
56
104
|
| **MCP 服务器构建** (mcp-builder) | 构建生产级 MCP 工具,扩展 AI 能力边界 | 无 |
|
|
105
|
+
| **工作流执行器** (workflow-runner) | 在 AI 工具内运行多角色 YAML 工作流 | 无 |
|
|
57
106
|
|
|
58
107
|
---
|
|
59
108
|
|
|
@@ -77,8 +126,16 @@ cp -r superpowers-zh/skills /your/project/.claude/skills # Claude Code
|
|
|
77
126
|
cp -r superpowers-zh/skills /your/project/.cursor/skills # Cursor
|
|
78
127
|
cp -r superpowers-zh/skills /your/project/.codex/skills # Codex CLI
|
|
79
128
|
cp -r superpowers-zh/skills /your/project/.kiro/steering # Kiro
|
|
129
|
+
cp -r superpowers-zh/skills /your/project/skills/custom # DeerFlow 2.0
|
|
80
130
|
cp -r superpowers-zh/skills /your/project/.trae/rules # Trae
|
|
81
131
|
cp -r superpowers-zh/skills /your/project/.antigravity # Antigravity
|
|
132
|
+
cp -r superpowers-zh/skills /your/project/.github/superpowers # VS Code (Copilot)
|
|
133
|
+
cp -r superpowers-zh/skills /your/project/skills # OpenClaw
|
|
134
|
+
cp -r superpowers-zh/skills /your/project/.windsurf/skills # Windsurf
|
|
135
|
+
cp -r superpowers-zh/skills /your/project/.gemini/skills # Gemini CLI
|
|
136
|
+
cp -r superpowers-zh/skills /your/project/.aider/skills # Aider
|
|
137
|
+
cp -r superpowers-zh/skills /your/project/.opencode/skills # OpenCode
|
|
138
|
+
cp -r superpowers-zh/skills /your/project/.qwen/skills # Qwen Code
|
|
82
139
|
```
|
|
83
140
|
|
|
84
141
|
### 方式三:在配置文件中引用
|
|
@@ -89,12 +146,19 @@ cp -r superpowers-zh/skills /your/project/.antigravity # Antigravity
|
|
|
89
146
|
|------|---------|------|
|
|
90
147
|
| Claude Code | `CLAUDE.md` | 项目根目录 |
|
|
91
148
|
| Kiro | `.kiro/steering/*.md` | 支持 always/globs/手动三种模式 |
|
|
149
|
+
| DeerFlow 2.0 | `skills/custom/*/SKILL.md` | 字节跳动开源 SuperAgent,自动发现自定义 skills |
|
|
92
150
|
| Trae | `.trae/rules/project_rules.md` | 项目级规则 |
|
|
93
151
|
| Antigravity | `GEMINI.md` 或 `AGENTS.md` | 项目根目录 |
|
|
94
152
|
| VS Code | `.github/copilot-instructions.md` | Copilot 自定义指令 |
|
|
95
153
|
| Cursor | `.cursor/rules/*.md` | 项目级规则目录 |
|
|
154
|
+
| OpenClaw | `skills/*/SKILL.md` | 工作区级 skills 目录,自动发现 |
|
|
155
|
+
| Windsurf | `.windsurf/skills/*/SKILL.md` | 项目级 skills 目录 |
|
|
156
|
+
| Gemini CLI | `.gemini/skills/*/SKILL.md` | 项目级 skills 目录 |
|
|
157
|
+
| Aider | `.aider/skills/*/SKILL.md` | 项目级 skills 目录 |
|
|
158
|
+
| OpenCode | `.opencode/skills/*/SKILL.md` | 项目级 skills 目录 |
|
|
159
|
+
| Qwen Code | `.qwen/skills/*/SKILL.md` | 项目级 skills 目录 |
|
|
96
160
|
|
|
97
|
-
> **详细安装指南**:[Kiro](docs/README.kiro.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)
|
|
161
|
+
> **详细安装指南**:[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)
|
|
98
162
|
|
|
99
163
|
---
|
|
100
164
|
|
|
@@ -102,7 +166,7 @@ cp -r superpowers-zh/skills /your/project/.antigravity # Antigravity
|
|
|
102
166
|
|
|
103
167
|
| 特性 | superpowers (英文) | superpowers-zh (中文) |
|
|
104
168
|
|------|-------------------|----------------------|
|
|
105
|
-
| Skills 数量 | 14 | **
|
|
169
|
+
| Skills 数量 | 14 | **20**(14 翻译 + 6 原创) |
|
|
106
170
|
| 语言 | 英文 | 中文(技术术语保留英文) |
|
|
107
171
|
| 代码审查规范 | 西方直接风格 | 适配国内团队沟通文化 |
|
|
108
172
|
| Git 平台 | GitHub 为主 | GitHub + Gitee + Coding + 极狐 |
|
|
@@ -133,7 +197,7 @@ cp -r superpowers-zh/skills /your/project/.antigravity # Antigravity
|
|
|
133
197
|
|
|
134
198
|
| 群名 | 群号 | 加入方式 |
|
|
135
199
|
|------|------|---------|
|
|
136
|
-
| AI Agent 中文实践群 | **
|
|
200
|
+
| AI 编程 & Agent 中文实践群 | **1071280067** | [点击加入](https://qm.qq.com/q/EeNQA9xCxy) |
|
|
137
201
|
|
|
138
202
|
---
|
|
139
203
|
|
|
@@ -141,7 +205,11 @@ cp -r superpowers-zh/skills /your/project/.antigravity # Antigravity
|
|
|
141
205
|
|
|
142
206
|
- 原始英文版:[obra/superpowers](https://github.com/obra/superpowers)(MIT 协议)
|
|
143
207
|
- 感谢 [@obra](https://github.com/obra) 创建了这个优秀的项目
|
|
144
|
-
- 姊妹项目:
|
|
208
|
+
- 姊妹项目:
|
|
209
|
+
- [ai-coding-guide](https://github.com/jnMetaCode/ai-coding-guide) — AI 编程工具实战指南 — 66 个 Claude Code 技巧 + 9 款工具最佳实践 + 可复制配置模板
|
|
210
|
+
- [agency-agents-zh](https://github.com/jnMetaCode/agency-agents-zh) — 187 个专业角色,让 AI 变成安全工程师、DBA、产品经理等
|
|
211
|
+
- [agency-orchestrator](https://github.com/jnMetaCode/agency-orchestrator) — 多智能体编排引擎 — 用 YAML 编排 187 个角色协作,支持 DeepSeek/Claude/OpenAI/Ollama,零代码
|
|
212
|
+
- [shellward](https://github.com/jnMetaCode/shellward) — AI 智能体安全中间件 — 注入检测、数据防泄露、命令安全、零依赖、MCP Server
|
|
145
213
|
|
|
146
214
|
---
|
|
147
215
|
|
|
@@ -153,7 +221,7 @@ MIT License — 自由使用,商业或个人均可。
|
|
|
153
221
|
|
|
154
222
|
<div align="center">
|
|
155
223
|
|
|
156
|
-
|
|
224
|
+
**🦸 AI 编程超能力:让 OpenClaw / Claude Code / Cursor 等 14 款工具真正会干活**
|
|
157
225
|
|
|
158
226
|
[Star 本项目](https://github.com/jnMetaCode/superpowers-zh) · [提交 Issue](https://github.com/jnMetaCode/superpowers-zh/issues) · [贡献代码](https://github.com/jnMetaCode/superpowers-zh/pulls)
|
|
159
227
|
|
package/bin/superpowers-zh.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
-
import { existsSync, mkdirSync, cpSync, readdirSync, readFileSync } from 'fs';
|
|
3
|
+
import { existsSync, mkdirSync, cpSync, readdirSync, readFileSync, writeFileSync } from 'fs';
|
|
4
4
|
import { resolve, dirname } from 'path';
|
|
5
5
|
import { fileURLToPath } from 'url';
|
|
6
6
|
|
|
@@ -15,9 +15,16 @@ const TARGETS = [
|
|
|
15
15
|
{ name: 'Cursor', dir: '.cursor/skills', detect: '.cursor' },
|
|
16
16
|
{ name: 'Codex CLI', dir: '.codex/skills', detect: '.codex' },
|
|
17
17
|
{ name: 'Kiro', dir: '.kiro/steering', detect: '.kiro' },
|
|
18
|
-
{ name: '
|
|
18
|
+
{ name: 'DeerFlow', dir: 'skills/custom', detect: 'deer_flow' },
|
|
19
|
+
{ name: 'Trae', dir: '.trae/skills', detect: '.trae' },
|
|
19
20
|
{ name: 'Antigravity', dir: '.antigravity/skills', detect: '.antigravity' },
|
|
20
21
|
{ name: 'VS Code', dir: '.github/superpowers', detect: '.github/copilot-instructions.md' },
|
|
22
|
+
{ name: 'OpenClaw', dir: 'skills', detect: '.openclaw' },
|
|
23
|
+
{ name: 'Windsurf', dir: '.windsurf/skills', detect: '.windsurf' },
|
|
24
|
+
{ name: 'Gemini CLI', dir: '.gemini/skills', detect: 'GEMINI.md' },
|
|
25
|
+
{ name: 'Aider', dir: '.aider/skills', detect: '.aider' },
|
|
26
|
+
{ name: 'OpenCode', dir: '.opencode/skills', detect: '.opencode' },
|
|
27
|
+
{ name: 'Qwen Code', dir: '.qwen/skills', detect: '.qwen' },
|
|
21
28
|
];
|
|
22
29
|
|
|
23
30
|
function countDirs(dir) {
|
|
@@ -25,27 +32,97 @@ function countDirs(dir) {
|
|
|
25
32
|
return readdirSync(dir, { withFileTypes: true }).filter(e => e.isDirectory()).length;
|
|
26
33
|
}
|
|
27
34
|
|
|
35
|
+
function generateTraeBootstrapRule(projectDir) {
|
|
36
|
+
const rulesDir = resolve(projectDir, '.trae', 'rules');
|
|
37
|
+
mkdirSync(rulesDir, { recursive: true });
|
|
38
|
+
|
|
39
|
+
// 扫描已安装的 skills,读取 name 和 description
|
|
40
|
+
const skillsDir = resolve(projectDir, '.trae', 'skills');
|
|
41
|
+
const skillEntries = [];
|
|
42
|
+
if (existsSync(skillsDir)) {
|
|
43
|
+
for (const entry of readdirSync(skillsDir, { withFileTypes: true })) {
|
|
44
|
+
if (!entry.isDirectory()) continue;
|
|
45
|
+
const skillFile = resolve(skillsDir, entry.name, 'SKILL.md');
|
|
46
|
+
if (!existsSync(skillFile)) continue;
|
|
47
|
+
const content = readFileSync(skillFile, 'utf8');
|
|
48
|
+
const fmMatch = content.match(/^---\s*\n([\s\S]*?)\n---/);
|
|
49
|
+
if (!fmMatch) continue;
|
|
50
|
+
const nameMatch = fmMatch[1].match(/^name:\s*(.+)$/m);
|
|
51
|
+
const descMatch = fmMatch[1].match(/^description:\s*["']?(.+?)["']?\s*$/m);
|
|
52
|
+
if (nameMatch) {
|
|
53
|
+
skillEntries.push({
|
|
54
|
+
name: nameMatch[1].trim(),
|
|
55
|
+
desc: descMatch ? descMatch[1].trim() : '',
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
const skillTable = skillEntries.map(s => `| ${s.name} | ${s.desc} |`).join('\n');
|
|
62
|
+
|
|
63
|
+
const rule = `---
|
|
64
|
+
alwaysApply: true
|
|
65
|
+
---
|
|
66
|
+
|
|
67
|
+
# Superpowers-ZH 中文增强版
|
|
68
|
+
|
|
69
|
+
你已加载 superpowers-zh 技能框架(${skillEntries.length} 个 skills)。
|
|
70
|
+
|
|
71
|
+
## 核心规则
|
|
72
|
+
|
|
73
|
+
1. **收到任务时,先检查是否有匹配的 skill** — 哪怕只有 1% 的可能性也要检查
|
|
74
|
+
2. **设计先于编码** — 收到功能需求时,先用 brainstorming skill 做需求分析
|
|
75
|
+
3. **测试先于实现** — 写代码前先写测试(TDD)
|
|
76
|
+
4. **验证先于完成** — 声称完成前必须运行验证命令
|
|
77
|
+
|
|
78
|
+
## 可用 Skills
|
|
79
|
+
|
|
80
|
+
Skills 位于 \`.trae/skills/\` 目录,每个 skill 有独立的 \`SKILL.md\` 文件。
|
|
81
|
+
|
|
82
|
+
| Skill | 触发条件 |
|
|
83
|
+
|-------|---------|
|
|
84
|
+
${skillTable}
|
|
85
|
+
|
|
86
|
+
## 如何使用
|
|
87
|
+
|
|
88
|
+
当任务匹配某个 skill 的触发条件时,读取对应的 \`.trae/skills/<skill-name>/SKILL.md\` 并严格遵循其流程。
|
|
89
|
+
`;
|
|
90
|
+
|
|
91
|
+
const rulePath = resolve(rulesDir, 'superpowers-zh.md');
|
|
92
|
+
writeFileSync(rulePath, rule, 'utf8');
|
|
93
|
+
console.log(` ✅ Trae: bootstrap rule -> ${rulePath}`);
|
|
94
|
+
}
|
|
95
|
+
|
|
28
96
|
function showHelp() {
|
|
29
97
|
console.log(`
|
|
30
98
|
superpowers-zh v${PKG.version} — AI 编程超能力中文版
|
|
31
99
|
|
|
32
100
|
用法:
|
|
33
|
-
npx superpowers-zh 安装 skills
|
|
101
|
+
npx superpowers-zh 安装 skills(及 agents)到当前项目
|
|
34
102
|
npx superpowers-zh --help 显示帮助
|
|
35
103
|
npx superpowers-zh --version 显示版本
|
|
36
104
|
|
|
37
105
|
说明:
|
|
38
106
|
自动检测当前项目使用的 AI 编程工具:
|
|
39
|
-
Claude Code / Cursor / Codex / Kiro / Trae / Antigravity / VS Code
|
|
107
|
+
Claude Code / Cursor / Codex / Kiro / DeerFlow / Trae / Antigravity / VS Code / OpenClaw
|
|
108
|
+
Windsurf / Gemini CLI / Aider / OpenCode / Qwen Code
|
|
40
109
|
将 ${countDirs(SKILLS_SRC)} 个 skills 安装到对应目录。
|
|
41
|
-
|
|
110
|
+
Claude Code 还会额外安装 agents 到 .claude/agents/。
|
|
111
|
+
如果未检测到任何工具,默认安装到 .claude/skills/ 和 .claude/agents/。
|
|
42
112
|
|
|
43
113
|
项目:https://github.com/jnMetaCode/superpowers-zh
|
|
44
114
|
`);
|
|
45
115
|
}
|
|
46
116
|
|
|
47
117
|
function install() {
|
|
118
|
+
try {
|
|
48
119
|
console.log(`\n superpowers-zh v${PKG.version} — AI 编程超能力中文版\n`);
|
|
120
|
+
|
|
121
|
+
if (!existsSync(SKILLS_SRC)) {
|
|
122
|
+
console.error(' ❌ 错误:skills 源目录不存在,请重新安装 superpowers-zh。');
|
|
123
|
+
process.exit(1);
|
|
124
|
+
}
|
|
125
|
+
|
|
49
126
|
console.log(` 源: ${countDirs(SKILLS_SRC)} 个 skills`);
|
|
50
127
|
console.log(` 目标项目: ${PROJECT_DIR}\n`);
|
|
51
128
|
|
|
@@ -62,6 +139,10 @@ function install() {
|
|
|
62
139
|
console.log(` ✅ ${target.name}: ${count} 个 skills -> ${dest}`);
|
|
63
140
|
installed++;
|
|
64
141
|
|
|
142
|
+
if (target.name === 'Trae') {
|
|
143
|
+
generateTraeBootstrapRule(PROJECT_DIR);
|
|
144
|
+
}
|
|
145
|
+
|
|
65
146
|
if (target.name === 'Claude Code' && existsSync(AGENTS_SRC)) {
|
|
66
147
|
const agentsDest = resolve(PROJECT_DIR, '.claude', 'agents');
|
|
67
148
|
mkdirSync(agentsDest, { recursive: true });
|
|
@@ -75,9 +156,20 @@ function install() {
|
|
|
75
156
|
mkdirSync(dest, { recursive: true });
|
|
76
157
|
cpSync(SKILLS_SRC, dest, { recursive: true });
|
|
77
158
|
console.log(` ✅ 默认安装: ${countDirs(dest)} 个 skills -> ${dest}`);
|
|
159
|
+
|
|
160
|
+
if (existsSync(AGENTS_SRC)) {
|
|
161
|
+
const agentsDest = resolve(PROJECT_DIR, '.claude', 'agents');
|
|
162
|
+
mkdirSync(agentsDest, { recursive: true });
|
|
163
|
+
cpSync(AGENTS_SRC, agentsDest, { recursive: true });
|
|
164
|
+
console.log(` ✅ 默认安装: agents -> ${agentsDest}`);
|
|
165
|
+
}
|
|
78
166
|
}
|
|
79
167
|
|
|
80
168
|
console.log('\n 安装完成!重启你的 AI 编程工具即可生效。\n');
|
|
169
|
+
} catch (err) {
|
|
170
|
+
console.error(` ❌ 安装失败:${err.message}`);
|
|
171
|
+
process.exit(1);
|
|
172
|
+
}
|
|
81
173
|
}
|
|
82
174
|
|
|
83
175
|
const arg = process.argv[2];
|
|
@@ -85,6 +177,10 @@ if (arg === '--help' || arg === '-h') {
|
|
|
85
177
|
showHelp();
|
|
86
178
|
} else if (arg === '--version' || arg === '-v') {
|
|
87
179
|
console.log(PKG.version);
|
|
180
|
+
} else if (arg && arg.startsWith('-')) {
|
|
181
|
+
console.warn(` 未知参数: ${arg}\n`);
|
|
182
|
+
showHelp();
|
|
183
|
+
process.exit(1);
|
|
88
184
|
} else {
|
|
89
185
|
install();
|
|
90
186
|
}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# Superpowers 中文版 — Aider 安装指南
|
|
2
|
+
|
|
3
|
+
在 [Aider](https://aider.chat) 中使用 superpowers-zh 的完整指南。
|
|
4
|
+
|
|
5
|
+
## 自动安装
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
cd /your/project
|
|
9
|
+
npx superpowers-zh
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
安装脚本会自动检测 `.aider.conf.yml` 文件并将 skills 复制到 `.aider/skills/` 目录。
|
|
13
|
+
|
|
14
|
+
## 手动安装
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
git clone https://github.com/jnMetaCode/superpowers-zh.git
|
|
18
|
+
cp -r superpowers-zh/skills /your/project/.aider/skills
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## 通过 CONVENTIONS.md 引用
|
|
22
|
+
|
|
23
|
+
Aider 原生支持 `CONVENTIONS.md` 文件。在其中引用 skills:
|
|
24
|
+
|
|
25
|
+
```markdown
|
|
26
|
+
# 项目约定
|
|
27
|
+
|
|
28
|
+
## 工作方法论
|
|
29
|
+
|
|
30
|
+
本项目使用 superpowers-zh skills 作为工作方法论。
|
|
31
|
+
Skills 位于 `.aider/skills/` 目录,每个子目录的 SKILL.md 定义一个工作流。
|
|
32
|
+
|
|
33
|
+
- 新功能开发:先使用 brainstorming skill
|
|
34
|
+
- 编写代码:遵循 test-driven-development skill
|
|
35
|
+
- 调试问题:使用 systematic-debugging skill
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
## 通过 .aider.conf.yml 配置
|
|
39
|
+
|
|
40
|
+
在 `.aider.conf.yml` 中添加 read 配置来加载 skills:
|
|
41
|
+
|
|
42
|
+
```yaml
|
|
43
|
+
read:
|
|
44
|
+
- .aider/skills/brainstorming/SKILL.md
|
|
45
|
+
- .aider/skills/test-driven-development/SKILL.md
|
|
46
|
+
- .aider/skills/systematic-debugging/SKILL.md
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
## 故障排查
|
|
50
|
+
|
|
51
|
+
### Skills 未生效
|
|
52
|
+
|
|
53
|
+
1. 确认 `.aider/skills/` 目录存在且包含 skill 文件夹
|
|
54
|
+
2. 确保在 `CONVENTIONS.md` 或 `.aider.conf.yml` 中引用了 skills
|
|
55
|
+
3. Aider 会自动读取 `CONVENTIONS.md`,无需额外配置
|
|
56
|
+
|
|
57
|
+
## 获取帮助
|
|
58
|
+
|
|
59
|
+
- 提交 Issue:https://github.com/jnMetaCode/superpowers-zh/issues
|
|
60
|
+
- 项目主页:https://github.com/jnMetaCode/superpowers-zh
|
|
61
|
+
- Aider 文档:https://aider.chat/docs/
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# Superpowers 中文版 — Antigravity 安装指南
|
|
2
|
+
|
|
3
|
+
在 [Google Antigravity](https://antigravity.google)(Google AI IDE)中使用 superpowers-zh 的完整指南。
|
|
4
|
+
|
|
5
|
+
## 快速安装
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
cd /your/project
|
|
9
|
+
npx superpowers-zh
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
安装脚本会自动检测 `.antigravity/` 目录并将 skills 复制到该目录。
|
|
13
|
+
|
|
14
|
+
## 手动安装
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
git clone https://github.com/jnMetaCode/superpowers-zh.git
|
|
18
|
+
mkdir -p /your/project/.antigravity/skills
|
|
19
|
+
cp -r superpowers-zh/skills/* /your/project/.antigravity/skills/
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
## 工作原理
|
|
23
|
+
|
|
24
|
+
Antigravity 支持多种规则文件格式:
|
|
25
|
+
|
|
26
|
+
| 文件 | 优先级 | 说明 |
|
|
27
|
+
|------|--------|------|
|
|
28
|
+
| `GEMINI.md` | 最高 | Antigravity 专属规则 |
|
|
29
|
+
| `AGENTS.md` | 中 | 通用规则(Antigravity、Cursor、Claude Code 共享) |
|
|
30
|
+
| `.antigravity/rules.md` | 中 | 项目级规则目录 |
|
|
31
|
+
| `CLAUDE.md` | 低 | 也会被自动读取 |
|
|
32
|
+
|
|
33
|
+
### 推荐配置方式
|
|
34
|
+
|
|
35
|
+
**方式一**:在项目根目录创建 `GEMINI.md`:
|
|
36
|
+
|
|
37
|
+
```markdown
|
|
38
|
+
# GEMINI.md
|
|
39
|
+
|
|
40
|
+
使用 .antigravity/ 目录下的 superpowers skills 来指导工作流程。
|
|
41
|
+
优先使用 brainstorming(头脑风暴)开始新任务。
|
|
42
|
+
|
|
43
|
+
Skills 列表参见 .antigravity/ 目录。
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
**方式二**:在 `AGENTS.md` 中引用(多工具共享):
|
|
47
|
+
|
|
48
|
+
```markdown
|
|
49
|
+
# AGENTS.md
|
|
50
|
+
|
|
51
|
+
本项目使用 superpowers-zh skills 框架。
|
|
52
|
+
Skills 位于 .antigravity/(Antigravity)或 .claude/skills/(Claude Code)目录下。
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
### 工具映射
|
|
56
|
+
|
|
57
|
+
Antigravity 使用 Gemini 模型,工具名称与 Claude Code 不同:
|
|
58
|
+
|
|
59
|
+
| Claude Code | Antigravity (Gemini) |
|
|
60
|
+
|-------------|---------------------|
|
|
61
|
+
| `Read` | `read_file` |
|
|
62
|
+
| `Write` | `write_file` |
|
|
63
|
+
| `Edit` | `replace` |
|
|
64
|
+
| `Bash` | `run_shell_command` |
|
|
65
|
+
| `Skill` | `activate_skill` |
|
|
66
|
+
|
|
67
|
+
Skills 中的 Claude Code 工具名称会被 Antigravity 自动适配。
|
|
68
|
+
|
|
69
|
+
## 使用
|
|
70
|
+
|
|
71
|
+
Antigravity 支持 Agent Manager 并行执行多个 agent:
|
|
72
|
+
- 与 superpowers-zh 的「派遣并行 Agent」skill 理念一致
|
|
73
|
+
- 可以同时调度多个 skill 处理不同任务
|
|
74
|
+
|
|
75
|
+
## 全局规则
|
|
76
|
+
|
|
77
|
+
个人级别的全局规则放在:
|
|
78
|
+
```
|
|
79
|
+
~/.gemini/GEMINI.md
|
|
80
|
+
~/.gemini/AGENTS.md
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## 更新
|
|
84
|
+
|
|
85
|
+
```bash
|
|
86
|
+
cd /your/project
|
|
87
|
+
npx superpowers-zh
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
## 获取帮助
|
|
91
|
+
|
|
92
|
+
- 提交 Issue:https://github.com/jnMetaCode/superpowers-zh/issues
|
|
93
|
+
- Antigravity 文档:https://antigravity.google/docs/rules-workflows
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
# Superpowers 中文版 — Codex CLI 安装指南
|
|
2
|
+
|
|
3
|
+
在 Codex 中使用 superpowers-zh 的完整指南。
|
|
4
|
+
|
|
5
|
+
## 快速安装
|
|
6
|
+
|
|
7
|
+
告诉 Codex:
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
Fetch and follow instructions from https://raw.githubusercontent.com/jnMetaCode/superpowers-zh/refs/heads/main/.codex/INSTALL.md
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## 手动安装
|
|
14
|
+
|
|
15
|
+
### 前置条件
|
|
16
|
+
|
|
17
|
+
- OpenAI Codex CLI
|
|
18
|
+
- Git
|
|
19
|
+
|
|
20
|
+
### 步骤
|
|
21
|
+
|
|
22
|
+
1. 克隆仓库:
|
|
23
|
+
```bash
|
|
24
|
+
git clone https://github.com/jnMetaCode/superpowers-zh.git ~/.codex/superpowers-zh
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
2. 创建 skills 符号链接:
|
|
28
|
+
```bash
|
|
29
|
+
mkdir -p ~/.agents/skills
|
|
30
|
+
ln -s ~/.codex/superpowers-zh/skills ~/.agents/skills/superpowers
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
3. 重启 Codex。
|
|
34
|
+
|
|
35
|
+
4. **子代理 skills(可选):** `dispatching-parallel-agents` 和 `subagent-driven-development` 需要 Codex 的多代理功能。在 Codex 配置中添加:
|
|
36
|
+
```toml
|
|
37
|
+
[features]
|
|
38
|
+
multi_agent = true
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### Windows
|
|
42
|
+
|
|
43
|
+
使用 junction 代替符号链接(无需开发者模式):
|
|
44
|
+
|
|
45
|
+
```powershell
|
|
46
|
+
New-Item -ItemType Directory -Force -Path "$env:USERPROFILE\.agents\skills"
|
|
47
|
+
cmd /c mklink /J "$env:USERPROFILE\.agents\skills\superpowers" "$env:USERPROFILE\.codex\superpowers-zh\skills"
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## 工作原理
|
|
51
|
+
|
|
52
|
+
Codex 原生支持 skill 发现——启动时扫描 `~/.agents/skills/` 目录,解析 SKILL.md 的 frontmatter,按需加载 skills。通过一个符号链接即可注册所有 skills:
|
|
53
|
+
|
|
54
|
+
```
|
|
55
|
+
~/.agents/skills/superpowers/ → ~/.codex/superpowers-zh/skills/
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
`using-superpowers` skill 会自动被发现并强制执行 skill 使用纪律——无需额外配置。
|
|
59
|
+
|
|
60
|
+
## 使用
|
|
61
|
+
|
|
62
|
+
Skills 自动发现。Codex 在以下情况激活 skills:
|
|
63
|
+
- 你提到 skill 名称(如 "use brainstorming")
|
|
64
|
+
- 任务匹配 skill 的描述
|
|
65
|
+
- `using-superpowers` skill 指示 Codex 使用某个 skill
|
|
66
|
+
|
|
67
|
+
## 更新
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
cd ~/.codex/superpowers-zh && git pull
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
Skills 通过符号链接即时更新。
|
|
74
|
+
|
|
75
|
+
## 卸载
|
|
76
|
+
|
|
77
|
+
```bash
|
|
78
|
+
rm ~/.agents/skills/superpowers
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
**Windows (PowerShell):**
|
|
82
|
+
```powershell
|
|
83
|
+
Remove-Item "$env:USERPROFILE\.agents\skills\superpowers"
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
可选:删除克隆的仓库 `rm -rf ~/.codex/superpowers-zh`
|
|
87
|
+
|
|
88
|
+
## 获取帮助
|
|
89
|
+
|
|
90
|
+
- 提交 Issue:https://github.com/jnMetaCode/superpowers-zh/issues
|
|
91
|
+
- 项目主页:https://github.com/jnMetaCode/superpowers-zh
|