gm-cc 2.0.618 → 2.0.620
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 +1 -1
- package/bin/plugkit-darwin-arm64 +0 -0
- package/bin/plugkit-darwin-x64 +0 -0
- package/bin/plugkit-linux-arm64 +0 -0
- package/bin/plugkit-linux-x64 +0 -0
- package/bin/plugkit-win32-arm64.exe +0 -0
- package/bin/plugkit-win32-x64.exe +0 -0
- package/bin/plugkit.exe +0 -0
- package/hooks/pre-tool-use-hook.js +9 -4
- package/package.json +1 -1
- package/plugin.json +1 -1
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"name": "AnEntrypoint"
|
|
5
5
|
},
|
|
6
6
|
"description": "State machine agent with hooks, skills, and automated git enforcement",
|
|
7
|
-
"version": "2.0.
|
|
7
|
+
"version": "2.0.620",
|
|
8
8
|
"metadata": {
|
|
9
9
|
"description": "State machine agent with hooks, skills, and automated git enforcement"
|
|
10
10
|
},
|
package/bin/plugkit-darwin-arm64
CHANGED
|
Binary file
|
package/bin/plugkit-darwin-x64
CHANGED
|
Binary file
|
package/bin/plugkit-linux-arm64
CHANGED
|
Binary file
|
package/bin/plugkit-linux-x64
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/bin/plugkit.exe
CHANGED
|
Binary file
|
|
@@ -1,17 +1,22 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
const fs = require('fs');
|
|
3
3
|
const path = require('path');
|
|
4
|
-
|
|
4
|
+
let raw = '';
|
|
5
|
+
try { raw = fs.readFileSync(0, 'utf8'); } catch (_) {}
|
|
6
|
+
if (!raw.trim()) raw = process.env.CLAUDE_HOOK_INPUT || '{}';
|
|
7
|
+
const input = JSON.parse(raw);
|
|
5
8
|
const toolName = input.tool_name || input.tool_use?.name || '';
|
|
6
9
|
const toolInput = input.tool_input || input.tool_use?.input || {};
|
|
10
|
+
const skillName = toolInput.skill || toolInput.name || '';
|
|
7
11
|
const gmDir = path.join(process.cwd(), '.gm');
|
|
8
12
|
const needsGmPath = path.join(gmDir, 'needs-gm');
|
|
9
13
|
const lastskillPath = path.join(gmDir, 'lastskill');
|
|
10
|
-
|
|
14
|
+
const isSkillTool = toolName === 'Skill' || toolName === 'skill';
|
|
15
|
+
if (isSkillTool && skillName) {
|
|
11
16
|
try {
|
|
12
17
|
if (!fs.existsSync(gmDir)) fs.mkdirSync(gmDir, { recursive: true });
|
|
13
|
-
fs.writeFileSync(lastskillPath,
|
|
14
|
-
if (
|
|
18
|
+
fs.writeFileSync(lastskillPath, skillName, 'utf8');
|
|
19
|
+
if (skillName === 'gm' || skillName === 'gm:gm') {
|
|
15
20
|
try { fs.unlinkSync(needsGmPath); } catch (_) {}
|
|
16
21
|
}
|
|
17
22
|
} catch (_) {}
|
package/package.json
CHANGED