clikit-plugin 0.2.35 → 0.2.37
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/README.md +13 -14
- package/command/init.md +70 -152
- package/command/issue.md +1 -1
- package/command/plan.md +9 -4
- package/command/research.md +5 -5
- package/command/ship.md +51 -59
- package/command/verify.md +74 -50
- package/dist/.tsbuildinfo +1 -1
- package/dist/agents/index.d.ts.map +1 -1
- package/dist/cli.d.ts +1 -1
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +45 -107
- package/dist/cli.test.d.ts +2 -0
- package/dist/cli.test.d.ts.map +1 -0
- package/dist/clikit.schema.json +154 -136
- package/dist/commands/index.d.ts.map +1 -1
- package/dist/config.d.ts +13 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/config.test.d.ts +2 -0
- package/dist/config.test.d.ts.map +1 -0
- package/dist/hooks/error-logger.d.ts +10 -0
- package/dist/hooks/error-logger.d.ts.map +1 -0
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/index.d.ts.map +1 -1
- package/dist/hooks/memory-digest.d.ts +2 -0
- package/dist/hooks/memory-digest.d.ts.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +770 -154
- package/dist/skills/index.d.ts +10 -0
- package/dist/skills/index.d.ts.map +1 -1
- package/dist/tools/cass-memory.d.ts +61 -0
- package/dist/tools/cass-memory.d.ts.map +1 -0
- package/dist/tools/index.d.ts +1 -0
- package/dist/tools/index.d.ts.map +1 -1
- package/package.json +2 -2
- package/skill/cass-village/SKILL.md +217 -0
- package/src/agents/AGENTS.md +2 -1
- package/src/agents/build.md +17 -16
- package/src/agents/index.ts +33 -4
- package/src/agents/oracle.md +49 -68
- package/src/agents/plan.md +14 -15
- package/src/agents/research.md +76 -0
- package/src/agents/review.md +1 -1
- package/src/agents/vision.md +1 -1
- package/dist/hooks/git-guard.test.d.ts +0 -2
- package/dist/hooks/git-guard.test.d.ts.map +0 -1
- package/dist/hooks/security-check.test.d.ts +0 -2
- package/dist/hooks/security-check.test.d.ts.map +0 -1
- package/src/agents/general.md +0 -92
- package/src/agents/librarian.md +0 -116
- package/src/agents/looker.md +0 -112
- package/src/agents/scout.md +0 -84
- /package/command/{status.md → status-beads.md} +0 -0
package/dist/cli.js
CHANGED
|
@@ -45,7 +45,7 @@ function getPackageVersion() {
|
|
|
45
45
|
}
|
|
46
46
|
}
|
|
47
47
|
function getPluginEntry() {
|
|
48
|
-
return `${PLUGIN_NAME}
|
|
48
|
+
return `${PLUGIN_NAME}@latest`;
|
|
49
49
|
}
|
|
50
50
|
function resolveProjectDir(env = process.env, cwd = process.cwd()) {
|
|
51
51
|
const candidates = [env.INIT_CWD, env.PWD, cwd].filter((value) => typeof value === "string" && value.trim().length > 0);
|
|
@@ -59,9 +59,10 @@ function resolveProjectDir(env = process.env, cwd = process.cwd()) {
|
|
|
59
59
|
}
|
|
60
60
|
return cwd;
|
|
61
61
|
}
|
|
62
|
-
function upsertPluginEntry(existingPlugins,
|
|
62
|
+
function upsertPluginEntry(existingPlugins, pluginEntry) {
|
|
63
|
+
const pluginName = pluginEntry.split("@")[0] || pluginEntry;
|
|
63
64
|
const filteredPlugins = existingPlugins.filter((p) => p !== pluginName && !p.startsWith(`${pluginName}@`));
|
|
64
|
-
filteredPlugins.push(
|
|
65
|
+
filteredPlugins.push(pluginEntry);
|
|
65
66
|
return filteredPlugins;
|
|
66
67
|
}
|
|
67
68
|
function copyFileIfMissing(sourcePath, targetPath, stats) {
|
|
@@ -125,6 +126,8 @@ export default CliKitPlugin;
|
|
|
125
126
|
function removeLegacyGlobalPluginAssets(configDir) {
|
|
126
127
|
const legacyPluginPath = path.join(configDir, "plugins", "clikit.js");
|
|
127
128
|
const legacyAgentsDir = path.join(configDir, "plugins", "agents");
|
|
129
|
+
const legacyCommandDir = path.join(configDir, "command");
|
|
130
|
+
const legacyStatusPath = path.join(legacyCommandDir, "status.md");
|
|
128
131
|
if (fs.existsSync(legacyPluginPath)) {
|
|
129
132
|
fs.rmSync(legacyPluginPath, { force: true });
|
|
130
133
|
console.log(`\u2713 Removed legacy local plugin file: ${legacyPluginPath}`);
|
|
@@ -133,6 +136,10 @@ function removeLegacyGlobalPluginAssets(configDir) {
|
|
|
133
136
|
fs.rmSync(legacyAgentsDir, { recursive: true, force: true });
|
|
134
137
|
console.log(`\u2713 Removed legacy local agents directory: ${legacyAgentsDir}`);
|
|
135
138
|
}
|
|
139
|
+
if (fs.existsSync(legacyStatusPath)) {
|
|
140
|
+
fs.rmSync(legacyStatusPath, { force: true });
|
|
141
|
+
console.log(`\u2713 Removed legacy command file: ${legacyStatusPath}`);
|
|
142
|
+
}
|
|
136
143
|
}
|
|
137
144
|
function getRealHome() {
|
|
138
145
|
if (process.env.SNAP_REAL_HOME) {
|
|
@@ -210,20 +217,10 @@ function writeConfig(configPath, config) {
|
|
|
210
217
|
fs.renameSync(tmpPath, configPath);
|
|
211
218
|
}
|
|
212
219
|
async function install(options) {
|
|
213
|
-
|
|
214
|
-
CliKit Installer
|
|
215
|
-
================
|
|
216
|
-
`);
|
|
217
|
-
const pluginVersion = getPackageVersion();
|
|
218
|
-
console.log("[1/6] Adding CliKit plugin to OpenCode config...");
|
|
220
|
+
const pluginEntry = getPluginEntry();
|
|
219
221
|
try {
|
|
220
222
|
ensureConfigDir();
|
|
221
|
-
|
|
222
|
-
console.error(`\u2717 Failed to create config directory: ${err}`);
|
|
223
|
-
return 1;
|
|
224
|
-
}
|
|
225
|
-
const configPath = getConfigPath();
|
|
226
|
-
try {
|
|
223
|
+
const configPath = getConfigPath();
|
|
227
224
|
const result = parseConfig(configPath);
|
|
228
225
|
if (result.parseError && result.raw.trim()) {
|
|
229
226
|
console.error(`\u2717 Config file has syntax errors and cannot be safely modified.`);
|
|
@@ -233,106 +230,47 @@ async function install(options) {
|
|
|
233
230
|
}
|
|
234
231
|
const config = result.config;
|
|
235
232
|
const existingPlugins = Array.isArray(config.plugin) ? config.plugin.filter((p) => typeof p === "string") : [];
|
|
236
|
-
const
|
|
237
|
-
if (preservedKeys.length > 0) {
|
|
238
|
-
console.log(` Preserving existing config: ${preservedKeys.join(", ")}`);
|
|
239
|
-
}
|
|
240
|
-
const filteredPlugins = upsertPluginEntry(existingPlugins, PLUGIN_NAME, pluginVersion);
|
|
233
|
+
const filteredPlugins = upsertPluginEntry(existingPlugins, pluginEntry);
|
|
241
234
|
const pluginMergedConfig = { ...config, plugin: filteredPlugins };
|
|
242
235
|
writeConfig(configPath, pluginMergedConfig);
|
|
243
|
-
|
|
244
|
-
console.log("\u2713 MCP servers are provided by plugin runtime (not written to opencode config)");
|
|
245
|
-
} catch (err) {
|
|
246
|
-
console.error(`\u2717 Failed to update OpenCode config: ${err}`);
|
|
247
|
-
return 1;
|
|
248
|
-
}
|
|
249
|
-
if (options.includeProjectScaffold) {
|
|
250
|
-
console.log(`
|
|
251
|
-
[2/6] Scaffolding project .opencode assets...`);
|
|
252
|
-
try {
|
|
236
|
+
if (options.includeProjectScaffold) {
|
|
253
237
|
const projectDir = resolveProjectDir();
|
|
254
|
-
|
|
255
|
-
console.log(`\u2713 Project assets ready in ${path.join(projectDir, ".opencode")}`);
|
|
256
|
-
console.log(` Copied: ${stats.copied}, Skipped existing: ${stats.skipped}`);
|
|
257
|
-
if (stats.missingSources.length > 0) {
|
|
258
|
-
console.log(" Missing bundled sources (skipped):");
|
|
259
|
-
for (const missing of stats.missingSources) {
|
|
260
|
-
console.log(` - ${missing}`);
|
|
261
|
-
}
|
|
262
|
-
}
|
|
263
|
-
} catch (err) {
|
|
264
|
-
console.error(`\u2717 Failed to scaffold project assets: ${err}`);
|
|
265
|
-
return 1;
|
|
238
|
+
scaffoldProjectOpencode(projectDir);
|
|
266
239
|
}
|
|
267
|
-
} else {
|
|
268
|
-
console.log(`
|
|
269
|
-
[2/6] Skipping project scaffold (global-only install)`);
|
|
270
|
-
}
|
|
271
|
-
console.log(`
|
|
272
|
-
[3/6] Cleaning legacy local plugin assets...`);
|
|
273
|
-
try {
|
|
274
240
|
removeLegacyGlobalPluginAssets(getConfigDir());
|
|
275
|
-
|
|
241
|
+
const memoryDir = path.join(getConfigDir(), "memory");
|
|
242
|
+
const memorySubdirs = ["specs", "plans", "research", "reviews", "handoffs", "beads", "prds"];
|
|
243
|
+
for (const subdir of memorySubdirs) {
|
|
244
|
+
const dir = path.join(memoryDir, subdir);
|
|
245
|
+
if (!fs.existsSync(dir)) {
|
|
246
|
+
fs.mkdirSync(dir, { recursive: true });
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
const clikitConfigPath = getCliKitConfigPath();
|
|
250
|
+
if (!fs.existsSync(clikitConfigPath)) {
|
|
251
|
+
const defaultConfig = {
|
|
252
|
+
$schema: `https://unpkg.com/${PLUGIN_NAME}@latest/schema.json`,
|
|
253
|
+
disabled_agents: [],
|
|
254
|
+
disabled_commands: [],
|
|
255
|
+
disabled_skills: [],
|
|
256
|
+
agents: {},
|
|
257
|
+
commands: {},
|
|
258
|
+
skills: {
|
|
259
|
+
enable: [],
|
|
260
|
+
disable: []
|
|
261
|
+
},
|
|
262
|
+
hooks: {}
|
|
263
|
+
};
|
|
264
|
+
writeConfig(clikitConfigPath, defaultConfig);
|
|
265
|
+
}
|
|
266
|
+
console.log(`\u2713 CliKit installed (${pluginEntry})`);
|
|
267
|
+
console.log(`\u2713 Config: ${configPath}`);
|
|
268
|
+
console.log("\u2713 Restart OpenCode");
|
|
269
|
+
return 0;
|
|
276
270
|
} catch (err) {
|
|
277
|
-
console.error(`\u2717
|
|
271
|
+
console.error(`\u2717 Install failed: ${err}`);
|
|
278
272
|
return 1;
|
|
279
273
|
}
|
|
280
|
-
console.log(`
|
|
281
|
-
[4/6] Creating memory directories...`);
|
|
282
|
-
const memoryDir = path.join(getConfigDir(), "memory");
|
|
283
|
-
const memorySubdirs = ["specs", "plans", "research", "reviews", "handoffs", "beads", "prds"];
|
|
284
|
-
for (const subdir of memorySubdirs) {
|
|
285
|
-
const dir = path.join(memoryDir, subdir);
|
|
286
|
-
if (!fs.existsSync(dir)) {
|
|
287
|
-
fs.mkdirSync(dir, { recursive: true });
|
|
288
|
-
}
|
|
289
|
-
}
|
|
290
|
-
console.log(`\u2713 Memory directories created in ${memoryDir}`);
|
|
291
|
-
console.log(`
|
|
292
|
-
[5/6] Verifying MCP environment hints...`);
|
|
293
|
-
if (!process.env.CONTEXT7_API_KEY) {
|
|
294
|
-
console.log("! CONTEXT7_API_KEY not set; using {env:CONTEXT7_API_KEY} placeholder");
|
|
295
|
-
}
|
|
296
|
-
if (!process.env.GOOGLE_GEMINI_API_KEY) {
|
|
297
|
-
console.log("! GOOGLE_GEMINI_API_KEY not set; human-mcp will require it at runtime");
|
|
298
|
-
}
|
|
299
|
-
console.log(`
|
|
300
|
-
[6/6] Creating CliKit config...`);
|
|
301
|
-
const clikitConfigPath = getCliKitConfigPath();
|
|
302
|
-
if (!fs.existsSync(clikitConfigPath)) {
|
|
303
|
-
const defaultConfig = {
|
|
304
|
-
$schema: `https://unpkg.com/${PLUGIN_NAME}@latest/schema.json`,
|
|
305
|
-
disabled_agents: [],
|
|
306
|
-
disabled_commands: [],
|
|
307
|
-
disabled_skills: [],
|
|
308
|
-
agents: {},
|
|
309
|
-
commands: {},
|
|
310
|
-
skills: {
|
|
311
|
-
enable: [],
|
|
312
|
-
disable: []
|
|
313
|
-
},
|
|
314
|
-
hooks: {}
|
|
315
|
-
};
|
|
316
|
-
writeConfig(clikitConfigPath, defaultConfig);
|
|
317
|
-
console.log(`\u2713 Config created at ${clikitConfigPath}`);
|
|
318
|
-
} else {
|
|
319
|
-
console.log(`\u2713 Config already exists at ${clikitConfigPath}`);
|
|
320
|
-
}
|
|
321
|
-
console.log(`
|
|
322
|
-
\u2713 CliKit installed successfully!
|
|
323
|
-
`);
|
|
324
|
-
console.log("Available commands:");
|
|
325
|
-
console.log(" /create - Start new task with specification");
|
|
326
|
-
console.log(" /start - Begin implementing from plan");
|
|
327
|
-
console.log(" /plan - Create implementation plan");
|
|
328
|
-
console.log(" /verify - Run verification suite");
|
|
329
|
-
console.log(" /ship - Commit, PR, and cleanup");
|
|
330
|
-
console.log(" /review - Request code review");
|
|
331
|
-
console.log(" /debug - Debug issues");
|
|
332
|
-
console.log(`
|
|
333
|
-
Restart OpenCode to use CliKit.
|
|
334
|
-
`);
|
|
335
|
-
return 0;
|
|
336
274
|
}
|
|
337
275
|
function help() {
|
|
338
276
|
console.log(`
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cli.test.d.ts","sourceRoot":"","sources":["../src/cli.test.ts"],"names":[],"mappings":""}
|
package/dist/clikit.schema.json
CHANGED
|
@@ -1,245 +1,263 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "
|
|
3
|
-
"
|
|
4
|
-
"
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"title": "CliKit Configuration",
|
|
4
|
+
"description": "Configuration schema for the CliKit OpenCode plugin",
|
|
5
5
|
"type": "object",
|
|
6
|
-
"additionalProperties": false,
|
|
7
6
|
"properties": {
|
|
8
7
|
"$schema": {
|
|
9
|
-
"type": "string"
|
|
8
|
+
"type": "string",
|
|
9
|
+
"description": "JSON Schema reference"
|
|
10
10
|
},
|
|
11
11
|
"disabled_agents": {
|
|
12
12
|
"type": "array",
|
|
13
13
|
"items": { "type": "string" },
|
|
14
|
-
"
|
|
14
|
+
"description": "List of agent names to disable"
|
|
15
15
|
},
|
|
16
16
|
"disabled_commands": {
|
|
17
17
|
"type": "array",
|
|
18
18
|
"items": { "type": "string" },
|
|
19
|
-
"
|
|
19
|
+
"description": "List of command names to disable"
|
|
20
20
|
},
|
|
21
21
|
"disabled_skills": {
|
|
22
22
|
"type": "array",
|
|
23
23
|
"items": { "type": "string" },
|
|
24
|
-
"
|
|
24
|
+
"description": "List of skill names to disable"
|
|
25
25
|
},
|
|
26
26
|
"agents": {
|
|
27
27
|
"type": "object",
|
|
28
|
+
"description": "Per-agent overrides",
|
|
28
29
|
"additionalProperties": {
|
|
29
|
-
"
|
|
30
|
-
|
|
31
|
-
"properties": {
|
|
32
|
-
"model": { "type": "string" },
|
|
33
|
-
"temperature": { "type": "number" },
|
|
34
|
-
"mode": { "enum": ["subagent", "primary", "all"] },
|
|
35
|
-
"disabled": { "type": "boolean" },
|
|
36
|
-
"tools": {
|
|
37
|
-
"type": "object",
|
|
38
|
-
"additionalProperties": { "type": "boolean" }
|
|
39
|
-
},
|
|
40
|
-
"permission": {
|
|
41
|
-
"type": "object",
|
|
42
|
-
"additionalProperties": true
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
},
|
|
46
|
-
"default": {}
|
|
30
|
+
"$ref": "#/definitions/AgentOverride"
|
|
31
|
+
}
|
|
47
32
|
},
|
|
48
33
|
"commands": {
|
|
49
34
|
"type": "object",
|
|
35
|
+
"description": "Per-command overrides",
|
|
50
36
|
"additionalProperties": {
|
|
51
|
-
"type": "object"
|
|
52
|
-
|
|
53
|
-
},
|
|
54
|
-
"default": {}
|
|
37
|
+
"type": "object"
|
|
38
|
+
}
|
|
55
39
|
},
|
|
56
40
|
"skills": {
|
|
57
|
-
"
|
|
41
|
+
"description": "Skill configuration — array of names, object with enable/disable/sources, or per-skill overrides",
|
|
42
|
+
"oneOf": [
|
|
58
43
|
{
|
|
59
44
|
"type": "array",
|
|
60
45
|
"items": { "type": "string" }
|
|
61
46
|
},
|
|
47
|
+
{
|
|
48
|
+
"$ref": "#/definitions/SkillsConfigObject"
|
|
49
|
+
},
|
|
62
50
|
{
|
|
63
51
|
"type": "object",
|
|
64
|
-
"properties": {
|
|
65
|
-
"sources": {
|
|
66
|
-
"type": "array",
|
|
67
|
-
"items": {
|
|
68
|
-
"anyOf": [
|
|
69
|
-
{ "type": "string" },
|
|
70
|
-
{
|
|
71
|
-
"type": "object",
|
|
72
|
-
"required": ["path"],
|
|
73
|
-
"properties": {
|
|
74
|
-
"path": { "type": "string" },
|
|
75
|
-
"recursive": { "type": "boolean" },
|
|
76
|
-
"glob": { "type": "string" }
|
|
77
|
-
},
|
|
78
|
-
"additionalProperties": false
|
|
79
|
-
}
|
|
80
|
-
]
|
|
81
|
-
}
|
|
82
|
-
},
|
|
83
|
-
"enable": {
|
|
84
|
-
"type": "array",
|
|
85
|
-
"items": { "type": "string" }
|
|
86
|
-
},
|
|
87
|
-
"disable": {
|
|
88
|
-
"type": "array",
|
|
89
|
-
"items": { "type": "string" }
|
|
90
|
-
}
|
|
91
|
-
},
|
|
92
52
|
"additionalProperties": {
|
|
93
|
-
"
|
|
53
|
+
"oneOf": [
|
|
94
54
|
{ "type": "boolean" },
|
|
95
|
-
{
|
|
96
|
-
"type": "object",
|
|
97
|
-
"additionalProperties": true,
|
|
98
|
-
"properties": {
|
|
99
|
-
"description": { "type": "string" },
|
|
100
|
-
"template": { "type": "string" },
|
|
101
|
-
"from": { "type": "string" },
|
|
102
|
-
"model": { "type": "string" },
|
|
103
|
-
"agent": { "type": "string" },
|
|
104
|
-
"subtask": { "type": "boolean" },
|
|
105
|
-
"argument-hint": { "type": "string" },
|
|
106
|
-
"license": { "type": "string" },
|
|
107
|
-
"compatibility": { "type": "string" },
|
|
108
|
-
"metadata": { "type": "object", "additionalProperties": true },
|
|
109
|
-
"allowed-tools": {
|
|
110
|
-
"type": "array",
|
|
111
|
-
"items": { "type": "string" }
|
|
112
|
-
},
|
|
113
|
-
"disable": { "type": "boolean" }
|
|
114
|
-
}
|
|
115
|
-
}
|
|
55
|
+
{ "$ref": "#/definitions/SkillOverride" }
|
|
116
56
|
]
|
|
117
57
|
}
|
|
118
58
|
}
|
|
119
|
-
]
|
|
120
|
-
"default": {}
|
|
59
|
+
]
|
|
121
60
|
},
|
|
122
61
|
"lsp": {
|
|
123
62
|
"type": "object",
|
|
63
|
+
"description": "LSP server configurations",
|
|
124
64
|
"additionalProperties": {
|
|
125
|
-
"
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
65
|
+
"$ref": "#/definitions/LspServerConfig"
|
|
66
|
+
}
|
|
67
|
+
},
|
|
68
|
+
"hooks": {
|
|
69
|
+
"$ref": "#/definitions/HooksConfig"
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"additionalProperties": false,
|
|
73
|
+
"definitions": {
|
|
74
|
+
"AgentOverride": {
|
|
75
|
+
"type": "object",
|
|
76
|
+
"properties": {
|
|
77
|
+
"model": { "type": "string", "description": "Override the model for this agent" },
|
|
78
|
+
"temperature": { "type": "number", "minimum": 0, "maximum": 2 },
|
|
79
|
+
"mode": { "type": "string", "enum": ["subagent", "primary", "all"] },
|
|
80
|
+
"disabled": { "type": "boolean" },
|
|
81
|
+
"tools": {
|
|
82
|
+
"type": "object",
|
|
83
|
+
"additionalProperties": { "type": "boolean" }
|
|
84
|
+
},
|
|
85
|
+
"permission": {
|
|
86
|
+
"type": "object",
|
|
87
|
+
"properties": {
|
|
88
|
+
"edit": { "type": "string", "enum": ["allow", "ask", "deny"] },
|
|
89
|
+
"bash": {
|
|
90
|
+
"oneOf": [
|
|
91
|
+
{ "type": "string", "enum": ["allow", "ask", "deny"] },
|
|
92
|
+
{ "type": "object", "additionalProperties": { "type": "string", "enum": ["allow", "ask", "deny"] } }
|
|
93
|
+
]
|
|
94
|
+
},
|
|
95
|
+
"webfetch": { "type": "string", "enum": ["allow", "ask", "deny"] }
|
|
143
96
|
},
|
|
144
|
-
"
|
|
145
|
-
"type": "object",
|
|
146
|
-
"additionalProperties": true
|
|
147
|
-
}
|
|
97
|
+
"additionalProperties": false
|
|
148
98
|
}
|
|
149
99
|
},
|
|
150
|
-
"
|
|
100
|
+
"additionalProperties": false
|
|
151
101
|
},
|
|
152
|
-
"
|
|
102
|
+
"LspServerConfig": {
|
|
103
|
+
"type": "object",
|
|
104
|
+
"required": ["command"],
|
|
105
|
+
"properties": {
|
|
106
|
+
"command": { "type": "array", "items": { "type": "string" } },
|
|
107
|
+
"extensions": { "type": "array", "items": { "type": "string" } },
|
|
108
|
+
"priority": { "type": "integer" },
|
|
109
|
+
"disabled": { "type": "boolean" },
|
|
110
|
+
"env": { "type": "object", "additionalProperties": { "type": "string" } },
|
|
111
|
+
"initialization": { "type": "object" }
|
|
112
|
+
},
|
|
113
|
+
"additionalProperties": false
|
|
114
|
+
},
|
|
115
|
+
"HooksConfig": {
|
|
153
116
|
"type": "object",
|
|
154
|
-
"additionalProperties": false,
|
|
155
117
|
"properties": {
|
|
156
118
|
"session_logging": { "type": "boolean" },
|
|
157
119
|
"tool_logging": { "type": "boolean" },
|
|
158
120
|
"todo_enforcer": {
|
|
159
121
|
"type": "object",
|
|
160
|
-
"additionalProperties": false,
|
|
161
122
|
"properties": {
|
|
162
123
|
"enabled": { "type": "boolean" },
|
|
163
124
|
"warn_on_incomplete": { "type": "boolean" }
|
|
164
|
-
}
|
|
125
|
+
},
|
|
126
|
+
"additionalProperties": false
|
|
165
127
|
},
|
|
166
128
|
"empty_message_sanitizer": {
|
|
167
129
|
"type": "object",
|
|
168
|
-
"additionalProperties": false,
|
|
169
130
|
"properties": {
|
|
170
131
|
"enabled": { "type": "boolean" },
|
|
171
132
|
"log_empty": { "type": "boolean" },
|
|
172
133
|
"placeholder": { "type": "string" }
|
|
173
|
-
}
|
|
134
|
+
},
|
|
135
|
+
"additionalProperties": false
|
|
174
136
|
},
|
|
175
137
|
"git_guard": {
|
|
176
138
|
"type": "object",
|
|
177
|
-
"additionalProperties": false,
|
|
178
139
|
"properties": {
|
|
179
140
|
"enabled": { "type": "boolean" },
|
|
180
141
|
"allow_force_with_lease": { "type": "boolean" }
|
|
181
|
-
}
|
|
142
|
+
},
|
|
143
|
+
"additionalProperties": false
|
|
182
144
|
},
|
|
183
145
|
"security_check": {
|
|
184
146
|
"type": "object",
|
|
185
|
-
"additionalProperties": false,
|
|
186
147
|
"properties": {
|
|
187
148
|
"enabled": { "type": "boolean" },
|
|
188
149
|
"block_commits": { "type": "boolean" }
|
|
189
|
-
}
|
|
150
|
+
},
|
|
151
|
+
"additionalProperties": false
|
|
190
152
|
},
|
|
191
153
|
"subagent_question_blocker": {
|
|
192
154
|
"type": "object",
|
|
193
|
-
"additionalProperties": false,
|
|
194
155
|
"properties": {
|
|
195
156
|
"enabled": { "type": "boolean" }
|
|
196
|
-
}
|
|
157
|
+
},
|
|
158
|
+
"additionalProperties": false
|
|
197
159
|
},
|
|
198
160
|
"truncator": {
|
|
199
161
|
"type": "object",
|
|
200
|
-
"additionalProperties": false,
|
|
201
162
|
"properties": {
|
|
202
163
|
"enabled": { "type": "boolean" },
|
|
203
|
-
"max_output_chars": { "type": "
|
|
204
|
-
"max_output_lines": { "type": "
|
|
205
|
-
"preserve_head_lines": { "type": "
|
|
206
|
-
"preserve_tail_lines": { "type": "
|
|
164
|
+
"max_output_chars": { "type": "integer" },
|
|
165
|
+
"max_output_lines": { "type": "integer" },
|
|
166
|
+
"preserve_head_lines": { "type": "integer" },
|
|
167
|
+
"preserve_tail_lines": { "type": "integer" },
|
|
207
168
|
"log": { "type": "boolean" }
|
|
208
|
-
}
|
|
169
|
+
},
|
|
170
|
+
"additionalProperties": false
|
|
209
171
|
},
|
|
210
172
|
"swarm_enforcer": {
|
|
211
173
|
"type": "object",
|
|
212
|
-
"additionalProperties": false,
|
|
213
174
|
"properties": {
|
|
214
175
|
"enabled": { "type": "boolean" },
|
|
215
176
|
"strict_file_locking": { "type": "boolean" },
|
|
216
177
|
"block_unreserved_edits": { "type": "boolean" },
|
|
217
178
|
"log": { "type": "boolean" }
|
|
218
|
-
}
|
|
179
|
+
},
|
|
180
|
+
"additionalProperties": false
|
|
219
181
|
},
|
|
220
182
|
"memory_digest": {
|
|
221
183
|
"type": "object",
|
|
222
|
-
"additionalProperties": false,
|
|
223
184
|
"properties": {
|
|
224
185
|
"enabled": { "type": "boolean" },
|
|
225
|
-
"max_per_type": { "type": "
|
|
226
|
-
"include_types": {
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
},
|
|
186
|
+
"max_per_type": { "type": "integer" },
|
|
187
|
+
"include_types": { "type": "array", "items": { "type": "string" } },
|
|
188
|
+
"index_highlights_per_type": { "type": "integer" },
|
|
189
|
+
"write_topic_files": { "type": "boolean" },
|
|
230
190
|
"log": { "type": "boolean" }
|
|
231
|
-
}
|
|
191
|
+
},
|
|
192
|
+
"additionalProperties": false
|
|
232
193
|
},
|
|
233
194
|
"todo_beads_sync": {
|
|
234
195
|
"type": "object",
|
|
235
|
-
"additionalProperties": false,
|
|
236
196
|
"properties": {
|
|
237
197
|
"enabled": { "type": "boolean" },
|
|
238
198
|
"close_missing": { "type": "boolean" },
|
|
239
199
|
"log": { "type": "boolean" }
|
|
240
|
-
}
|
|
200
|
+
},
|
|
201
|
+
"additionalProperties": false
|
|
202
|
+
},
|
|
203
|
+
"cass_memory": {
|
|
204
|
+
"type": "object",
|
|
205
|
+
"properties": {
|
|
206
|
+
"enabled": { "type": "boolean" },
|
|
207
|
+
"context_on_session_created": { "type": "boolean" },
|
|
208
|
+
"reflect_on_session_idle": { "type": "boolean" },
|
|
209
|
+
"context_limit": { "type": "integer" },
|
|
210
|
+
"reflect_days": { "type": "integer" },
|
|
211
|
+
"cm_path": { "type": "string" },
|
|
212
|
+
"log": { "type": "boolean" }
|
|
213
|
+
},
|
|
214
|
+
"additionalProperties": false
|
|
241
215
|
}
|
|
242
|
-
}
|
|
216
|
+
},
|
|
217
|
+
"additionalProperties": false
|
|
218
|
+
},
|
|
219
|
+
"SkillsConfigObject": {
|
|
220
|
+
"type": "object",
|
|
221
|
+
"properties": {
|
|
222
|
+
"sources": {
|
|
223
|
+
"type": "array",
|
|
224
|
+
"items": {
|
|
225
|
+
"oneOf": [
|
|
226
|
+
{ "type": "string" },
|
|
227
|
+
{
|
|
228
|
+
"type": "object",
|
|
229
|
+
"required": ["path"],
|
|
230
|
+
"properties": {
|
|
231
|
+
"path": { "type": "string" },
|
|
232
|
+
"recursive": { "type": "boolean" },
|
|
233
|
+
"glob": { "type": "string" }
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
]
|
|
237
|
+
}
|
|
238
|
+
},
|
|
239
|
+
"enable": { "type": "array", "items": { "type": "string" } },
|
|
240
|
+
"disable": { "type": "array", "items": { "type": "string" } }
|
|
241
|
+
},
|
|
242
|
+
"additionalProperties": true
|
|
243
|
+
},
|
|
244
|
+
"SkillOverride": {
|
|
245
|
+
"type": "object",
|
|
246
|
+
"properties": {
|
|
247
|
+
"disable": { "type": "boolean" },
|
|
248
|
+
"description": { "type": "string" },
|
|
249
|
+
"template": { "type": "string" },
|
|
250
|
+
"from": { "type": "string" },
|
|
251
|
+
"model": { "type": "string" },
|
|
252
|
+
"agent": { "type": "string" },
|
|
253
|
+
"subtask": { "type": "boolean" },
|
|
254
|
+
"argument-hint": { "type": "string" },
|
|
255
|
+
"license": { "type": "string" },
|
|
256
|
+
"compatibility": { "type": "string" },
|
|
257
|
+
"metadata": { "type": "object" },
|
|
258
|
+
"allowed-tools": { "type": "array", "items": { "type": "string" } }
|
|
259
|
+
},
|
|
260
|
+
"additionalProperties": false
|
|
243
261
|
}
|
|
244
262
|
}
|
|
245
263
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/commands/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AA+C9C,wBAAgB,YAAY,IAAI,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAuB5D;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/commands/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AA+C9C,wBAAgB,YAAY,IAAI,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAuB5D;AAmBD,wBAAgB,kBAAkB,IAAI,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAWlE"}
|
package/dist/config.d.ts
CHANGED
|
@@ -54,6 +54,8 @@ export interface MemoryDigestHookConfig {
|
|
|
54
54
|
enabled?: boolean;
|
|
55
55
|
max_per_type?: number;
|
|
56
56
|
include_types?: string[];
|
|
57
|
+
index_highlights_per_type?: number;
|
|
58
|
+
write_topic_files?: boolean;
|
|
57
59
|
log?: boolean;
|
|
58
60
|
}
|
|
59
61
|
export interface TodoBeadsSyncHookConfig {
|
|
@@ -61,6 +63,15 @@ export interface TodoBeadsSyncHookConfig {
|
|
|
61
63
|
close_missing?: boolean;
|
|
62
64
|
log?: boolean;
|
|
63
65
|
}
|
|
66
|
+
export interface CassMemoryHookConfig {
|
|
67
|
+
enabled?: boolean;
|
|
68
|
+
context_on_session_created?: boolean;
|
|
69
|
+
reflect_on_session_idle?: boolean;
|
|
70
|
+
context_limit?: number;
|
|
71
|
+
reflect_days?: number;
|
|
72
|
+
cm_path?: string;
|
|
73
|
+
log?: boolean;
|
|
74
|
+
}
|
|
64
75
|
export interface HooksConfig {
|
|
65
76
|
session_logging?: boolean;
|
|
66
77
|
tool_logging?: boolean;
|
|
@@ -73,6 +84,7 @@ export interface HooksConfig {
|
|
|
73
84
|
swarm_enforcer?: SwarmEnforcerHookConfig;
|
|
74
85
|
memory_digest?: MemoryDigestHookConfig;
|
|
75
86
|
todo_beads_sync?: TodoBeadsSyncHookConfig;
|
|
87
|
+
cass_memory?: CassMemoryHookConfig;
|
|
76
88
|
}
|
|
77
89
|
export interface SkillOverride {
|
|
78
90
|
disable?: boolean;
|
|
@@ -110,6 +122,7 @@ export interface CliKitConfig {
|
|
|
110
122
|
hooks?: HooksConfig;
|
|
111
123
|
}
|
|
112
124
|
declare function getUserConfigDir(): string;
|
|
125
|
+
export declare function deepMerge<T extends object>(base: T, override: Partial<T>): T;
|
|
113
126
|
export declare function loadCliKitConfig(projectDirectory: unknown): CliKitConfig;
|
|
114
127
|
export declare function filterAgents(agents: Record<string, AgentConfig>, config: CliKitConfig | undefined | null): Record<string, AgentConfig>;
|
|
115
128
|
export declare function filterCommands(commands: Record<string, CommandConfig>, config: CliKitConfig | undefined | null): Record<string, CommandConfig>;
|