adspecs 0.1.39 → 0.1.40

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.
@@ -10,7 +10,7 @@
10
10
  {
11
11
  "name": "adspecs",
12
12
  "description": "AI Coding研发协同开发插件",
13
- "version": "0.1.39",
13
+ "version": "0.1.40",
14
14
  "source": "./",
15
15
  "author": {
16
16
  "name": "Qingwen Chen",
@@ -2,7 +2,7 @@
2
2
  "name": "adspecs",
3
3
  "displayName": "adspecs AI Plugin",
4
4
  "description": "AI first工程规范驱动开发插件",
5
- "version": "0.1.39",
5
+ "version": "0.1.40",
6
6
  "author": {
7
7
  "name": "Qingwen Chen",
8
8
  "email": "cqinwn@qq.com",
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "adspecs",
3
3
  "displayName": "adspecs AI 工程规范驱动开发插件",
4
- "version": "0.1.39",
4
+ "version": "0.1.40",
5
5
  "description": "AI-first specification-driven development plugin for ECP platform full-lifecycle development",
6
6
  "descriptionZh": "AI优先的工程规范驱动开发插件,覆盖需求分析、PRD、系统设计、任务拆解、TDD、代码评审、Wiki同步全流程",
7
7
  "author": {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "adspecs",
3
3
  "displayName": "adspecs AI 工程规范驱动开发插件",
4
- "version": "0.1.39",
4
+ "version": "0.1.40",
5
5
  "description": "AI-first specification-driven development plugin for ECP platform full-lifecycle development",
6
6
  "descriptionZh": "AI优先的工程规范驱动开发插件,覆盖需求分析、PRD、系统设计、任务拆解、TDD、代码评审、Wiki同步全流程",
7
7
  "author": {
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "adspecs",
3
3
  "displayName": "adspecs AI 工程规范驱动开发插件",
4
- "version": "0.1.39",
4
+ "version": "0.1.40",
5
5
  "description": "AI-first specification-driven development plugin for ECP platform full-lifecycle development",
6
6
  "descriptionZh": "AI优先的工程规范驱动开发插件,覆盖需求分析、PRD、系统设计、任务拆解、TDD、代码评审、Wiki同步全流程",
7
7
  "author": {
@@ -212,10 +212,8 @@ function checkAndReport() {
212
212
  });
213
213
 
214
214
  console.log('');
215
- console.log('[commit-queue] To commit with worktree isolation:');
216
- console.log('[commit-queue] /ai-softengineer:git-worktree-manager');
217
- console.log('[commit-queue] To commit directly (no worktree):');
218
- console.log('[commit-queue] /ai-softengineer:git-commit');
215
+ console.log('[commit-queue] 提交已编译通过的功能:');
216
+ console.log('[commit-queue] /adspecs-git-commit');
219
217
  console.log('══════════════════════════════════════════════════════');
220
218
  console.log('');
221
219
  }
package/hooks/hooks.json CHANGED
@@ -1,24 +1,24 @@
1
1
  {
2
- "_comment": "跨平台 Hook 配置 — 同时支持 Claude Code、Qoder 和 WorkBuddy。${CLAUDE_PLUGIN_ROOT} 由平台在加载插件时注入(所有平台兼容此变量或设置 ADSPECS_PLATFORM=claude|qoder|workbuddy)。",
2
+ "_comment": "跨平台 Hook 配置 — 同时支持 Claude Code、Qoder 和 WorkBuddy。所有脚本命令使用项目根目录相对路径(hooks/xxx.js),由 /project-init 将插件 hooks/ 复制到目标项目根。平台运行时 CWD 即为目标项目根目录。",
3
3
  "hooks": {
4
4
  "SessionStart": [
5
5
  {
6
6
  "hooks": [
7
7
  {
8
8
  "type": "command",
9
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/session-start.js"
9
+ "command": "node hooks/session-start.js"
10
10
  },
11
11
  {
12
12
  "type": "command",
13
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/wiki-queue.js init"
13
+ "command": "node hooks/wiki-queue.js init"
14
14
  },
15
15
  {
16
16
  "type": "command",
17
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/commit-queue.js init"
17
+ "command": "node hooks/commit-queue.js init"
18
18
  },
19
19
  {
20
20
  "type": "command",
21
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/session-logger.js init"
21
+ "command": "node hooks/session-logger.js init"
22
22
  }
23
23
  ]
24
24
  }
@@ -28,7 +28,7 @@
28
28
  "hooks": [
29
29
  {
30
30
  "type": "command",
31
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/session-logger.js mark"
31
+ "command": "node hooks/session-logger.js mark"
32
32
  }
33
33
  ]
34
34
  }
@@ -40,7 +40,7 @@
40
40
  "hooks": [
41
41
  {
42
42
  "type": "command",
43
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/wiki-queue.js enqueue"
43
+ "command": "node hooks/wiki-queue.js enqueue"
44
44
  }
45
45
  ],
46
46
  "conditions": {
@@ -52,7 +52,7 @@
52
52
  "hooks": [
53
53
  {
54
54
  "type": "command",
55
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/commit-queue.js enqueue"
55
+ "command": "node hooks/commit-queue.js enqueue"
56
56
  }
57
57
  ],
58
58
  "conditions": {
@@ -65,15 +65,15 @@
65
65
  "hooks": [
66
66
  {
67
67
  "type": "command",
68
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/wiki-queue.js report"
68
+ "command": "node hooks/wiki-queue.js report"
69
69
  },
70
70
  {
71
71
  "type": "command",
72
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/commit-queue.js report"
72
+ "command": "node hooks/commit-queue.js report"
73
73
  },
74
74
  {
75
75
  "type": "command",
76
- "command": "node ${CLAUDE_PLUGIN_ROOT}/hooks/session-logger.js report"
76
+ "command": "node hooks/session-logger.js report"
77
77
  }
78
78
  ]
79
79
  }
@@ -1,40 +1,17 @@
1
1
  #!/usr/bin/env node
2
2
 
3
3
  /**
4
- * SessionStart Hook — 注入 using-adspecs 技能引导内容
4
+ * SessionStart Hook — 会话启动占位脚本
5
5
  *
6
- * 在每次会话启动时,读取 using-adspecs/SKILL.md 并输出为
7
- * hook additionalContext,确保 Agent 在任何任务开始前
8
- * 都知道需要检查并使用 ADSpecs 技能。
6
+ * 原设计:注入 using-adspecs/SKILL.md 引导内容。
7
+ * 当前状态:using-adspecs skill 不存在,会话引导已由 session-logger.js init 承担
8
+ * (注入 AI 会话日志保存指南)。
9
9
  *
10
- * 跨平台兼容:Claude Code / Qoder
10
+ * 保留此脚本文件是为了 hooks.json SessionStart 事件的结构完整性,
11
+ * 后续若需要新增会话启动时的上下文注入可在此扩展。
12
+ *
13
+ * 跨平台兼容:Claude Code / Qoder / WorkBuddy
11
14
  */
12
15
 
13
- const fs = require('fs');
14
- const path = require('path');
15
- const platform = require('./platform');
16
-
17
- // ── 路径解析 ──────────────────────────────────────────
18
- // 使用平台工具解析插件根目录(兼容环境变量和 __dirname 回退)
19
- const PLUGIN_ROOT = platform.getPluginRoot(__dirname);
20
- const SKILL_PATH = path.join(PLUGIN_ROOT, 'skills', 'using-adspecs', 'SKILL.md');
21
-
22
- // ── 读取技能内容 ──────────────────────────────────────
23
- var skillContent;
24
- try {
25
- skillContent = fs.readFileSync(SKILL_PATH, 'utf8');
26
- } catch (err) {
27
- // 技能文件不存在,静默跳过
28
- process.exit(0);
29
- }
30
-
31
- if (!skillContent || skillContent.trim() === '') {
32
- process.exit(0);
33
- }
34
-
35
- // ── 输出 Hook Context ─────────────────────────────────
36
- // 使用平台统一输出协议(hookSpecificOutput.additionalContext)
37
- platform.outputContext(
38
- 'SessionStart',
39
- '<EXTREMELY-IMPORTANT>\n' + skillContent + '\n</EXTREMELY-IMPORTANT>'
40
- );
16
+ // 直接退出,不输出任何内容
17
+ process.exit(0);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "adspecs",
3
- "version": "0.1.39",
3
+ "version": "0.1.40",
4
4
  "description": "AI first 工程规范驱动开发插件 — 支持 npm 安装和 CLI 初始化",
5
5
  "bin": {
6
6
  "adspecs": "bin/adspecs.js"
@@ -1128,7 +1128,7 @@ echo "更新了 ${#REPLACE_FILES[@]} 个模板文件,保留了 ${#KEEP_FILES[@
1128
1128
  hooks/
1129
1129
  ├── hooks.json # 跨平台 Hook 配置(SessionStart/PreCompact/PostToolUse/Stop)
1130
1130
  ├── platform.js # 平台检测工具模块(Claude Code / Qoder / WorkBuddy 兼容)
1131
- ├── session-start.js # SessionStart — 注入 using-adspecs 技能引导
1131
+ ├── session-start.js # SessionStart — 会话启动占位(会话引导由 session-logger.js init 承担)
1132
1132
  ├── wiki-queue.js # PostToolUse/Stop — wiki 同步队列管理
1133
1133
  ├── commit-queue.js # PostToolUse/Stop — commit 候选队列管理
1134
1134
  └── session-logger.js # SessionStart/PreCompact/Stop — AI 会话日志管理
@@ -1151,9 +1151,9 @@ find "$TARGET/hooks" -type f | wc -l
1151
1151
  ```
1152
1152
 
1153
1153
  **注意**:
1154
- - hooks.json 中的 `${CLAUDE_PLUGIN_ROOT}` 由平台在加载插件时注入,指向插件根目录或项目目录
1155
- - 复制 hooks/ 到项目目录确保脚本在任何平台环境下都能正确解析
1156
- - 不要修改 hooks.json 内容,保持 `${CLAUDE_PLUGIN_ROOT}` 变量引用不变
1154
+ - hooks.json 中的脚本命令使用项目根目录相对路径(`hooks/xxx.js`),运行时由平台 CWD 解析到目标项目的 `hooks/` 目录
1155
+ - 复制 hooks/ 到目标项目根目录是脚本可执行的前提,不可省略
1156
+ - 不要修改 hooks.json 内容,保持 `hooks/xxx.js` 路径格式不变
1157
1157
 
1158
1158
  完成后输出:
1159
1159