ccjk 13.6.7 → 14.0.0
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/dist/chunks/api-cli.mjs +4 -2
- package/dist/chunks/api-config-selector.mjs +2 -4
- package/dist/chunks/auto-fix.mjs +3 -1
- package/dist/chunks/ccjk-all.mjs +5 -2
- package/dist/chunks/ccjk-mcp.mjs +5 -2
- package/dist/chunks/ccjk-setup.mjs +4 -1
- package/dist/chunks/ccr.mjs +3 -5
- package/dist/chunks/check-updates.mjs +0 -1
- package/dist/chunks/claude-code-incremental-manager.mjs +4 -6
- package/dist/chunks/codex-config-switch.mjs +0 -1
- package/dist/chunks/codex-provider-manager.mjs +0 -1
- package/dist/chunks/codex.mjs +2 -2
- package/dist/chunks/config-switch.mjs +2 -4
- package/dist/chunks/config.mjs +1104 -5
- package/dist/chunks/config2.mjs +6 -4
- package/dist/chunks/config3.mjs +4 -2
- package/dist/chunks/doctor.mjs +1 -1
- package/dist/chunks/evolution.mjs +47 -27
- package/dist/chunks/features.mjs +2 -3
- package/dist/chunks/index10.mjs +64 -10
- package/dist/chunks/init.mjs +6 -7
- package/dist/chunks/installer.mjs +2 -2
- package/dist/chunks/mcp-cli.mjs +18 -19
- package/dist/chunks/mcp.mjs +6 -7
- package/dist/chunks/package.mjs +1 -1
- package/dist/chunks/platform.mjs +1 -1
- package/dist/chunks/quick-setup.mjs +1 -2
- package/dist/chunks/slash-commands.mjs +1 -1
- package/dist/chunks/update.mjs +4 -5
- package/dist/i18n/locales/en/menu.json +7 -0
- package/dist/i18n/locales/zh-CN/menu.json +7 -0
- package/dist/index.mjs +3 -2
- package/dist/shared/{ccjk.DHaUdzX3.mjs → ccjk.B6VCKdyy.mjs} +2 -2
- package/dist/shared/{ccjk.B4aXNclK.mjs → ccjk.CVjfbEIj.mjs} +1 -1
- package/dist/shared/{ccjk.Dz0ssUQx.mjs → ccjk.Dh6Be-ef.mjs} +1 -1
- package/package.json +1 -1
- package/dist/chunks/claude-code-config-manager.mjs +0 -811
- package/dist/chunks/claude-config.mjs +0 -286
package/dist/chunks/config2.mjs
CHANGED
|
@@ -8,8 +8,7 @@ import { d as dayjs } from '../shared/ccjk.RyizuzOI.mjs';
|
|
|
8
8
|
import { i as inquirer } from './index6.mjs';
|
|
9
9
|
import { SETTINGS_FILE } from './constants.mjs';
|
|
10
10
|
import { ensureI18nInitialized, i18n } from './index2.mjs';
|
|
11
|
-
import {
|
|
12
|
-
import { b as backupExistingConfig } from './config.mjs';
|
|
11
|
+
import { l as setPrimaryApiKey, n as addCompletedOnboarding, b as backupExistingConfig } from './config.mjs';
|
|
13
12
|
import { readJsonConfig, writeJsonConfig } from './json-config.mjs';
|
|
14
13
|
import { p as promptBoolean } from '../shared/ccjk.DZ2LLOa-.mjs';
|
|
15
14
|
import { j as join } from '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
@@ -34,6 +33,9 @@ import 'node:stream';
|
|
|
34
33
|
import './fs-operations.mjs';
|
|
35
34
|
import 'node:fs/promises';
|
|
36
35
|
import '../shared/ccjk.DScm_NnL.mjs';
|
|
36
|
+
import './ccjk-config.mjs';
|
|
37
|
+
import '../shared/ccjk.BBtCGd_g.mjs';
|
|
38
|
+
import './index3.mjs';
|
|
37
39
|
import '../shared/ccjk.DeWpAShp.mjs';
|
|
38
40
|
|
|
39
41
|
const PROVIDER_PRESETS_URL = "https://pub-0dc3e1677e894f07bbea11b17a29e032.r2.dev/providers.json";
|
|
@@ -415,7 +417,7 @@ async function setupCcrConfiguration() {
|
|
|
415
417
|
console.log(a.yellow(`${i18n.t("ccr:keepingExistingConfig")}`));
|
|
416
418
|
await configureCcrProxy(existingConfig);
|
|
417
419
|
try {
|
|
418
|
-
const { manageApiKeyApproval } = await import('./
|
|
420
|
+
const { manageApiKeyApproval } = await import('./config.mjs').then(function (n) { return n.E; });
|
|
419
421
|
const apiKey = existingConfig.APIKEY || "sk-ccjk-x-ccr";
|
|
420
422
|
manageApiKeyApproval(apiKey);
|
|
421
423
|
console.log(a.green(`\u2714 ${i18n.t("ccr:apiKeyApprovalSuccess")}`));
|
|
@@ -449,7 +451,7 @@ async function setupCcrConfiguration() {
|
|
|
449
451
|
console.error(a.red(i18n.t("errors:failedToSetOnboarding")), error);
|
|
450
452
|
}
|
|
451
453
|
try {
|
|
452
|
-
const { manageApiKeyApproval } = await import('./
|
|
454
|
+
const { manageApiKeyApproval } = await import('./config.mjs').then(function (n) { return n.E; });
|
|
453
455
|
const apiKey = config.APIKEY || "sk-ccjk-x-ccr";
|
|
454
456
|
manageApiKeyApproval(apiKey);
|
|
455
457
|
console.log(a.green(`\u2714 ${i18n.t("ccr:apiKeyApprovalSuccess")}`));
|
package/dist/chunks/config3.mjs
CHANGED
|
@@ -21,10 +21,9 @@ import 'node:os';
|
|
|
21
21
|
import 'node:crypto';
|
|
22
22
|
import 'buffer';
|
|
23
23
|
import 'string_decoder';
|
|
24
|
-
import '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
25
24
|
import 'node:url';
|
|
25
|
+
import '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
26
26
|
import '../shared/ccjk.RyizuzOI.mjs';
|
|
27
|
-
import './claude-config.mjs';
|
|
28
27
|
import './json-config.mjs';
|
|
29
28
|
import './fs-operations.mjs';
|
|
30
29
|
import 'node:fs/promises';
|
|
@@ -34,6 +33,9 @@ import 'module';
|
|
|
34
33
|
import 'node:child_process';
|
|
35
34
|
import 'node:stream';
|
|
36
35
|
import '../shared/ccjk.DScm_NnL.mjs';
|
|
36
|
+
import './ccjk-config.mjs';
|
|
37
|
+
import '../shared/ccjk.BBtCGd_g.mjs';
|
|
38
|
+
import './index3.mjs';
|
|
37
39
|
|
|
38
40
|
async function getConfig(key, options = {}) {
|
|
39
41
|
const isZh = i18n.language === "zh-CN";
|
package/dist/chunks/doctor.mjs
CHANGED
|
@@ -814,7 +814,7 @@ async function checkPermissionRules() {
|
|
|
814
814
|
}
|
|
815
815
|
async function fixSettingsFile() {
|
|
816
816
|
const isZh = i18n.language === "zh-CN";
|
|
817
|
-
const { copyConfigFiles } = await import('./config.mjs').then(function (n) { return n.
|
|
817
|
+
const { copyConfigFiles } = await import('./config.mjs').then(function (n) { return n.B; });
|
|
818
818
|
console.log("");
|
|
819
819
|
console.log(a.bold.cyan("\u{1F527} Fixing settings.json"));
|
|
820
820
|
console.log(a.dim("\u2500".repeat(50)));
|
|
@@ -27,88 +27,108 @@ class A2AClient {
|
|
|
27
27
|
this.baseUrl = resolved;
|
|
28
28
|
}
|
|
29
29
|
/**
|
|
30
|
-
* Register agent
|
|
30
|
+
* Register agent — POST /a2a/hello
|
|
31
|
+
* Server expects: { agent: { name, version }, capabilities }
|
|
31
32
|
*/
|
|
32
|
-
async hello(
|
|
33
|
+
async hello(name, version, capabilities = []) {
|
|
33
34
|
const response = await this.request("/a2a/hello", {
|
|
34
35
|
method: "POST",
|
|
35
|
-
body: {
|
|
36
|
+
body: { agent: { name, version }, capabilities }
|
|
36
37
|
});
|
|
37
38
|
this.token = response.token;
|
|
38
39
|
this.agentId = response.agentId;
|
|
39
40
|
return response;
|
|
40
41
|
}
|
|
41
42
|
/**
|
|
42
|
-
* Publish a gene
|
|
43
|
+
* Publish a gene — POST /a2a/publish
|
|
44
|
+
* Server expects flat fields: problemSignature, solutionStrategy, solutionCode, solutionSteps, tags, version
|
|
43
45
|
*/
|
|
44
|
-
async publish(gene
|
|
46
|
+
async publish(gene) {
|
|
45
47
|
this.ensureAuthenticated();
|
|
46
48
|
return this.request("/a2a/publish", {
|
|
47
49
|
method: "POST",
|
|
48
|
-
body: {
|
|
50
|
+
body: {
|
|
51
|
+
problemSignature: gene.problemSignature,
|
|
52
|
+
solutionStrategy: gene.solutionStrategy,
|
|
53
|
+
solutionCode: gene.solutionCode || "",
|
|
54
|
+
solutionSteps: gene.solutionSteps,
|
|
55
|
+
tags: gene.tags || [],
|
|
56
|
+
version: gene.version || "1.0.0"
|
|
57
|
+
},
|
|
49
58
|
auth: true
|
|
50
59
|
});
|
|
51
60
|
}
|
|
52
61
|
/**
|
|
53
|
-
* Fetch genes
|
|
62
|
+
* Fetch genes — GET /a2a/fetch?minGDI=&limit=&signature=
|
|
63
|
+
* Server returns: { success, genes: [...] }
|
|
54
64
|
*/
|
|
55
|
-
async fetch(
|
|
65
|
+
async fetch(options = {}) {
|
|
56
66
|
this.ensureAuthenticated();
|
|
57
|
-
const
|
|
58
|
-
|
|
59
|
-
|
|
67
|
+
const params = new URLSearchParams();
|
|
68
|
+
if (options.minGDI !== void 0) params.set("minGDI", String(options.minGDI));
|
|
69
|
+
if (options.limit !== void 0) params.set("limit", String(options.limit));
|
|
70
|
+
if (options.signature) params.set("signature", options.signature);
|
|
71
|
+
if (options.geneId) params.set("geneId", options.geneId);
|
|
72
|
+
const qs = params.toString();
|
|
73
|
+
const response = await this.request(`/a2a/fetch${qs ? "?" + qs : ""}`, {
|
|
74
|
+
method: "GET",
|
|
60
75
|
auth: true
|
|
61
76
|
});
|
|
62
77
|
return response.genes;
|
|
63
78
|
}
|
|
64
79
|
/**
|
|
65
|
-
* Report usage result
|
|
80
|
+
* Report usage result — POST /a2a/report
|
|
81
|
+
* Server expects: { geneId, outcome, context? }
|
|
66
82
|
*/
|
|
67
|
-
async report(geneId,
|
|
83
|
+
async report(geneId, outcome, context) {
|
|
68
84
|
this.ensureAuthenticated();
|
|
69
85
|
return this.request("/a2a/report", {
|
|
70
86
|
method: "POST",
|
|
71
|
-
body: {
|
|
87
|
+
body: { geneId, outcome, ...context ? { context } : {} },
|
|
72
88
|
auth: true
|
|
73
89
|
});
|
|
74
90
|
}
|
|
75
91
|
/**
|
|
76
|
-
*
|
|
92
|
+
* Record decision — POST /a2a/decision
|
|
93
|
+
* Server expects: { geneId, action: 'approve' | 'reject' }
|
|
77
94
|
*/
|
|
78
|
-
async decision(
|
|
95
|
+
async decision(geneId, action) {
|
|
79
96
|
this.ensureAuthenticated();
|
|
80
97
|
return this.request("/a2a/decision", {
|
|
81
98
|
method: "POST",
|
|
82
|
-
body: {
|
|
99
|
+
body: { geneId, action },
|
|
83
100
|
auth: true
|
|
84
101
|
});
|
|
85
102
|
}
|
|
86
103
|
/**
|
|
87
|
-
* Revoke a gene
|
|
104
|
+
* Revoke a gene — POST /a2a/revoke
|
|
105
|
+
* Server expects: { geneId, reason? }
|
|
88
106
|
*/
|
|
89
107
|
async revoke(geneId, reason) {
|
|
90
108
|
this.ensureAuthenticated();
|
|
91
109
|
await this.request("/a2a/revoke", {
|
|
92
110
|
method: "POST",
|
|
93
|
-
body: {
|
|
111
|
+
body: { geneId, ...reason ? { reason } : {} },
|
|
94
112
|
auth: true
|
|
95
113
|
});
|
|
96
114
|
}
|
|
97
115
|
/**
|
|
98
|
-
* Get
|
|
116
|
+
* Get stats — GET /a2a/stats
|
|
99
117
|
*/
|
|
118
|
+
async stats() {
|
|
119
|
+
this.ensureAuthenticated();
|
|
120
|
+
const resp = await this.request("/a2a/stats", {
|
|
121
|
+
method: "GET",
|
|
122
|
+
auth: true
|
|
123
|
+
});
|
|
124
|
+
return resp.stats;
|
|
125
|
+
}
|
|
100
126
|
getAgentId() {
|
|
101
127
|
return this.agentId;
|
|
102
128
|
}
|
|
103
|
-
/**
|
|
104
|
-
* Check if authenticated
|
|
105
|
-
*/
|
|
106
129
|
isAuthenticated() {
|
|
107
130
|
return this.token !== null;
|
|
108
131
|
}
|
|
109
|
-
/**
|
|
110
|
-
* Internal request wrapper
|
|
111
|
-
*/
|
|
112
132
|
async request(path, options) {
|
|
113
133
|
const url = `${this.baseUrl}${path}`;
|
|
114
134
|
const headers = {
|
|
@@ -124,7 +144,7 @@ class A2AClient {
|
|
|
124
144
|
});
|
|
125
145
|
if (!response.ok) {
|
|
126
146
|
const error = await response.json().catch(() => ({ error: response.statusText }));
|
|
127
|
-
throw new Error(error.error || `Request failed: ${response.statusText}`);
|
|
147
|
+
throw new Error(error.error || error.message || `Request failed: ${response.statusText}`);
|
|
128
148
|
}
|
|
129
149
|
return response.json();
|
|
130
150
|
}
|
package/dist/chunks/features.mjs
CHANGED
|
@@ -7,9 +7,8 @@ import { g as getMcpServices } from '../shared/ccjk.DKXs7Fbm.mjs';
|
|
|
7
7
|
import { SUPPORTED_LANGS, LANG_LABELS } from './constants.mjs';
|
|
8
8
|
import { ensureI18nInitialized, i18n, changeLanguage } from './index2.mjs';
|
|
9
9
|
import { updateZcfConfig, readZcfConfig } from './ccjk-config.mjs';
|
|
10
|
-
import { r as readMcpConfig, f as fixWindowsMcpConfig, w as writeMcpConfig,
|
|
11
|
-
import {
|
|
12
|
-
import { c as configureOutputStyle, m as modifyApiConfigPartially, v as validateApiKey, f as formatApiKeyDisplay } from '../shared/ccjk.Dz0ssUQx.mjs';
|
|
10
|
+
import { g as getExistingModelConfig, a as getExistingCustomModelConfig, u as updateCustomModel, c as updateDefaultModel, r as readMcpConfig, f as fixWindowsMcpConfig, w as writeMcpConfig, d as backupMcpConfig, e as buildMcpServerConfig, m as mergeMcpServers, h as getExistingApiConfig, p as promptApiConfigurationAction, i as configureApi } from './config.mjs';
|
|
11
|
+
import { c as configureOutputStyle, m as modifyApiConfigPartially, v as validateApiKey, f as formatApiKeyDisplay } from '../shared/ccjk.Dh6Be-ef.mjs';
|
|
13
12
|
import { s as selectMcpServices } from '../shared/ccjk.BI-hdI7P.mjs';
|
|
14
13
|
import { i as isWindows } from './platform.mjs';
|
|
15
14
|
import { a as addNumbersToChoices } from '../shared/ccjk.BFQ7yr5S.mjs';
|
package/dist/chunks/index10.mjs
CHANGED
|
@@ -26,7 +26,7 @@ import { configSwitchCommand } from './config-switch.mjs';
|
|
|
26
26
|
import process__default from 'node:process';
|
|
27
27
|
import { readFile, writeFileAtomic, ensureDir, exists, readJsonFile } from './fs-operations.mjs';
|
|
28
28
|
import { workspaceDiagnostics, doctor } from './doctor.mjs';
|
|
29
|
-
import { a as mcpList, c as mcpUninstall, m as mcpInstall, d as mcpTrending, b as mcpSearch } from '../shared/ccjk.
|
|
29
|
+
import { a as mcpList, c as mcpUninstall, m as mcpInstall, d as mcpTrending, b as mcpSearch } from '../shared/ccjk.CVjfbEIj.mjs';
|
|
30
30
|
import { notificationCommand } from './notification.mjs';
|
|
31
31
|
import { g as getRuntimeVersion } from '../shared/ccjk.gDEDGD_t.mjs';
|
|
32
32
|
import { uninstall } from './uninstall.mjs';
|
|
@@ -3774,6 +3774,15 @@ function getToolModeMeta(codeTool) {
|
|
|
3774
3774
|
config: t("menu:toolMode.claude.config", "Primary config: ~/.claude/settings.json"),
|
|
3775
3775
|
menuTitle: t("menu:toolMode.claude.menuTitle", "Claude Control Center")
|
|
3776
3776
|
};
|
|
3777
|
+
case "myclaude":
|
|
3778
|
+
return {
|
|
3779
|
+
icon: "\u25C9",
|
|
3780
|
+
title: t("menu:toolMode.myclaude.title", "myclaude Workspace"),
|
|
3781
|
+
summary: t("menu:toolMode.myclaude.summary", "Provider-first control center with explicit runtime status at startup."),
|
|
3782
|
+
focus: t("menu:toolMode.myclaude.focus", "Provider profiles, routing state, model slots, and Claude-family compatible configuration."),
|
|
3783
|
+
config: t("menu:toolMode.myclaude.config", "Primary config: ~/.claude.json (runtime) + ~/.ccjk/config.toml (reusable profiles)"),
|
|
3784
|
+
menuTitle: t("menu:toolMode.myclaude.menuTitle", "myclaude Control Center")
|
|
3785
|
+
};
|
|
3777
3786
|
case "codex":
|
|
3778
3787
|
return {
|
|
3779
3788
|
icon: "\u25C6",
|
|
@@ -3907,15 +3916,28 @@ function renderMenu(title, items, options = {}) {
|
|
|
3907
3916
|
lines.push(renderFooter(opts));
|
|
3908
3917
|
return lines.join("\n");
|
|
3909
3918
|
}
|
|
3910
|
-
function renderToolModeHero(codeTool, width = 76) {
|
|
3919
|
+
function renderToolModeHero(codeTool, width = 76, runtimeSummary) {
|
|
3911
3920
|
const meta = getToolModeMeta(codeTool);
|
|
3921
|
+
const content = [
|
|
3922
|
+
colors.itemText(meta.summary),
|
|
3923
|
+
`${colors.shortcut("Focus")} ${colors.itemText(meta.focus)}`,
|
|
3924
|
+
`${colors.shortcut("Config")} ${colors.itemText(meta.config)}`
|
|
3925
|
+
];
|
|
3926
|
+
if (runtimeSummary?.runtimeLabel) {
|
|
3927
|
+
content.push(`${colors.shortcut("Runtime")} ${colors.itemText(runtimeSummary.runtimeLabel)}`);
|
|
3928
|
+
}
|
|
3929
|
+
if (runtimeSummary?.profileLabel) {
|
|
3930
|
+
content.push(`${colors.shortcut("Profile")} ${colors.itemText(runtimeSummary.profileLabel)}`);
|
|
3931
|
+
}
|
|
3932
|
+
if (runtimeSummary?.routeLabel) {
|
|
3933
|
+
content.push(`${colors.shortcut("Route")} ${colors.itemText(runtimeSummary.routeLabel)}`);
|
|
3934
|
+
}
|
|
3935
|
+
if (runtimeSummary?.modelLabel) {
|
|
3936
|
+
content.push(`${colors.shortcut("Models")} ${colors.itemText(runtimeSummary.modelLabel)}`);
|
|
3937
|
+
}
|
|
3912
3938
|
return renderBox(
|
|
3913
3939
|
`${meta.icon} ${meta.title}`,
|
|
3914
|
-
|
|
3915
|
-
colors.itemText(meta.summary),
|
|
3916
|
-
`${colors.shortcut("Focus")} ${colors.itemText(meta.focus)}`,
|
|
3917
|
-
`${colors.shortcut("Config")} ${colors.itemText(meta.config)}`
|
|
3918
|
-
],
|
|
3940
|
+
content,
|
|
3919
3941
|
width
|
|
3920
3942
|
);
|
|
3921
3943
|
}
|
|
@@ -4332,6 +4354,29 @@ function getProgressiveFooterCommands(codeTool) {
|
|
|
4332
4354
|
}
|
|
4333
4355
|
];
|
|
4334
4356
|
}
|
|
4357
|
+
function buildMyclaudeRuntimeSummary(syncResult) {
|
|
4358
|
+
if (!syncResult?.activeProfile) {
|
|
4359
|
+
return {
|
|
4360
|
+
runtimeLabel: "myclaude / no active provider synced"
|
|
4361
|
+
};
|
|
4362
|
+
}
|
|
4363
|
+
const profile = syncResult.activeProfile;
|
|
4364
|
+
const routeFamily = profile.baseUrl ? "OpenAI-compatible gateway" : "Official runtime route";
|
|
4365
|
+
const primaryModel = typeof profile.primaryModel === "string" ? profile.primaryModel : profile.model;
|
|
4366
|
+
const fastModel = typeof profile.defaultHaikuModel === "string" ? profile.defaultHaikuModel : profile.fastModel;
|
|
4367
|
+
const sonnetModel = typeof profile.defaultSonnetModel === "string" ? profile.defaultSonnetModel : void 0;
|
|
4368
|
+
const modelParts = [
|
|
4369
|
+
primaryModel ? `primary ${primaryModel}` : void 0,
|
|
4370
|
+
fastModel ? `fast ${fastModel}` : void 0,
|
|
4371
|
+
sonnetModel ? `exec ${sonnetModel}` : void 0
|
|
4372
|
+
].filter(Boolean);
|
|
4373
|
+
return {
|
|
4374
|
+
runtimeLabel: "myclaude",
|
|
4375
|
+
profileLabel: `${profile.name} (${syncResult.activeProfileId || profile.id})`,
|
|
4376
|
+
routeLabel: profile.baseUrl ? `${routeFamily} \xB7 ${profile.baseUrl}` : routeFamily,
|
|
4377
|
+
modelLabel: modelParts.join(" \xB7 ") || void 0
|
|
4378
|
+
};
|
|
4379
|
+
}
|
|
4335
4380
|
function getMenuShellConfig(codeTool) {
|
|
4336
4381
|
if (codeTool === "codex" || codeTool === "myclaude") {
|
|
4337
4382
|
return {
|
|
@@ -4348,7 +4393,7 @@ function getMenuShellConfig(codeTool) {
|
|
|
4348
4393
|
showHero: false
|
|
4349
4394
|
};
|
|
4350
4395
|
}
|
|
4351
|
-
async function showProgressiveMenu(codeTool) {
|
|
4396
|
+
async function showProgressiveMenu(codeTool, runtimeSyncResult) {
|
|
4352
4397
|
if (codeTool !== "codex" && codeTool !== "myclaude") {
|
|
4353
4398
|
const rawItems2 = getItemsForLevel(menuState.level, "claude-code");
|
|
4354
4399
|
const items2 = attachHandlers(rawItems2, "claude-code");
|
|
@@ -4438,7 +4483,7 @@ async function showProgressiveMenu(codeTool) {
|
|
|
4438
4483
|
const menuShell = getMenuShellConfig(codeTool);
|
|
4439
4484
|
const allowedCommands = ["0", "q", ...menuShell.allowMore ? ["m"] : [], ...menuShell.footerCommands.map((command) => command.key)];
|
|
4440
4485
|
if (menuShell.showHero) {
|
|
4441
|
-
console.log(renderToolModeHero(codeTool));
|
|
4486
|
+
console.log(renderToolModeHero(codeTool, 76, codeTool === "myclaude" ? buildMyclaudeRuntimeSummary(runtimeSyncResult) : void 0));
|
|
4442
4487
|
console.log("");
|
|
4443
4488
|
}
|
|
4444
4489
|
const menuOutput = renderMenu(
|
|
@@ -5214,6 +5259,7 @@ async function showMainMenu(options = {}) {
|
|
|
5214
5259
|
if (await isFirstTimeUser()) {
|
|
5215
5260
|
await runOnboardingWizard({ preferredCodeTool: options.codeType });
|
|
5216
5261
|
}
|
|
5262
|
+
let myclaudeRuntimeSyncResult = null;
|
|
5217
5263
|
try {
|
|
5218
5264
|
const previousType = getCurrentCodeTool();
|
|
5219
5265
|
const resolvedType = await resolveStartupCodeType({
|
|
@@ -5226,6 +5272,10 @@ async function showMainMenu(options = {}) {
|
|
|
5226
5272
|
console.log(a.green(`\u2714 Switched to ${resolvedType}`));
|
|
5227
5273
|
}
|
|
5228
5274
|
}
|
|
5275
|
+
if (resolvedType === "myclaude") {
|
|
5276
|
+
const { syncMyclaudeProviderProfilesFromCurrentClaudeConfig } = await import('./config.mjs').then(function (n) { return n.E; });
|
|
5277
|
+
myclaudeRuntimeSyncResult = syncMyclaudeProviderProfilesFromCurrentClaudeConfig();
|
|
5278
|
+
}
|
|
5229
5279
|
} catch (err) {
|
|
5230
5280
|
const errorMessage = err instanceof Error ? err.message : String(err);
|
|
5231
5281
|
console.error(a.yellow(errorMessage));
|
|
@@ -5234,7 +5284,11 @@ async function showMainMenu(options = {}) {
|
|
|
5234
5284
|
while (!exitMenu) {
|
|
5235
5285
|
const codeTool = getCurrentCodeTool();
|
|
5236
5286
|
displayBannerWithInfo(CODE_TOOL_BANNERS[codeTool] || "CCJK");
|
|
5237
|
-
|
|
5287
|
+
if (codeTool === "myclaude") {
|
|
5288
|
+
const { syncMyclaudeProviderProfilesFromCurrentClaudeConfig } = await import('./config.mjs').then(function (n) { return n.E; });
|
|
5289
|
+
myclaudeRuntimeSyncResult = syncMyclaudeProviderProfilesFromCurrentClaudeConfig();
|
|
5290
|
+
}
|
|
5291
|
+
const result = await showProgressiveMenu(codeTool, myclaudeRuntimeSyncResult);
|
|
5238
5292
|
if (result === "exit") {
|
|
5239
5293
|
exitMenu = true;
|
|
5240
5294
|
} else if (result === "switch") {
|
package/dist/chunks/init.mjs
CHANGED
|
@@ -12,14 +12,13 @@ import { exec } from 'node:child_process';
|
|
|
12
12
|
import { promisify } from 'node:util';
|
|
13
13
|
import { updateCcr } from './auto-updater.mjs';
|
|
14
14
|
import { w as wrapCommandWithSudo, i as isWindows, b as isTermux } from './platform.mjs';
|
|
15
|
-
import {
|
|
15
|
+
import { v as setMyclaudeProviderProfiles, p as promptApiConfigurationAction, n as addCompletedOnboarding, l as setPrimaryApiKey, x as ensureClaudeDir, y as clearMyclaudeProviderProfiles, h as getExistingApiConfig, q as switchToOfficialLogin, b as backupExistingConfig, k as copyConfigFiles, t as applyAiLanguageDirective, i as configureApi, d as backupMcpConfig, e as buildMcpServerConfig, r as readMcpConfig, z as replaceMcpServers, f as fixWindowsMcpConfig, w as writeMcpConfig, A as syncMcpPermissions } from './config.mjs';
|
|
16
16
|
import { h as runCodexFullInit } from './codex.mjs';
|
|
17
17
|
import { a as resolveStartupCodeType, r as resolveCodeType } from '../shared/ccjk.yYQMbHH3.mjs';
|
|
18
18
|
import { exists } from './fs-operations.mjs';
|
|
19
19
|
import { readJsonConfig, writeJsonConfig } from './json-config.mjs';
|
|
20
|
-
import { p as promptApiConfigurationAction, i as ensureClaudeDir, d as getExistingApiConfig, s as switchToOfficialLogin, b as backupExistingConfig, f as copyConfigFiles, h as applyAiLanguageDirective, e as configureApi } from './config.mjs';
|
|
21
20
|
import { n as needsMigration, m as migrateSettingsForTokenRetrieval, d as displayMigrationResult, p as promptMigration } from '../shared/ccjk.DDq2hqA5.mjs';
|
|
22
|
-
import { m as modifyApiConfigPartially, a as configureApiCompletely, c as configureOutputStyle, f as formatApiKeyDisplay } from '../shared/ccjk.
|
|
21
|
+
import { m as modifyApiConfigPartially, a as configureApiCompletely, c as configureOutputStyle, f as formatApiKeyDisplay } from '../shared/ccjk.Dh6Be-ef.mjs';
|
|
23
22
|
import { a as handleExitPromptError, h as handleGeneralError } from '../shared/ccjk.DGllfVCZ.mjs';
|
|
24
23
|
import { getInstallationStatus, installMyclaude, installClaudeCode } from './installer.mjs';
|
|
25
24
|
import { s as selectMcpServices } from '../shared/ccjk.BI-hdI7P.mjs';
|
|
@@ -770,7 +769,7 @@ async function validateApiConfigs(configs) {
|
|
|
770
769
|
}
|
|
771
770
|
}
|
|
772
771
|
async function handleClaudeCodeConfigs(configs) {
|
|
773
|
-
const { ClaudeCodeConfigManager } = await import('./
|
|
772
|
+
const { ClaudeCodeConfigManager } = await import('./config.mjs').then(function (n) { return n.D; });
|
|
774
773
|
const addedProfiles = [];
|
|
775
774
|
for (const config of configs) {
|
|
776
775
|
if (config.type === "ccr_proxy") {
|
|
@@ -861,7 +860,7 @@ async function handleCodexConfigs(configs) {
|
|
|
861
860
|
}
|
|
862
861
|
async function saveSingleConfigToToml(apiConfig, provider, options) {
|
|
863
862
|
try {
|
|
864
|
-
const { ClaudeCodeConfigManager } = await import('./
|
|
863
|
+
const { ClaudeCodeConfigManager } = await import('./config.mjs').then(function (n) { return n.D; });
|
|
865
864
|
const profile = await convertSingleConfigToProfile(apiConfig, provider, options);
|
|
866
865
|
const result = await ClaudeCodeConfigManager.addProfile(profile);
|
|
867
866
|
if (result.success) {
|
|
@@ -887,7 +886,7 @@ async function saveSingleConfigToToml(apiConfig, provider, options) {
|
|
|
887
886
|
}
|
|
888
887
|
}
|
|
889
888
|
async function buildClaudeCodeProfile(params) {
|
|
890
|
-
const { ClaudeCodeConfigManager } = await import('./
|
|
889
|
+
const { ClaudeCodeConfigManager } = await import('./config.mjs').then(function (n) { return n.D; });
|
|
891
890
|
let {
|
|
892
891
|
url: baseUrl,
|
|
893
892
|
authType,
|
|
@@ -1509,7 +1508,7 @@ async function init(options = {}) {
|
|
|
1509
1508
|
const hasModelParams = options.apiModel || options.apiHaikuModel || options.apiSonnetModel || options.apiOpusModel;
|
|
1510
1509
|
if (hasModelParams && action !== "docs-only" && (codeToolType === "claude-code" || codeToolType === "myclaude")) {
|
|
1511
1510
|
if (options.skipPrompt) {
|
|
1512
|
-
const { updateCustomModel } = await import('./config.mjs').then(function (n) { return n.
|
|
1511
|
+
const { updateCustomModel } = await import('./config.mjs').then(function (n) { return n.B; });
|
|
1513
1512
|
updateCustomModel(
|
|
1514
1513
|
options.apiModel || void 0,
|
|
1515
1514
|
options.apiHaikuModel || void 0,
|
|
@@ -224,7 +224,7 @@ async function getInstallationStatus(codeType = "claude-code") {
|
|
|
224
224
|
async function getInstallMethodFromConfig(codeType) {
|
|
225
225
|
try {
|
|
226
226
|
if (isClaudeFamilyCodeTool(codeType)) {
|
|
227
|
-
const { readMcpConfig } = await import('./
|
|
227
|
+
const { readMcpConfig } = await import('./config.mjs').then(function (n) { return n.E; });
|
|
228
228
|
const config = readMcpConfig();
|
|
229
229
|
return config?.installMethod || null;
|
|
230
230
|
}
|
|
@@ -348,7 +348,7 @@ async function uninstallCodeTool(codeType) {
|
|
|
348
348
|
async function setInstallMethod(method, codeType = "claude-code") {
|
|
349
349
|
try {
|
|
350
350
|
if (isClaudeFamilyCodeTool(codeType)) {
|
|
351
|
-
const { readMcpConfig, writeMcpConfig } = await import('./
|
|
351
|
+
const { readMcpConfig, writeMcpConfig } = await import('./config.mjs').then(function (n) { return n.E; });
|
|
352
352
|
let config = readMcpConfig();
|
|
353
353
|
if (!config) {
|
|
354
354
|
config = { mcpServers: {} };
|
package/dist/chunks/mcp-cli.mjs
CHANGED
|
@@ -1,28 +1,17 @@
|
|
|
1
1
|
import a from './index5.mjs';
|
|
2
2
|
import { g as getMcpServices } from '../shared/ccjk.DKXs7Fbm.mjs';
|
|
3
3
|
import { i18n } from './index2.mjs';
|
|
4
|
-
import { r as readMcpConfig } from './
|
|
5
|
-
import { i as installMcpService, u as uninstallMcpService } from '../shared/ccjk.
|
|
4
|
+
import { r as readMcpConfig } from './config.mjs';
|
|
5
|
+
import { i as installMcpService, u as uninstallMcpService } from '../shared/ccjk.B6VCKdyy.mjs';
|
|
6
6
|
import '../shared/ccjk.BAGoDD49.mjs';
|
|
7
7
|
import 'node:child_process';
|
|
8
8
|
import 'node:process';
|
|
9
9
|
import 'node:fs';
|
|
10
10
|
import 'node:url';
|
|
11
11
|
import '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
12
|
-
import './constants.mjs';
|
|
13
|
-
import 'node:os';
|
|
14
|
-
import './json-config.mjs';
|
|
15
12
|
import '../shared/ccjk.RyizuzOI.mjs';
|
|
16
|
-
import './fs-operations.mjs';
|
|
17
|
-
import 'node:crypto';
|
|
18
|
-
import 'node:fs/promises';
|
|
19
|
-
import './platform.mjs';
|
|
20
|
-
import './main.mjs';
|
|
21
|
-
import 'module';
|
|
22
|
-
import 'node:path';
|
|
23
|
-
import 'node:stream';
|
|
24
|
-
import 'node:readline';
|
|
25
13
|
import './index6.mjs';
|
|
14
|
+
import 'node:readline';
|
|
26
15
|
import 'stream';
|
|
27
16
|
import 'node:tty';
|
|
28
17
|
import 'node:async_hooks';
|
|
@@ -31,17 +20,27 @@ import 'node:util';
|
|
|
31
20
|
import 'tty';
|
|
32
21
|
import 'fs';
|
|
33
22
|
import 'child_process';
|
|
23
|
+
import 'node:path';
|
|
24
|
+
import 'node:os';
|
|
25
|
+
import 'node:crypto';
|
|
34
26
|
import 'buffer';
|
|
35
27
|
import 'string_decoder';
|
|
28
|
+
import './constants.mjs';
|
|
29
|
+
import './json-config.mjs';
|
|
30
|
+
import './fs-operations.mjs';
|
|
31
|
+
import 'node:fs/promises';
|
|
32
|
+
import './platform.mjs';
|
|
33
|
+
import './main.mjs';
|
|
34
|
+
import 'module';
|
|
35
|
+
import 'node:stream';
|
|
36
|
+
import '../shared/ccjk.DScm_NnL.mjs';
|
|
37
|
+
import './ccjk-config.mjs';
|
|
38
|
+
import '../shared/ccjk.BBtCGd_g.mjs';
|
|
39
|
+
import './index3.mjs';
|
|
36
40
|
import './codex.mjs';
|
|
37
41
|
import './index8.mjs';
|
|
38
42
|
import '../shared/ccjk.DeWpAShp.mjs';
|
|
39
43
|
import '../shared/ccjk.CxpGa6MC.mjs';
|
|
40
|
-
import '../shared/ccjk.BBtCGd_g.mjs';
|
|
41
|
-
import './ccjk-config.mjs';
|
|
42
|
-
import './index3.mjs';
|
|
43
|
-
import './config.mjs';
|
|
44
|
-
import '../shared/ccjk.DScm_NnL.mjs';
|
|
45
44
|
import '../shared/ccjk.BFQ7yr5S.mjs';
|
|
46
45
|
import './prompts.mjs';
|
|
47
46
|
import '../shared/ccjk.gDEDGD_t.mjs';
|
package/dist/chunks/mcp.mjs
CHANGED
|
@@ -5,11 +5,11 @@ import { readZcfConfig } from './ccjk-config.mjs';
|
|
|
5
5
|
import 'node:child_process';
|
|
6
6
|
import 'node:process';
|
|
7
7
|
import { M as MCP_SERVICE_TIERS, i as isCoreService, g as getServicesByTier, c as checkMcpPerformance, f as formatPerformanceWarning, a as calculateResourceUsage, b as getOptimizationSuggestions, d as getMcpTierConfig } from './mcp-performance.mjs';
|
|
8
|
-
import { r as readMcpConfig,
|
|
9
|
-
export { m as mcpInstall, a as mcpList, b as mcpSearch, c as mcpUninstall } from '../shared/ccjk.
|
|
8
|
+
import { r as readMcpConfig, d as backupMcpConfig, w as writeMcpConfig } from './config.mjs';
|
|
9
|
+
export { m as mcpInstall, a as mcpList, b as mcpSearch, c as mcpUninstall } from '../shared/ccjk.CVjfbEIj.mjs';
|
|
10
10
|
import { M as MCP_SERVICE_CONFIGS } from '../shared/ccjk.DKXs7Fbm.mjs';
|
|
11
11
|
import { r as readCodexConfig, e as backupCodexComplete, w as writeCodexConfig, g as applyCodexPlatformCommand } from './codex.mjs';
|
|
12
|
-
import { i as isWindows,
|
|
12
|
+
import { i as isWindows, l as getSystemRoot } from './platform.mjs';
|
|
13
13
|
import '../shared/ccjk.BAGoDD49.mjs';
|
|
14
14
|
import 'node:os';
|
|
15
15
|
import '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
@@ -35,15 +35,14 @@ import 'child_process';
|
|
|
35
35
|
import 'node:path';
|
|
36
36
|
import 'buffer';
|
|
37
37
|
import 'string_decoder';
|
|
38
|
-
import '../shared/ccjk.
|
|
38
|
+
import '../shared/ccjk.DScm_NnL.mjs';
|
|
39
|
+
import '../shared/ccjk.B6VCKdyy.mjs';
|
|
39
40
|
import './index8.mjs';
|
|
40
41
|
import '../shared/ccjk.DeWpAShp.mjs';
|
|
41
42
|
import '../shared/ccjk.CxpGa6MC.mjs';
|
|
42
43
|
import './main.mjs';
|
|
43
44
|
import 'module';
|
|
44
45
|
import 'node:stream';
|
|
45
|
-
import './config.mjs';
|
|
46
|
-
import '../shared/ccjk.DScm_NnL.mjs';
|
|
47
46
|
import '../shared/ccjk.BFQ7yr5S.mjs';
|
|
48
47
|
import './prompts.mjs';
|
|
49
48
|
import '../shared/ccjk.gDEDGD_t.mjs';
|
|
@@ -576,7 +575,7 @@ function getServiceTier(serviceId, tiers) {
|
|
|
576
575
|
return caseInsensitiveMatch?.[1] || "ondemand";
|
|
577
576
|
}
|
|
578
577
|
async function mcpStatus(options = {}) {
|
|
579
|
-
const { readMcpConfig } = await import('./
|
|
578
|
+
const { readMcpConfig } = await import('./config.mjs').then(function (n) { return n.E; });
|
|
580
579
|
const { readCodexConfig } = await import('./codex.mjs').then(function (n) { return n.q; });
|
|
581
580
|
const { checkMcpPerformance, formatPerformanceWarning } = await import('./mcp-performance.mjs').then(function (n) { return n.e; });
|
|
582
581
|
const { MCP_SERVICE_TIERS } = await import('./mcp-performance.mjs').then(function (n) { return n.m; });
|
package/dist/chunks/package.mjs
CHANGED
package/dist/chunks/platform.mjs
CHANGED
|
@@ -392,4 +392,4 @@ const platform = {
|
|
|
392
392
|
wrapCommandWithSudo: wrapCommandWithSudo
|
|
393
393
|
};
|
|
394
394
|
|
|
395
|
-
export { getHomebrewCommandPaths as a, isTermux as b, getTermuxPrefix as c, isWSL as d, getWSLInfo as e, findCommandPath as f, getPlatform as g, commandExists as h, isWindows as i, getRecommendedInstallMethods as j, findRealCommandPath as k,
|
|
395
|
+
export { getHomebrewCommandPaths as a, isTermux as b, getTermuxPrefix as c, isWSL as d, getWSLInfo as e, findCommandPath as f, getPlatform as g, commandExists as h, isWindows as i, getRecommendedInstallMethods as j, findRealCommandPath as k, getSystemRoot as l, getMcpCommand as m, normalizeTomlPath as n, platform as p, shouldUseSudoForGlobalInstall as s, wrapCommandWithSudo as w };
|
|
@@ -40,7 +40,6 @@ import './index3.mjs';
|
|
|
40
40
|
import '../shared/ccjk.DKXs7Fbm.mjs';
|
|
41
41
|
import './banner.mjs';
|
|
42
42
|
import './config2.mjs';
|
|
43
|
-
import './claude-config.mjs';
|
|
44
43
|
import './config.mjs';
|
|
45
44
|
import '../shared/ccjk.DScm_NnL.mjs';
|
|
46
45
|
import '../shared/ccjk.DZ2LLOa-.mjs';
|
|
@@ -54,7 +53,7 @@ import '../shared/ccjk.BFQ7yr5S.mjs';
|
|
|
54
53
|
import './prompts.mjs';
|
|
55
54
|
import '../shared/ccjk.yYQMbHH3.mjs';
|
|
56
55
|
import '../shared/ccjk.DDq2hqA5.mjs';
|
|
57
|
-
import '../shared/ccjk.
|
|
56
|
+
import '../shared/ccjk.Dh6Be-ef.mjs';
|
|
58
57
|
import '../shared/ccjk.DGllfVCZ.mjs';
|
|
59
58
|
import './installer.mjs';
|
|
60
59
|
import '../shared/ccjk.BI-hdI7P.mjs';
|
|
@@ -122,7 +122,7 @@ function getSlashCommands() {
|
|
|
122
122
|
descriptionZh: "\u521B\u5EFA\u914D\u7F6E\u5907\u4EFD",
|
|
123
123
|
category: "system",
|
|
124
124
|
handler: async () => {
|
|
125
|
-
const { backupExistingConfig } = await import('./config.mjs').then(function (n) { return n.
|
|
125
|
+
const { backupExistingConfig } = await import('./config.mjs').then(function (n) { return n.B; });
|
|
126
126
|
const backupPath = backupExistingConfig();
|
|
127
127
|
if (backupPath) {
|
|
128
128
|
console.log(a.green(`\u2705 Backup created: ${backupPath}`));
|
package/dist/chunks/update.mjs
CHANGED
|
@@ -6,13 +6,12 @@ import { SETTINGS_FILE, DEFAULT_CODE_TOOL_TYPE, resolveCodeToolType as resolveCo
|
|
|
6
6
|
import { i18n } from './index2.mjs';
|
|
7
7
|
import { displayBanner } from './banner.mjs';
|
|
8
8
|
import { readZcfConfig, updateZcfConfig } from './ccjk-config.mjs';
|
|
9
|
-
import { r as readMcpConfig } from './
|
|
9
|
+
import { k as copyConfigFiles, r as readMcpConfig } from './config.mjs';
|
|
10
10
|
import { c as runCodexUpdate } from './codex.mjs';
|
|
11
|
-
import { f as copyConfigFiles } from './config.mjs';
|
|
12
11
|
import { n as needsMigration, m as migrateSettingsForTokenRetrieval, d as displayMigrationResult, p as promptMigration } from '../shared/ccjk.DDq2hqA5.mjs';
|
|
13
|
-
import { u as updatePromptOnly } from '../shared/ccjk.
|
|
12
|
+
import { u as updatePromptOnly } from '../shared/ccjk.Dh6Be-ef.mjs';
|
|
14
13
|
import { a as handleExitPromptError, h as handleGeneralError } from '../shared/ccjk.DGllfVCZ.mjs';
|
|
15
|
-
import { a as installMcpServices } from '../shared/ccjk.
|
|
14
|
+
import { a as installMcpServices } from '../shared/ccjk.B6VCKdyy.mjs';
|
|
16
15
|
import { resolveAiOutputLanguage } from './prompts.mjs';
|
|
17
16
|
import { g as getRuntimeVersion } from '../shared/ccjk.gDEDGD_t.mjs';
|
|
18
17
|
import { checkClaudeCodeVersionAndPrompt } from './version-checker.mjs';
|
|
@@ -46,12 +45,12 @@ import './platform.mjs';
|
|
|
46
45
|
import './main.mjs';
|
|
47
46
|
import 'module';
|
|
48
47
|
import 'node:stream';
|
|
48
|
+
import '../shared/ccjk.DScm_NnL.mjs';
|
|
49
49
|
import './index8.mjs';
|
|
50
50
|
import '../shared/ccjk.DeWpAShp.mjs';
|
|
51
51
|
import '../shared/ccjk.CxpGa6MC.mjs';
|
|
52
52
|
import '../shared/ccjk.BFQ7yr5S.mjs';
|
|
53
53
|
import '../shared/ccjk.DZ2LLOa-.mjs';
|
|
54
|
-
import '../shared/ccjk.DScm_NnL.mjs';
|
|
55
54
|
|
|
56
55
|
const ccjkVersion = getRuntimeVersion();
|
|
57
56
|
function resolveCodeToolType(optionValue, savedValue) {
|
|
@@ -144,6 +144,13 @@
|
|
|
144
144
|
"config": "Primary config: ~/.claude/settings.json",
|
|
145
145
|
"menuTitle": "Claude Control Center"
|
|
146
146
|
},
|
|
147
|
+
"myclaude": {
|
|
148
|
+
"title": "myclaude Workspace",
|
|
149
|
+
"summary": "Provider-first control center with explicit runtime status at startup.",
|
|
150
|
+
"focus": "Provider profiles, routing state, model slots, and Claude-family compatible configuration.",
|
|
151
|
+
"config": "Primary config: ~/.claude.json (runtime) + ~/.ccjk/config.toml (reusable profiles)",
|
|
152
|
+
"menuTitle": "myclaude Control Center"
|
|
153
|
+
},
|
|
147
154
|
"codex": {
|
|
148
155
|
"title": "Codex Workspace",
|
|
149
156
|
"summary": "Lean setup focused on provider wiring, prompts, MCP, and memory.",
|