chatccc 0.2.107 → 0.2.108
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/package.json +63 -63
- package/src/__tests__/config-reload.test.ts +2 -1
- package/src/config.ts +2 -2
package/package.json
CHANGED
|
@@ -1,63 +1,63 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "chatccc",
|
|
3
|
-
"version": "0.2.
|
|
4
|
-
"description": "Feishu bot bridge for Claude Code",
|
|
5
|
-
"license": "Apache-2.0",
|
|
6
|
-
"type": "module",
|
|
7
|
-
"main": "./src/index.ts",
|
|
8
|
-
"bin": {
|
|
9
|
-
"chatccc": "bin/chatccc.mjs"
|
|
10
|
-
},
|
|
11
|
-
"files": [
|
|
12
|
-
"src/",
|
|
13
|
-
"bin/",
|
|
14
|
-
"scripts/postinstall-sharp-check.mjs",
|
|
15
|
-
"demo/ilink_echo_probe.ts",
|
|
16
|
-
"im-skills/",
|
|
17
|
-
"images/img_readme_*.jpg",
|
|
18
|
-
"images/img_readme_*.png",
|
|
19
|
-
"images/avatars/status_*.png",
|
|
20
|
-
"images/avatars/badges/",
|
|
21
|
-
"package.json",
|
|
22
|
-
"README.md",
|
|
23
|
-
"config.sample.json"
|
|
24
|
-
],
|
|
25
|
-
"scripts": {
|
|
26
|
-
"dev": "tsx src/index.ts",
|
|
27
|
-
"chatccc": "tsx src/index.ts",
|
|
28
|
-
"start": "tsx src/index.ts",
|
|
29
|
-
"demo:bot-test": "tsx demo/bot_test.ts",
|
|
30
|
-
"demo:bot-test:local": "tsx demo/bot_test.ts --local",
|
|
31
|
-
"demo:create-group": "tsx src/index.ts",
|
|
32
|
-
"demo:create-group:local": "tsx src/index.ts --local",
|
|
33
|
-
"demo:permission-check": "tsx demo/permission_check.ts",
|
|
34
|
-
"demo:claude-hi": "tsx demo/claude_say_hi.ts",
|
|
35
|
-
"demo:codex-hi": "tsx demo/codex_say_hi.ts",
|
|
36
|
-
"demo:ilink-echo": "tsx demo/ilink_echo_probe.ts",
|
|
37
|
-
"test": "vitest run",
|
|
38
|
-
"test:watch": "vitest",
|
|
39
|
-
"postinstall": "node scripts/postinstall-sharp-check.mjs"
|
|
40
|
-
},
|
|
41
|
-
"dependencies": {
|
|
42
|
-
"@ai-sdk/openai-compatible": "^2.0.47",
|
|
43
|
-
"@anthropic-ai/claude-agent-sdk": "0.2.133",
|
|
44
|
-
"@larksuiteoapi/node-sdk": "^1.59.0",
|
|
45
|
-
"@openilink/openilink-sdk-node": "^0.6.0",
|
|
46
|
-
"ai": "^6.0.184",
|
|
47
|
-
"nodemailer": "^8.0.7",
|
|
48
|
-
"qrcode-terminal": "^0.12.0",
|
|
49
|
-
"sharp": "^0.34.5",
|
|
50
|
-
"tsx": "^4.0.0",
|
|
51
|
-
"ws": "^8.18.0"
|
|
52
|
-
},
|
|
53
|
-
"devDependencies": {
|
|
54
|
-
"@types/node": "^20.0.0",
|
|
55
|
-
"@types/qrcode-terminal": "^0.12.2",
|
|
56
|
-
"@types/ws": "^8.18.1",
|
|
57
|
-
"typescript": "^5.0.0",
|
|
58
|
-
"vitest": "^3.2.4"
|
|
59
|
-
},
|
|
60
|
-
"engines": {
|
|
61
|
-
"node": ">=20"
|
|
62
|
-
}
|
|
63
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "chatccc",
|
|
3
|
+
"version": "0.2.108",
|
|
4
|
+
"description": "Feishu bot bridge for Claude Code",
|
|
5
|
+
"license": "Apache-2.0",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"main": "./src/index.ts",
|
|
8
|
+
"bin": {
|
|
9
|
+
"chatccc": "bin/chatccc.mjs"
|
|
10
|
+
},
|
|
11
|
+
"files": [
|
|
12
|
+
"src/",
|
|
13
|
+
"bin/",
|
|
14
|
+
"scripts/postinstall-sharp-check.mjs",
|
|
15
|
+
"demo/ilink_echo_probe.ts",
|
|
16
|
+
"im-skills/",
|
|
17
|
+
"images/img_readme_*.jpg",
|
|
18
|
+
"images/img_readme_*.png",
|
|
19
|
+
"images/avatars/status_*.png",
|
|
20
|
+
"images/avatars/badges/",
|
|
21
|
+
"package.json",
|
|
22
|
+
"README.md",
|
|
23
|
+
"config.sample.json"
|
|
24
|
+
],
|
|
25
|
+
"scripts": {
|
|
26
|
+
"dev": "tsx src/index.ts",
|
|
27
|
+
"chatccc": "tsx src/index.ts",
|
|
28
|
+
"start": "tsx src/index.ts",
|
|
29
|
+
"demo:bot-test": "tsx demo/bot_test.ts",
|
|
30
|
+
"demo:bot-test:local": "tsx demo/bot_test.ts --local",
|
|
31
|
+
"demo:create-group": "tsx src/index.ts",
|
|
32
|
+
"demo:create-group:local": "tsx src/index.ts --local",
|
|
33
|
+
"demo:permission-check": "tsx demo/permission_check.ts",
|
|
34
|
+
"demo:claude-hi": "tsx demo/claude_say_hi.ts",
|
|
35
|
+
"demo:codex-hi": "tsx demo/codex_say_hi.ts",
|
|
36
|
+
"demo:ilink-echo": "tsx demo/ilink_echo_probe.ts",
|
|
37
|
+
"test": "vitest run",
|
|
38
|
+
"test:watch": "vitest",
|
|
39
|
+
"postinstall": "node scripts/postinstall-sharp-check.mjs"
|
|
40
|
+
},
|
|
41
|
+
"dependencies": {
|
|
42
|
+
"@ai-sdk/openai-compatible": "^2.0.47",
|
|
43
|
+
"@anthropic-ai/claude-agent-sdk": "0.2.133",
|
|
44
|
+
"@larksuiteoapi/node-sdk": "^1.59.0",
|
|
45
|
+
"@openilink/openilink-sdk-node": "^0.6.0",
|
|
46
|
+
"ai": "^6.0.184",
|
|
47
|
+
"nodemailer": "^8.0.7",
|
|
48
|
+
"qrcode-terminal": "^0.12.0",
|
|
49
|
+
"sharp": "^0.34.5",
|
|
50
|
+
"tsx": "^4.0.0",
|
|
51
|
+
"ws": "^8.18.0"
|
|
52
|
+
},
|
|
53
|
+
"devDependencies": {
|
|
54
|
+
"@types/node": "^20.0.0",
|
|
55
|
+
"@types/qrcode-terminal": "^0.12.2",
|
|
56
|
+
"@types/ws": "^8.18.1",
|
|
57
|
+
"typescript": "^5.0.0",
|
|
58
|
+
"vitest": "^3.2.4"
|
|
59
|
+
},
|
|
60
|
+
"engines": {
|
|
61
|
+
"node": ">=20"
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -131,7 +131,8 @@ describe("applyLoadedConfig — 刷新 export let 常量", () => {
|
|
|
131
131
|
cursor: { enabled: true, defaultAgent: false, path: "/x/cursor", model: "claude-3.7-sonnet" },
|
|
132
132
|
});
|
|
133
133
|
|
|
134
|
-
// CURSOR_AGENT_ARGS 是 ['-p', '--force', ..., '--model', 'claude-3.7-sonnet']
|
|
134
|
+
// CURSOR_AGENT_ARGS 是 ['-p', '--force', '--approve-mcps', ..., '--model', 'claude-3.7-sonnet']
|
|
135
|
+
expect(CURSOR_AGENT_ARGS).toContain("--approve-mcps");
|
|
135
136
|
expect(CURSOR_AGENT_ARGS).toContain("--model");
|
|
136
137
|
expect(CURSOR_AGENT_ARGS).toContain("claude-3.7-sonnet");
|
|
137
138
|
});
|
package/src/config.ts
CHANGED
|
@@ -555,7 +555,7 @@ function detectCursorAgent(): string {
|
|
|
555
555
|
export let CURSOR_AGENT_COMMAND = detectCursorAgent();
|
|
556
556
|
|
|
557
557
|
function resolveCursorAgentArgs(): string[] {
|
|
558
|
-
let args = "-p --force --output-format stream-json --stream-partial-output";
|
|
558
|
+
let args = "-p --force --approve-mcps --output-format stream-json --stream-partial-output";
|
|
559
559
|
const model = config.cursor.model;
|
|
560
560
|
if (model.trim() !== "") {
|
|
561
561
|
args += ` --model ${model}`;
|
|
@@ -563,7 +563,7 @@ function resolveCursorAgentArgs(): string[] {
|
|
|
563
563
|
return args.split(/\s+/).filter(Boolean);
|
|
564
564
|
}
|
|
565
565
|
|
|
566
|
-
/** Cursor agent 参数:-p 非交互模式,--force
|
|
566
|
+
/** Cursor agent 参数:-p 非交互模式,--force 强制允许命令,--approve-mcps 自动批准 MCP,stream-json 流式 JSONL 输出 */
|
|
567
567
|
export let CURSOR_AGENT_ARGS = resolveCursorAgentArgs();
|
|
568
568
|
|
|
569
569
|
// ---------------------------------------------------------------------------
|