ccjk 12.0.0 → 12.0.2
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/agent-teams.mjs +17 -18
- package/dist/chunks/agent.mjs +105 -102
- package/dist/chunks/agents.mjs +87 -77
- package/dist/chunks/api-cli.mjs +41 -27
- package/dist/chunks/api-providers.mjs +2 -4
- package/dist/chunks/api.mjs +22 -11
- package/dist/chunks/auto-bootstrap.mjs +3 -5
- package/dist/chunks/auto-init.mjs +3 -4
- package/dist/chunks/auto-updater.mjs +103 -91
- package/dist/chunks/banner.mjs +41 -42
- package/dist/chunks/boost.mjs +30 -31
- package/dist/chunks/ccjk-agents.mjs +6 -9
- package/dist/chunks/ccjk-all.mjs +703 -85
- package/dist/chunks/ccjk-config.mjs +6 -6
- package/dist/chunks/ccjk-hooks.mjs +20 -9
- package/dist/chunks/ccjk-mcp.mjs +64 -52
- package/dist/chunks/ccjk-setup.mjs +35 -25
- package/dist/chunks/ccjk-skills.mjs +51 -41
- package/dist/chunks/ccr.mjs +42 -32
- package/dist/chunks/ccu.mjs +16 -12
- package/dist/chunks/check-updates.mjs +30 -19
- package/dist/chunks/claude-code-config-manager.mjs +25 -10
- package/dist/chunks/claude-code-incremental-manager.mjs +65 -51
- package/dist/chunks/claude-config.mjs +2 -2
- package/dist/chunks/claude-wrapper.mjs +9 -6
- package/dist/chunks/cleanup-migration.mjs +1 -1
- package/dist/chunks/cli-hook.mjs +10 -3
- package/dist/chunks/cloud-sync.mjs +1 -1
- package/dist/chunks/codex-config-switch.mjs +58 -45
- package/dist/chunks/codex-provider-manager.mjs +29 -16
- package/dist/chunks/codex-uninstaller.mjs +5 -6
- package/dist/chunks/codex.mjs +89 -89
- package/dist/chunks/commands.mjs +28 -29
- package/dist/chunks/commands2.mjs +4 -3
- package/dist/chunks/commit.mjs +42 -23
- package/dist/chunks/completion.mjs +46 -47
- package/dist/chunks/config-consolidator.mjs +12 -13
- package/dist/chunks/config-switch.mjs +66 -53
- package/dist/chunks/config.mjs +10 -10
- package/dist/chunks/config2.mjs +53 -42
- package/dist/chunks/config3.mjs +107 -93
- package/dist/chunks/constants.mjs +2 -4
- package/dist/chunks/context-loader.mjs +5 -4
- package/dist/chunks/context.mjs +77 -76
- package/dist/chunks/convoy-manager.mjs +4 -4
- package/dist/chunks/dashboard.mjs +28 -29
- package/dist/chunks/doctor.mjs +68 -54
- package/dist/chunks/evolution.mjs +37 -38
- package/dist/chunks/features.mjs +103 -92
- package/dist/chunks/fs-operations.mjs +1 -1
- package/dist/chunks/health-alerts.mjs +1 -1
- package/dist/chunks/health-check.mjs +1 -1
- package/dist/chunks/help.mjs +117 -116
- package/dist/chunks/hook-installer.mjs +3 -2
- package/dist/chunks/index.mjs +20 -6
- package/dist/chunks/index10.mjs +1171 -0
- package/dist/chunks/index11.mjs +1008 -0
- package/dist/chunks/index12.mjs +193 -0
- package/dist/chunks/index13.mjs +218 -0
- package/dist/chunks/index14.mjs +663 -0
- package/dist/chunks/index2.mjs +19 -10
- package/dist/chunks/index3.mjs +19079 -164
- package/dist/chunks/index4.mjs +8 -1171
- package/dist/chunks/index5.mjs +7479 -884
- package/dist/chunks/index6.mjs +160 -184
- package/dist/chunks/index7.mjs +3573 -653
- package/dist/chunks/index8.mjs +19 -0
- package/dist/chunks/index9.mjs +616 -0
- package/dist/chunks/init.mjs +173 -173
- package/dist/chunks/installer.mjs +92 -82
- package/dist/chunks/installer2.mjs +3 -2
- package/dist/chunks/interview.mjs +118 -107
- package/dist/chunks/json-config.mjs +3 -2
- package/dist/chunks/linux.mjs +3863 -0
- package/dist/chunks/macos.mjs +69 -0
- package/dist/chunks/main.mjs +635 -0
- package/dist/chunks/marketplace.mjs +69 -66
- package/dist/chunks/mcp-cli.mjs +61 -48
- package/dist/chunks/mcp.mjs +140 -127
- package/dist/chunks/menu.mjs +85 -85
- package/dist/chunks/metrics-display.mjs +41 -40
- package/dist/chunks/migrator.mjs +4 -5
- package/dist/chunks/monitor.mjs +95 -95
- package/dist/chunks/notification.mjs +151 -141
- package/dist/chunks/onboarding.mjs +26 -15
- package/dist/chunks/package.mjs +1 -1
- package/dist/chunks/paradigm.mjs +24 -23
- package/dist/chunks/permission-manager.mjs +10 -11
- package/dist/chunks/permissions.mjs +72 -57
- package/dist/chunks/persistence-manager.mjs +97 -84
- package/dist/chunks/persistence.mjs +1 -1
- package/dist/chunks/platform.mjs +29 -29
- package/dist/chunks/plugin.mjs +104 -105
- package/dist/chunks/prompts.mjs +36 -25
- package/dist/chunks/providers.mjs +68 -69
- package/dist/chunks/quick-actions.mjs +71 -72
- package/dist/chunks/quick-provider.mjs +56 -40
- package/dist/chunks/quick-setup.mjs +71 -60
- package/dist/chunks/remote.mjs +21 -12
- package/dist/chunks/session.mjs +116 -103
- package/dist/chunks/sessions.mjs +29 -28
- package/dist/chunks/silent-updater.mjs +8 -10
- package/dist/chunks/simple-config.mjs +13 -10
- package/dist/chunks/skill.mjs +8560 -103
- package/dist/chunks/skills-sync.mjs +5212 -79
- package/dist/chunks/skills.mjs +105 -94
- package/dist/chunks/slash-commands.mjs +36 -37
- package/dist/chunks/smart-defaults.mjs +7 -3
- package/dist/chunks/smart-guide.mjs +1 -1
- package/dist/chunks/startup.mjs +2 -4
- package/dist/chunks/stats.mjs +41 -42
- package/dist/chunks/status.mjs +49 -50
- package/dist/chunks/team.mjs +24 -12
- package/dist/chunks/thinking.mjs +74 -63
- package/dist/chunks/trace.mjs +20 -19
- package/dist/chunks/uninstall.mjs +69 -56
- package/dist/chunks/update.mjs +39 -28
- package/dist/chunks/upgrade-manager.mjs +24 -18
- package/dist/chunks/version-checker.mjs +45 -41
- package/dist/chunks/vim.mjs +81 -69
- package/dist/chunks/windows.mjs +14 -0
- package/dist/chunks/workflows.mjs +15 -15
- package/dist/chunks/wsl.mjs +129 -0
- package/dist/chunks/zero-config.mjs +45 -34
- package/dist/cli.mjs +20 -20
- package/dist/index.mjs +41 -31
- package/dist/shared/ccjk.BAGoDD49.mjs +36 -0
- package/dist/shared/ccjk.BBtCGd_g.mjs +899 -0
- package/dist/shared/{ccjk.CGcy7cNM.mjs → ccjk.BDKUdmLk.mjs} +1 -1
- package/dist/shared/{ccjk.DtMBiwVG.mjs → ccjk.BFxsJM0k.mjs} +1 -1
- package/dist/shared/{ccjk.j4uut26D.mjs → ccjk.BIxuVL3_.mjs} +5 -5
- package/dist/shared/ccjk.BRZ9ww8S.mjs +142 -0
- package/dist/shared/{ccjk.CN0edl87.mjs → ccjk.BSYWk9ML.mjs} +1 -1
- package/dist/shared/{ccjk.Dk1HDseQ.mjs → ccjk.BnpWvs9V.mjs} +75 -75
- package/dist/shared/ccjk.BoApaI4j.mjs +28 -0
- package/dist/shared/{ccjk.DKojSRzw.mjs → ccjk.BrPUmTqm.mjs} +1 -1
- package/dist/shared/{ccjk.C10pepYx.mjs → ccjk.BxSmJ8B7.mjs} +1 -1
- package/dist/shared/ccjk.Bx_rmYfN.mjs +69 -0
- package/dist/shared/ccjk.COweQ1RR.mjs +5 -0
- package/dist/shared/{ccjk.BN90X6oc.mjs → ccjk.CePkJq2S.mjs} +17 -17
- package/dist/shared/{ccjk.Bvoex4TZ.mjs → ccjk.CfKKcvWy.mjs} +1 -1
- package/dist/shared/ccjk.Cjgrln_h.mjs +297 -0
- package/dist/shared/ccjk.CxpGa6MC.mjs +2724 -0
- package/dist/shared/{ccjk.DfwJOEok.mjs → ccjk.D5MFQT7w.mjs} +1 -1
- package/dist/shared/{ccjk.cChAaGgT.mjs → ccjk.DG_o24cZ.mjs} +6 -6
- package/dist/shared/{ccjk.bhFAMRyc.mjs → ccjk.DLLw-h4Y.mjs} +32 -32
- package/dist/shared/ccjk.DOwtZMk8.mjs +4019 -0
- package/dist/shared/{ccjk.BsXQugfY.mjs → ccjk.DTdjs-qK.mjs} +13 -13
- package/dist/shared/{ccjk.Bdhyg3X-.mjs → ccjk.DsYaCCx4.mjs} +1 -1
- package/dist/shared/ccjk.KfSWcGlE.mjs +38 -0
- package/dist/shared/ccjk.RyizuzOI.mjs +21 -0
- package/dist/shared/{ccjk.h7_W-wTs.mjs → ccjk.SPoXMvZD.mjs} +1 -1
- package/dist/shared/ccjk.T_cX87dY.mjs +15 -0
- package/dist/shared/{ccjk.CrB6OYHv.mjs → ccjk._dESH4Rk.mjs} +2 -2
- package/dist/shared/ccjk.bQ7Dh1g4.mjs +249 -0
- package/dist/shared/{ccjk.CBhIZiPz.mjs → ccjk.hoqrwWdN.mjs} +1 -1
- package/dist/shared/{ccjk.BNwRnWYx.mjs → ccjk.s7OCVzdd.mjs} +1230 -33
- package/dist/shared/{ccjk.BOIUTf5z.mjs → ccjk.waa2ikKJ.mjs} +8 -9
- package/package.json +31 -30
- package/dist/shared/ccjk.DHbrGcgg.mjs +0 -13
- package/dist/shared/ccjk.DntgA8fQ.mjs +0 -42
|
@@ -1,31 +1,45 @@
|
|
|
1
|
-
import
|
|
2
|
-
import inquirer from '
|
|
3
|
-
import { ensureI18nInitialized, i18n } from './
|
|
1
|
+
import a from './index2.mjs';
|
|
2
|
+
import { i as inquirer } from './index3.mjs';
|
|
3
|
+
import { ensureI18nInitialized, i18n } from './index5.mjs';
|
|
4
4
|
import { ClaudeCodeConfigManager } from './claude-code-config-manager.mjs';
|
|
5
5
|
import { a as addNumbersToChoices } from '../shared/ccjk.BFQ7yr5S.mjs';
|
|
6
|
-
import { p as promptBoolean } from '../shared/ccjk.
|
|
7
|
-
import { v as validateApiKey } from '../shared/ccjk.
|
|
8
|
-
import '
|
|
6
|
+
import { p as promptBoolean } from '../shared/ccjk.DOwtZMk8.mjs';
|
|
7
|
+
import { v as validateApiKey } from '../shared/ccjk.BnpWvs9V.mjs';
|
|
8
|
+
import '../shared/ccjk.BAGoDD49.mjs';
|
|
9
|
+
import 'node:readline';
|
|
10
|
+
import 'stream';
|
|
11
|
+
import 'node:tty';
|
|
9
12
|
import 'node:process';
|
|
13
|
+
import 'node:async_hooks';
|
|
14
|
+
import '../shared/ccjk.Cjgrln_h.mjs';
|
|
15
|
+
import 'node:util';
|
|
16
|
+
import 'tty';
|
|
17
|
+
import 'fs';
|
|
18
|
+
import 'child_process';
|
|
19
|
+
import 'node:path';
|
|
20
|
+
import 'node:os';
|
|
21
|
+
import 'node:crypto';
|
|
22
|
+
import 'buffer';
|
|
23
|
+
import 'string_decoder';
|
|
24
|
+
import 'node:fs';
|
|
10
25
|
import 'node:url';
|
|
11
|
-
import '
|
|
12
|
-
import '
|
|
13
|
-
import 'pathe';
|
|
14
|
-
import 'dayjs';
|
|
26
|
+
import '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
27
|
+
import '../shared/ccjk.RyizuzOI.mjs';
|
|
15
28
|
import './constants.mjs';
|
|
16
|
-
import 'node:os';
|
|
17
29
|
import './ccjk-config.mjs';
|
|
18
|
-
import '
|
|
30
|
+
import '../shared/ccjk.BBtCGd_g.mjs';
|
|
31
|
+
import './index6.mjs';
|
|
19
32
|
import './fs-operations.mjs';
|
|
20
|
-
import 'node:crypto';
|
|
21
33
|
import 'node:fs/promises';
|
|
22
34
|
import './json-config.mjs';
|
|
23
35
|
import './config.mjs';
|
|
24
36
|
import './claude-config.mjs';
|
|
25
37
|
import './platform.mjs';
|
|
26
|
-
import '
|
|
38
|
+
import './main.mjs';
|
|
39
|
+
import 'module';
|
|
40
|
+
import 'node:child_process';
|
|
41
|
+
import 'node:stream';
|
|
27
42
|
import '../shared/ccjk.BiCrMV5O.mjs';
|
|
28
|
-
import 'inquirer-toggle';
|
|
29
43
|
|
|
30
44
|
function getAuthTypeLabel(authType) {
|
|
31
45
|
ensureI18nInitialized();
|
|
@@ -49,10 +63,10 @@ async function configureIncrementalManagement() {
|
|
|
49
63
|
}
|
|
50
64
|
const profiles = Object.values(config.profiles);
|
|
51
65
|
const currentProfile = config.currentProfileId ? config.profiles[config.currentProfileId] : null;
|
|
52
|
-
console.log(
|
|
53
|
-
console.log(
|
|
66
|
+
console.log(a.green(i18n.t("multi-config:incrementalManagementTitle")));
|
|
67
|
+
console.log(a.gray(i18n.t("multi-config:currentProfileCount", { count: profiles.length })));
|
|
54
68
|
if (currentProfile) {
|
|
55
|
-
console.log(
|
|
69
|
+
console.log(a.gray(i18n.t("multi-config:currentDefaultProfile", { profile: currentProfile.name })));
|
|
56
70
|
}
|
|
57
71
|
const choices = [
|
|
58
72
|
{ name: i18n.t("multi-config:addProfile"), value: "add" },
|
|
@@ -68,7 +82,7 @@ async function configureIncrementalManagement() {
|
|
|
68
82
|
choices: addNumbersToChoices(choices)
|
|
69
83
|
}]);
|
|
70
84
|
if (!action || action === "skip") {
|
|
71
|
-
console.log(
|
|
85
|
+
console.log(a.yellow(i18n.t("common:skip")));
|
|
72
86
|
return;
|
|
73
87
|
}
|
|
74
88
|
switch (action) {
|
|
@@ -93,7 +107,7 @@ async function promptContinueAdding() {
|
|
|
93
107
|
});
|
|
94
108
|
}
|
|
95
109
|
async function handleAddProfile() {
|
|
96
|
-
console.log(
|
|
110
|
+
console.log(a.green(`
|
|
97
111
|
${i18n.t("multi-config:addingNewProfile")}`));
|
|
98
112
|
const { getApiProviders } = await import('./api-providers.mjs');
|
|
99
113
|
const providers = getApiProviders("claude-code");
|
|
@@ -116,7 +130,7 @@ ${i18n.t("multi-config:addingNewProfile")}`));
|
|
|
116
130
|
prefilledBaseUrl = provider.claudeCode.baseUrl;
|
|
117
131
|
prefilledAuthType = provider.claudeCode.authType;
|
|
118
132
|
prefilledDefaultModels = provider.claudeCode.defaultModels;
|
|
119
|
-
console.log(
|
|
133
|
+
console.log(a.gray(i18n.t("api:providerSelected", { name: provider.name })));
|
|
120
134
|
}
|
|
121
135
|
}
|
|
122
136
|
const answers = await inquirer.prompt([
|
|
@@ -235,7 +249,7 @@ ${i18n.t("multi-config:addingNewProfile")}`));
|
|
|
235
249
|
defaultValue: false
|
|
236
250
|
});
|
|
237
251
|
if (!overwrite) {
|
|
238
|
-
console.log(
|
|
252
|
+
console.log(a.yellow(i18n.t("multi-config:profileDuplicateSkipped", { name: profile.name })));
|
|
239
253
|
const shouldContinue2 = await promptContinueAdding();
|
|
240
254
|
if (shouldContinue2) {
|
|
241
255
|
await handleAddProfile();
|
|
@@ -253,37 +267,37 @@ ${i18n.t("multi-config:addingNewProfile")}`));
|
|
|
253
267
|
defaultOpusModel: profile.defaultOpusModel
|
|
254
268
|
});
|
|
255
269
|
if (updateResult.success) {
|
|
256
|
-
console.log(
|
|
270
|
+
console.log(a.green(i18n.t("multi-config:profileUpdated", { name: profile.name })));
|
|
257
271
|
if (updateResult.backupPath) {
|
|
258
|
-
console.log(
|
|
272
|
+
console.log(a.gray(i18n.t("common:backupCreated", { path: updateResult.backupPath })));
|
|
259
273
|
}
|
|
260
274
|
if (setAsDefault) {
|
|
261
275
|
const switchResult = await ClaudeCodeConfigManager.switchProfile(existingProfile.id);
|
|
262
276
|
if (switchResult.success) {
|
|
263
|
-
console.log(
|
|
277
|
+
console.log(a.green(i18n.t("multi-config:profileSetAsDefault", { name: profile.name })));
|
|
264
278
|
await ClaudeCodeConfigManager.applyProfileSettings({ ...profile, id: existingProfile.id });
|
|
265
279
|
}
|
|
266
280
|
}
|
|
267
281
|
} else {
|
|
268
|
-
console.log(
|
|
282
|
+
console.log(a.red(i18n.t("multi-config:profileUpdateFailed", { error: updateResult.error || "" })));
|
|
269
283
|
}
|
|
270
284
|
} else {
|
|
271
285
|
const result = await ClaudeCodeConfigManager.addProfile(profile);
|
|
272
286
|
if (result.success) {
|
|
273
287
|
const runtimeProfile = result.addedProfile || { ...profile, id: profileId };
|
|
274
|
-
console.log(
|
|
288
|
+
console.log(a.green(i18n.t("multi-config:profileAdded", { name: runtimeProfile.name })));
|
|
275
289
|
if (result.backupPath) {
|
|
276
|
-
console.log(
|
|
290
|
+
console.log(a.gray(i18n.t("common:backupCreated", { path: result.backupPath })));
|
|
277
291
|
}
|
|
278
292
|
if (setAsDefault) {
|
|
279
293
|
const switchResult = await ClaudeCodeConfigManager.switchProfile(runtimeProfile.id);
|
|
280
294
|
if (switchResult.success) {
|
|
281
|
-
console.log(
|
|
295
|
+
console.log(a.green(i18n.t("multi-config:profileSetAsDefault", { name: runtimeProfile.name })));
|
|
282
296
|
await ClaudeCodeConfigManager.applyProfileSettings(runtimeProfile);
|
|
283
297
|
}
|
|
284
298
|
}
|
|
285
299
|
} else {
|
|
286
|
-
console.log(
|
|
300
|
+
console.log(a.red(i18n.t("multi-config:profileAddFailed", { error: result.error })));
|
|
287
301
|
}
|
|
288
302
|
}
|
|
289
303
|
const shouldContinue = await promptContinueAdding();
|
|
@@ -303,15 +317,15 @@ async function handleEditProfile(profiles) {
|
|
|
303
317
|
choices: addNumbersToChoices(choices)
|
|
304
318
|
}]);
|
|
305
319
|
if (!selectedProfileId) {
|
|
306
|
-
console.log(
|
|
320
|
+
console.log(a.yellow(i18n.t("common:cancelled")));
|
|
307
321
|
return;
|
|
308
322
|
}
|
|
309
323
|
const selectedProfile = profiles.find((p) => p.id === selectedProfileId);
|
|
310
324
|
if (!selectedProfile) {
|
|
311
|
-
console.log(
|
|
325
|
+
console.log(a.red(i18n.t("multi-config:profileNotFound")));
|
|
312
326
|
return;
|
|
313
327
|
}
|
|
314
|
-
console.log(
|
|
328
|
+
console.log(a.green(`
|
|
315
329
|
${i18n.t("multi-config:editingProfile", { name: selectedProfile.name })}`));
|
|
316
330
|
const answers = await inquirer.prompt([
|
|
317
331
|
{
|
|
@@ -398,20 +412,20 @@ ${i18n.t("multi-config:editingProfile", { name: selectedProfile.name })}`));
|
|
|
398
412
|
}
|
|
399
413
|
const result = await ClaudeCodeConfigManager.updateProfile(selectedProfile.id, updateData);
|
|
400
414
|
if (result.success) {
|
|
401
|
-
console.log(
|
|
415
|
+
console.log(a.green(i18n.t("multi-config:profileUpdated", { name: updateData.name })));
|
|
402
416
|
if (result.backupPath) {
|
|
403
|
-
console.log(
|
|
417
|
+
console.log(a.gray(i18n.t("common:backupCreated", { path: result.backupPath })));
|
|
404
418
|
}
|
|
405
419
|
const currentConfig = ClaudeCodeConfigManager.readConfig();
|
|
406
420
|
if (currentConfig?.currentProfileId === selectedProfile.id) {
|
|
407
421
|
const updatedProfile = ClaudeCodeConfigManager.getProfileById(selectedProfile.id);
|
|
408
422
|
if (updatedProfile) {
|
|
409
423
|
await ClaudeCodeConfigManager.applyProfileSettings(updatedProfile);
|
|
410
|
-
console.log(
|
|
424
|
+
console.log(a.green(i18n.t("multi-config:settingsApplied")));
|
|
411
425
|
}
|
|
412
426
|
}
|
|
413
427
|
} else {
|
|
414
|
-
console.log(
|
|
428
|
+
console.log(a.red(i18n.t("multi-config:profileUpdateFailed", { error: result.error })));
|
|
415
429
|
}
|
|
416
430
|
}
|
|
417
431
|
async function handleCopyProfile(profiles) {
|
|
@@ -426,15 +440,15 @@ async function handleCopyProfile(profiles) {
|
|
|
426
440
|
choices: addNumbersToChoices(choices)
|
|
427
441
|
}]);
|
|
428
442
|
if (!selectedProfileId) {
|
|
429
|
-
console.log(
|
|
443
|
+
console.log(a.yellow(i18n.t("common:cancelled")));
|
|
430
444
|
return;
|
|
431
445
|
}
|
|
432
446
|
const selectedProfile = profiles.find((p) => p.id === selectedProfileId);
|
|
433
447
|
if (!selectedProfile) {
|
|
434
|
-
console.log(
|
|
448
|
+
console.log(a.red(i18n.t("multi-config:profileNotFound")));
|
|
435
449
|
return;
|
|
436
450
|
}
|
|
437
|
-
console.log(
|
|
451
|
+
console.log(a.green(`
|
|
438
452
|
${i18n.t("multi-config:copyingProfile", { name: selectedProfile.name })}`));
|
|
439
453
|
const copiedName = `${selectedProfile.name}-copy`;
|
|
440
454
|
const questions = [
|
|
@@ -534,24 +548,24 @@ ${i18n.t("multi-config:copyingProfile", { name: selectedProfile.name })}`));
|
|
|
534
548
|
const result = await ClaudeCodeConfigManager.addProfile(copiedProfile);
|
|
535
549
|
if (result.success) {
|
|
536
550
|
const runtimeProfile = result.addedProfile || { ...copiedProfile, id: profileId };
|
|
537
|
-
console.log(
|
|
551
|
+
console.log(a.green(i18n.t("multi-config:profileCopied", { name: runtimeProfile.name })));
|
|
538
552
|
if (result.backupPath) {
|
|
539
|
-
console.log(
|
|
553
|
+
console.log(a.gray(i18n.t("common:backupCreated", { path: result.backupPath })));
|
|
540
554
|
}
|
|
541
555
|
if (setAsDefault) {
|
|
542
556
|
const switchResult = await ClaudeCodeConfigManager.switchProfile(runtimeProfile.id);
|
|
543
557
|
if (switchResult.success) {
|
|
544
|
-
console.log(
|
|
558
|
+
console.log(a.green(i18n.t("multi-config:profileSetAsDefault", { name: runtimeProfile.name })));
|
|
545
559
|
await ClaudeCodeConfigManager.applyProfileSettings(runtimeProfile);
|
|
546
560
|
}
|
|
547
561
|
}
|
|
548
562
|
} else {
|
|
549
|
-
console.log(
|
|
563
|
+
console.log(a.red(i18n.t("multi-config:profileCopyFailed", { error: result.error })));
|
|
550
564
|
}
|
|
551
565
|
}
|
|
552
566
|
async function handleDeleteProfile(profiles) {
|
|
553
567
|
if (profiles.length <= 1) {
|
|
554
|
-
console.log(
|
|
568
|
+
console.log(a.yellow(i18n.t("multi-config:cannotDeleteLast")));
|
|
555
569
|
return;
|
|
556
570
|
}
|
|
557
571
|
const choices = profiles.map((profile) => ({
|
|
@@ -574,7 +588,7 @@ async function handleDeleteProfile(profiles) {
|
|
|
574
588
|
}
|
|
575
589
|
});
|
|
576
590
|
if (!selectedProfileIds || selectedProfileIds.length === 0) {
|
|
577
|
-
console.log(
|
|
591
|
+
console.log(a.yellow(i18n.t("common:cancelled")));
|
|
578
592
|
return;
|
|
579
593
|
}
|
|
580
594
|
const selectedNames = selectedProfileIds.map(
|
|
@@ -585,24 +599,24 @@ async function handleDeleteProfile(profiles) {
|
|
|
585
599
|
defaultValue: false
|
|
586
600
|
});
|
|
587
601
|
if (!confirmed) {
|
|
588
|
-
console.log(
|
|
602
|
+
console.log(a.yellow(i18n.t("common:cancelled")));
|
|
589
603
|
return;
|
|
590
604
|
}
|
|
591
605
|
const result = await ClaudeCodeConfigManager.deleteProfiles(selectedProfileIds);
|
|
592
606
|
if (result.success) {
|
|
593
|
-
console.log(
|
|
607
|
+
console.log(a.green(i18n.t("multi-config:profilesDeleted", { count: selectedProfileIds.length })));
|
|
594
608
|
if (result.backupPath) {
|
|
595
|
-
console.log(
|
|
609
|
+
console.log(a.gray(i18n.t("common:backupCreated", { path: result.backupPath })));
|
|
596
610
|
}
|
|
597
611
|
if (result.newCurrentProfileId) {
|
|
598
612
|
const newProfile = ClaudeCodeConfigManager.getProfileById(result.newCurrentProfileId);
|
|
599
613
|
if (newProfile) {
|
|
600
|
-
console.log(
|
|
614
|
+
console.log(a.green(i18n.t("multi-config:newDefaultProfile", { profile: newProfile.name })));
|
|
601
615
|
await ClaudeCodeConfigManager.applyProfileSettings(newProfile);
|
|
602
616
|
}
|
|
603
617
|
}
|
|
604
618
|
} else {
|
|
605
|
-
console.log(
|
|
619
|
+
console.log(a.red(i18n.t("multi-config:profilesDeleteFailed", { error: result.error })));
|
|
606
620
|
}
|
|
607
621
|
}
|
|
608
622
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { existsSync, readFileSync } from 'node:fs';
|
|
2
|
-
import { join } from 'pathe';
|
|
3
2
|
import { CLAUDE_VSC_CONFIG_FILE, CLAUDE_DIR, ClAUDE_CONFIG_FILE } from './constants.mjs';
|
|
4
|
-
import { ensureI18nInitialized, i18n } from './
|
|
3
|
+
import { ensureI18nInitialized, i18n } from './index5.mjs';
|
|
5
4
|
import { readJsonConfig, writeJsonConfig, backupJsonConfig } from './json-config.mjs';
|
|
6
5
|
import { i as isWindows, m as getMcpCommand } from './platform.mjs';
|
|
6
|
+
import { j as join } from '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
7
7
|
|
|
8
8
|
function mergeArraysUnique(arr1, arr2) {
|
|
9
9
|
const combined = [...arr1 || [], ...arr2 || []];
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
import process__default from 'node:process';
|
|
2
|
-
import { exec } from '
|
|
3
|
-
import { i18n, initI18n } from './
|
|
2
|
+
import { exec as q } from './main.mjs';
|
|
3
|
+
import { i18n, initI18n } from './index5.mjs';
|
|
4
4
|
import { k as findRealCommandPath } from './platform.mjs';
|
|
5
|
+
import 'module';
|
|
6
|
+
import 'node:child_process';
|
|
7
|
+
import 'node:path';
|
|
8
|
+
import 'node:stream';
|
|
9
|
+
import 'node:readline';
|
|
5
10
|
import 'node:fs';
|
|
6
11
|
import 'node:url';
|
|
7
|
-
import '
|
|
8
|
-
import 'i18next-fs-backend';
|
|
9
|
-
import 'pathe';
|
|
12
|
+
import '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
10
13
|
import 'node:os';
|
|
11
14
|
|
|
12
15
|
const PASSTHROUGH_ARGS = /* @__PURE__ */ new Set([
|
|
@@ -55,7 +58,7 @@ async function claudeWrapper(args, options = {}) {
|
|
|
55
58
|
}
|
|
56
59
|
async function execClaudeDirect(claudePath, args) {
|
|
57
60
|
try {
|
|
58
|
-
const result = await
|
|
61
|
+
const result = await q(claudePath, args, {
|
|
59
62
|
nodeOptions: {
|
|
60
63
|
stdio: "inherit"
|
|
61
64
|
}
|
package/dist/chunks/cli-hook.mjs
CHANGED
|
@@ -1,10 +1,17 @@
|
|
|
1
1
|
import { EventEmitter } from 'node:events';
|
|
2
2
|
import { a as getGlobalStateManager, g as getGlobalConvoyManager } from './convoy-manager.mjs';
|
|
3
|
-
import { nanoid } from '
|
|
3
|
+
import { n as nanoid } from '../shared/ccjk.BoApaI4j.mjs';
|
|
4
4
|
import { existsSync, readFileSync, writeFileSync } from 'node:fs';
|
|
5
|
-
import { join } from '
|
|
5
|
+
import { j as join } from '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
6
6
|
import 'node:os';
|
|
7
|
-
import '
|
|
7
|
+
import './main.mjs';
|
|
8
|
+
import 'module';
|
|
9
|
+
import 'node:child_process';
|
|
10
|
+
import 'node:path';
|
|
11
|
+
import 'node:process';
|
|
12
|
+
import 'node:stream';
|
|
13
|
+
import 'node:readline';
|
|
14
|
+
import 'node:crypto';
|
|
8
15
|
|
|
9
16
|
class ProgressTracker extends EventEmitter {
|
|
10
17
|
config;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import 'node:fs';
|
|
2
2
|
import { writeFile } from 'node:fs/promises';
|
|
3
3
|
import { homedir } from 'node:os';
|
|
4
|
-
import { join } from '
|
|
4
|
+
import { j as join } from '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
5
5
|
|
|
6
6
|
function getCloudSyncConfigPath() {
|
|
7
7
|
return join(homedir(), ".claude", "superpowers-cloud-sync.json");
|
|
@@ -1,48 +1,61 @@
|
|
|
1
|
-
import
|
|
2
|
-
import inquirer from '
|
|
1
|
+
import a from './index2.mjs';
|
|
2
|
+
import { i as inquirer } from './index3.mjs';
|
|
3
3
|
import { CODEX_AUTH_FILE } from './constants.mjs';
|
|
4
|
-
import { ensureI18nInitialized, i18n } from './
|
|
4
|
+
import { ensureI18nInitialized, i18n } from './index5.mjs';
|
|
5
5
|
import { readJsonConfig } from './json-config.mjs';
|
|
6
6
|
import { a as addNumbersToChoices } from '../shared/ccjk.BFQ7yr5S.mjs';
|
|
7
|
-
import { p as promptBoolean } from '../shared/ccjk.
|
|
7
|
+
import { p as promptBoolean } from '../shared/ccjk.DOwtZMk8.mjs';
|
|
8
8
|
import { h as detectConfigManagementMode } from './codex.mjs';
|
|
9
9
|
import { deleteProviders, addProviderToExisting, editExistingProvider } from './codex-provider-manager.mjs';
|
|
10
|
+
import '../shared/ccjk.BAGoDD49.mjs';
|
|
11
|
+
import 'node:readline';
|
|
12
|
+
import 'stream';
|
|
13
|
+
import 'node:tty';
|
|
14
|
+
import 'node:process';
|
|
15
|
+
import 'node:async_hooks';
|
|
16
|
+
import '../shared/ccjk.Cjgrln_h.mjs';
|
|
17
|
+
import 'node:util';
|
|
18
|
+
import 'tty';
|
|
19
|
+
import 'fs';
|
|
20
|
+
import 'child_process';
|
|
21
|
+
import 'node:path';
|
|
10
22
|
import 'node:os';
|
|
11
|
-
import '
|
|
23
|
+
import 'node:crypto';
|
|
24
|
+
import 'buffer';
|
|
25
|
+
import 'string_decoder';
|
|
26
|
+
import '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
12
27
|
import 'node:fs';
|
|
13
|
-
import 'node:process';
|
|
14
28
|
import 'node:url';
|
|
15
|
-
import '
|
|
16
|
-
import 'i18next-fs-backend';
|
|
17
|
-
import 'dayjs';
|
|
29
|
+
import '../shared/ccjk.RyizuzOI.mjs';
|
|
18
30
|
import './fs-operations.mjs';
|
|
19
|
-
import 'node:crypto';
|
|
20
31
|
import 'node:fs/promises';
|
|
21
|
-
import '
|
|
22
|
-
import '
|
|
23
|
-
import '
|
|
24
|
-
import '
|
|
25
|
-
import '
|
|
32
|
+
import './index7.mjs';
|
|
33
|
+
import '../shared/ccjk.CxpGa6MC.mjs';
|
|
34
|
+
import '../shared/ccjk.BBtCGd_g.mjs';
|
|
35
|
+
import './main.mjs';
|
|
36
|
+
import 'module';
|
|
37
|
+
import 'node:child_process';
|
|
38
|
+
import 'node:stream';
|
|
26
39
|
import './ccjk-config.mjs';
|
|
40
|
+
import './index6.mjs';
|
|
27
41
|
import './config.mjs';
|
|
28
42
|
import './claude-config.mjs';
|
|
29
43
|
import './platform.mjs';
|
|
30
44
|
import '../shared/ccjk.BiCrMV5O.mjs';
|
|
31
45
|
import './prompts.mjs';
|
|
32
46
|
import './package.mjs';
|
|
33
|
-
import 'node:child_process';
|
|
34
47
|
|
|
35
48
|
async function configureIncrementalManagement() {
|
|
36
49
|
ensureI18nInitialized();
|
|
37
50
|
const managementMode = detectConfigManagementMode();
|
|
38
51
|
if (managementMode.mode !== "management" || !managementMode.hasProviders) {
|
|
39
|
-
console.log(
|
|
52
|
+
console.log(a.yellow(i18n.t("codex:noExistingProviders")));
|
|
40
53
|
return;
|
|
41
54
|
}
|
|
42
|
-
console.log(
|
|
43
|
-
console.log(
|
|
55
|
+
console.log(a.green(i18n.t("codex:incrementalManagementTitle")));
|
|
56
|
+
console.log(a.gray(i18n.t("codex:currentProviderCount", { count: managementMode.providerCount })));
|
|
44
57
|
if (managementMode.currentProvider) {
|
|
45
|
-
console.log(
|
|
58
|
+
console.log(a.gray(i18n.t("codex:currentDefaultProvider", { provider: managementMode.currentProvider })));
|
|
46
59
|
}
|
|
47
60
|
const choices = [
|
|
48
61
|
{ name: i18n.t("codex:addProvider"), value: "add" },
|
|
@@ -58,7 +71,7 @@ async function configureIncrementalManagement() {
|
|
|
58
71
|
choices: addNumbersToChoices(choices)
|
|
59
72
|
}]);
|
|
60
73
|
if (!action || action === "skip") {
|
|
61
|
-
console.log(
|
|
74
|
+
console.log(a.yellow(i18n.t("common:skip")));
|
|
62
75
|
return;
|
|
63
76
|
}
|
|
64
77
|
switch (action) {
|
|
@@ -98,7 +111,7 @@ async function handleAddProvider() {
|
|
|
98
111
|
prefilledBaseUrl = provider2.codex.baseUrl;
|
|
99
112
|
prefilledWireApi = provider2.codex.wireApi;
|
|
100
113
|
prefilledModel = provider2.codex.defaultModel;
|
|
101
|
-
console.log(
|
|
114
|
+
console.log(a.gray(i18n.t("api:providerSelected", { name: provider2.name })));
|
|
102
115
|
}
|
|
103
116
|
}
|
|
104
117
|
const answers = await inquirer.prompt([
|
|
@@ -154,7 +167,7 @@ async function handleAddProvider() {
|
|
|
154
167
|
defaultValue: false
|
|
155
168
|
});
|
|
156
169
|
if (!shouldOverwrite) {
|
|
157
|
-
console.log(
|
|
170
|
+
console.log(a.yellow(i18n.t("codex:providerDuplicateSkipped")));
|
|
158
171
|
return;
|
|
159
172
|
}
|
|
160
173
|
}
|
|
@@ -170,9 +183,9 @@ async function handleAddProvider() {
|
|
|
170
183
|
};
|
|
171
184
|
const result = await addProviderToExisting(provider, answers.apiKey.trim(), true);
|
|
172
185
|
if (result.success) {
|
|
173
|
-
console.log(
|
|
186
|
+
console.log(a.green(i18n.t("codex:providerAdded", { name: result.addedProvider?.name })));
|
|
174
187
|
if (result.backupPath) {
|
|
175
|
-
console.log(
|
|
188
|
+
console.log(a.gray(i18n.t("common:backupCreated", { path: result.backupPath })));
|
|
176
189
|
}
|
|
177
190
|
const setAsDefault = await promptBoolean({
|
|
178
191
|
message: i18n.t("multi-config:setAsDefaultPrompt"),
|
|
@@ -182,11 +195,11 @@ async function handleAddProvider() {
|
|
|
182
195
|
const { switchToProvider } = await import('./codex.mjs').then(function (n) { return n.n; });
|
|
183
196
|
const switched = await switchToProvider(provider.id);
|
|
184
197
|
if (switched) {
|
|
185
|
-
console.log(
|
|
198
|
+
console.log(a.green(i18n.t("multi-config:profileSetAsDefault", { name: provider.name })));
|
|
186
199
|
}
|
|
187
200
|
}
|
|
188
201
|
} else {
|
|
189
|
-
console.log(
|
|
202
|
+
console.log(a.red(i18n.t("codex:providerAddFailed", { error: result.error })));
|
|
190
203
|
}
|
|
191
204
|
}
|
|
192
205
|
async function handleEditProvider(providers) {
|
|
@@ -201,12 +214,12 @@ async function handleEditProvider(providers) {
|
|
|
201
214
|
choices: addNumbersToChoices(choices)
|
|
202
215
|
}]);
|
|
203
216
|
if (!selectedProviderId) {
|
|
204
|
-
console.log(
|
|
217
|
+
console.log(a.yellow(i18n.t("common:cancelled")));
|
|
205
218
|
return;
|
|
206
219
|
}
|
|
207
220
|
const provider = providers.find((p) => p.id === selectedProviderId);
|
|
208
221
|
if (!provider) {
|
|
209
|
-
console.log(
|
|
222
|
+
console.log(a.red(i18n.t("codex:providerNotFound")));
|
|
210
223
|
return;
|
|
211
224
|
}
|
|
212
225
|
const existingAuth = readJsonConfig(CODEX_AUTH_FILE, { defaultValue: {} }) || {};
|
|
@@ -270,12 +283,12 @@ async function handleEditProvider(providers) {
|
|
|
270
283
|
};
|
|
271
284
|
const result = await editExistingProvider(selectedProviderId, updates);
|
|
272
285
|
if (result.success) {
|
|
273
|
-
console.log(
|
|
286
|
+
console.log(a.green(i18n.t("codex:providerUpdated", { name: result.updatedProvider?.name })));
|
|
274
287
|
if (result.backupPath) {
|
|
275
|
-
console.log(
|
|
288
|
+
console.log(a.gray(i18n.t("common:backupCreated", { path: result.backupPath })));
|
|
276
289
|
}
|
|
277
290
|
} else {
|
|
278
|
-
console.log(
|
|
291
|
+
console.log(a.red(i18n.t("codex:providerUpdateFailed", { error: result.error })));
|
|
279
292
|
}
|
|
280
293
|
}
|
|
281
294
|
async function handleCopyProvider(providers) {
|
|
@@ -290,15 +303,15 @@ async function handleCopyProvider(providers) {
|
|
|
290
303
|
choices: addNumbersToChoices(choices)
|
|
291
304
|
}]);
|
|
292
305
|
if (!selectedProviderId) {
|
|
293
|
-
console.log(
|
|
306
|
+
console.log(a.yellow(i18n.t("common:cancelled")));
|
|
294
307
|
return;
|
|
295
308
|
}
|
|
296
309
|
const provider = providers.find((p) => p.id === selectedProviderId);
|
|
297
310
|
if (!provider) {
|
|
298
|
-
console.log(
|
|
311
|
+
console.log(a.red(i18n.t("codex:providerNotFound")));
|
|
299
312
|
return;
|
|
300
313
|
}
|
|
301
|
-
console.log(
|
|
314
|
+
console.log(a.green(`
|
|
302
315
|
${i18n.t("codex:copyingProvider", { name: provider.name })}`));
|
|
303
316
|
const existingAuth = readJsonConfig(CODEX_AUTH_FILE, { defaultValue: {} }) || {};
|
|
304
317
|
const existingApiKey = existingAuth[provider.tempEnvKey] || "";
|
|
@@ -365,9 +378,9 @@ ${i18n.t("codex:copyingProvider", { name: provider.name })}`));
|
|
|
365
378
|
};
|
|
366
379
|
const result = await addProviderToExisting(copiedProvider, answers.apiKey.trim(), false);
|
|
367
380
|
if (result.success) {
|
|
368
|
-
console.log(
|
|
381
|
+
console.log(a.green(i18n.t("codex:providerCopied", { name: result.addedProvider?.name })));
|
|
369
382
|
if (result.backupPath) {
|
|
370
|
-
console.log(
|
|
383
|
+
console.log(a.gray(i18n.t("common:backupCreated", { path: result.backupPath })));
|
|
371
384
|
}
|
|
372
385
|
const setAsDefault = await promptBoolean({
|
|
373
386
|
message: i18n.t("multi-config:setAsDefaultPrompt"),
|
|
@@ -377,11 +390,11 @@ ${i18n.t("codex:copyingProvider", { name: provider.name })}`));
|
|
|
377
390
|
const { switchToProvider } = await import('./codex.mjs').then(function (n) { return n.n; });
|
|
378
391
|
const switched = await switchToProvider(copiedProvider.id);
|
|
379
392
|
if (switched) {
|
|
380
|
-
console.log(
|
|
393
|
+
console.log(a.green(i18n.t("multi-config:profileSetAsDefault", { name: copiedProvider.name })));
|
|
381
394
|
}
|
|
382
395
|
}
|
|
383
396
|
} else {
|
|
384
|
-
console.log(
|
|
397
|
+
console.log(a.red(i18n.t("codex:providerCopyFailed", { error: result.error })));
|
|
385
398
|
}
|
|
386
399
|
}
|
|
387
400
|
async function handleDeleteProvider(providers) {
|
|
@@ -406,7 +419,7 @@ async function handleDeleteProvider(providers) {
|
|
|
406
419
|
}
|
|
407
420
|
});
|
|
408
421
|
if (!selectedProviderIds || selectedProviderIds.length === 0) {
|
|
409
|
-
console.log(
|
|
422
|
+
console.log(a.yellow(i18n.t("common:cancelled")));
|
|
410
423
|
return;
|
|
411
424
|
}
|
|
412
425
|
const selectedNames = selectedProviderIds.map(
|
|
@@ -417,20 +430,20 @@ async function handleDeleteProvider(providers) {
|
|
|
417
430
|
defaultValue: false
|
|
418
431
|
});
|
|
419
432
|
if (!confirmDelete) {
|
|
420
|
-
console.log(
|
|
433
|
+
console.log(a.yellow(i18n.t("common:cancelled")));
|
|
421
434
|
return;
|
|
422
435
|
}
|
|
423
436
|
const result = await deleteProviders(selectedProviderIds);
|
|
424
437
|
if (result.success) {
|
|
425
|
-
console.log(
|
|
438
|
+
console.log(a.green(i18n.t("codex:providersDeleted", { count: selectedProviderIds.length })));
|
|
426
439
|
if (result.newDefaultProvider) {
|
|
427
|
-
console.log(
|
|
440
|
+
console.log(a.green(i18n.t("codex:newDefaultProvider", { provider: result.newDefaultProvider })));
|
|
428
441
|
}
|
|
429
442
|
if (result.backupPath) {
|
|
430
|
-
console.log(
|
|
443
|
+
console.log(a.gray(i18n.t("common:backupCreated", { path: result.backupPath })));
|
|
431
444
|
}
|
|
432
445
|
} else {
|
|
433
|
-
console.log(
|
|
446
|
+
console.log(a.red(i18n.t("codex:providersDeleteFailed", { error: result.error })));
|
|
434
447
|
}
|
|
435
448
|
}
|
|
436
449
|
const codexConfigSwitch = { configureIncrementalManagement };
|