ccjk 2.0.13 → 2.0.15
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/simple-config.mjs +15 -53
- package/dist/cli.mjs +48 -33
- package/dist/i18n/locales/en/menu.json +8 -2
- package/dist/i18n/locales/en/superpowers.json +2 -0
- package/dist/i18n/locales/zh-CN/menu.json +8 -2
- package/dist/i18n/locales/zh-CN/superpowers.json +2 -0
- package/package.json +1 -1
|
@@ -22,7 +22,7 @@ import i18next from 'i18next';
|
|
|
22
22
|
import Backend from 'i18next-fs-backend';
|
|
23
23
|
import { randomBytes } from 'node:crypto';
|
|
24
24
|
|
|
25
|
-
const version = "2.0.
|
|
25
|
+
const version = "2.0.15";
|
|
26
26
|
const homepage = "https://github.com/miounet11/ccjk";
|
|
27
27
|
|
|
28
28
|
const i18n = i18next.createInstance();
|
|
@@ -6773,29 +6773,7 @@ async function installSuperpowers(_options) {
|
|
|
6773
6773
|
message: i18n.t("superpowers:alreadyInstalled")
|
|
6774
6774
|
};
|
|
6775
6775
|
}
|
|
6776
|
-
|
|
6777
|
-
try {
|
|
6778
|
-
await execAsync("claude /plugin marketplace add obra/superpowers-marketplace", {
|
|
6779
|
-
timeout: 6e4
|
|
6780
|
-
});
|
|
6781
|
-
} catch {
|
|
6782
|
-
}
|
|
6783
|
-
console.log(i18n.t("superpowers:installing"));
|
|
6784
|
-
await execAsync("claude /plugin install superpowers@superpowers-marketplace", {
|
|
6785
|
-
timeout: 12e4
|
|
6786
|
-
});
|
|
6787
|
-
const newStatus = await checkSuperpowersInstalled();
|
|
6788
|
-
if (newStatus.installed) {
|
|
6789
|
-
return {
|
|
6790
|
-
success: true,
|
|
6791
|
-
message: i18n.t("superpowers:installSuccess")
|
|
6792
|
-
};
|
|
6793
|
-
}
|
|
6794
|
-
return {
|
|
6795
|
-
success: false,
|
|
6796
|
-
message: i18n.t("superpowers:installFailed"),
|
|
6797
|
-
error: "Installation completed but plugin not found"
|
|
6798
|
-
};
|
|
6776
|
+
return installSuperpowersViaGit();
|
|
6799
6777
|
} catch (error) {
|
|
6800
6778
|
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
6801
6779
|
return {
|
|
@@ -6845,16 +6823,10 @@ async function uninstallSuperpowers() {
|
|
|
6845
6823
|
message: i18n.t("superpowers:notInstalled")
|
|
6846
6824
|
};
|
|
6847
6825
|
}
|
|
6848
|
-
|
|
6849
|
-
|
|
6850
|
-
|
|
6851
|
-
});
|
|
6852
|
-
} catch {
|
|
6853
|
-
const superpowersPath = getSuperpowersPath();
|
|
6854
|
-
if (existsSync(superpowersPath)) {
|
|
6855
|
-
const { rm } = await import('node:fs/promises');
|
|
6856
|
-
await rm(superpowersPath, { recursive: true, force: true });
|
|
6857
|
-
}
|
|
6826
|
+
const superpowersPath = getSuperpowersPath();
|
|
6827
|
+
if (existsSync(superpowersPath)) {
|
|
6828
|
+
const { rm } = await import('node:fs/promises');
|
|
6829
|
+
await rm(superpowersPath, { recursive: true, force: true });
|
|
6858
6830
|
}
|
|
6859
6831
|
const newStatus = await checkSuperpowersInstalled();
|
|
6860
6832
|
if (!newStatus.installed) {
|
|
@@ -6885,25 +6857,15 @@ async function updateSuperpowers() {
|
|
|
6885
6857
|
message: i18n.t("superpowers:notInstalled")
|
|
6886
6858
|
};
|
|
6887
6859
|
}
|
|
6888
|
-
|
|
6889
|
-
|
|
6890
|
-
|
|
6891
|
-
|
|
6892
|
-
|
|
6893
|
-
|
|
6894
|
-
|
|
6895
|
-
|
|
6896
|
-
}
|
|
6897
|
-
const superpowersPath = getSuperpowersPath();
|
|
6898
|
-
await execAsync("git pull", {
|
|
6899
|
-
cwd: superpowersPath,
|
|
6900
|
-
timeout: 6e4
|
|
6901
|
-
});
|
|
6902
|
-
return {
|
|
6903
|
-
success: true,
|
|
6904
|
-
message: i18n.t("superpowers:updateSuccess")
|
|
6905
|
-
};
|
|
6906
|
-
}
|
|
6860
|
+
const superpowersPath = getSuperpowersPath();
|
|
6861
|
+
await execAsync("git pull", {
|
|
6862
|
+
cwd: superpowersPath,
|
|
6863
|
+
timeout: 6e4
|
|
6864
|
+
});
|
|
6865
|
+
return {
|
|
6866
|
+
success: true,
|
|
6867
|
+
message: i18n.t("superpowers:updateSuccess")
|
|
6868
|
+
};
|
|
6907
6869
|
} catch (error) {
|
|
6908
6870
|
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
6909
6871
|
return {
|
package/dist/cli.mjs
CHANGED
|
@@ -9431,9 +9431,10 @@ async function showConfigCenterMenu() {
|
|
|
9431
9431
|
}
|
|
9432
9432
|
printSeparator();
|
|
9433
9433
|
}
|
|
9434
|
-
async function
|
|
9435
|
-
console.log(ansis.cyan(i18n.t("menu:
|
|
9434
|
+
async function showExtensionsHubMenu() {
|
|
9435
|
+
console.log(ansis.cyan(i18n.t("menu:extensionsHub.title")));
|
|
9436
9436
|
console.log("");
|
|
9437
|
+
console.log(` ${i18n.t("menu:menuSections.recommendedPlugins")}`);
|
|
9437
9438
|
console.log(
|
|
9438
9439
|
` ${ansis.cyan("1.")} ${i18n.t("menu:pluginsMenu.ccr")} ${ansis.gray(`- ${i18n.t("menu:pluginsMenu.ccrDesc")}`)}`
|
|
9439
9440
|
);
|
|
@@ -9446,6 +9447,15 @@ async function showRecommendedPluginsMenu() {
|
|
|
9446
9447
|
console.log(
|
|
9447
9448
|
` ${ansis.cyan("4.")} ${i18n.t("menu:pluginsMenu.superpowers")} ${ansis.gray(`- ${i18n.t("menu:pluginsMenu.superpowersDesc")}`)}`
|
|
9448
9449
|
);
|
|
9450
|
+
console.log("");
|
|
9451
|
+
console.log(` ${i18n.t("menu:extensionsHub.markets")}`);
|
|
9452
|
+
console.log(
|
|
9453
|
+
` ${ansis.cyan("5.")} ${i18n.t("menu:categorizedMenu.mcpMarket")} ${ansis.gray(`- ${i18n.t("menu:categorizedMenu.mcpMarketDesc")}`)}`
|
|
9454
|
+
);
|
|
9455
|
+
console.log(
|
|
9456
|
+
` ${ansis.cyan("6.")} ${i18n.t("menu:categorizedMenu.marketplace")} ${ansis.gray(`- ${i18n.t("menu:categorizedMenu.marketplaceDesc")}`)}`
|
|
9457
|
+
);
|
|
9458
|
+
console.log("");
|
|
9449
9459
|
console.log(` ${ansis.cyan("0.")} ${i18n.t("common:back")}`);
|
|
9450
9460
|
console.log("");
|
|
9451
9461
|
const { choice } = await inquirer.prompt({
|
|
@@ -9453,7 +9463,7 @@ async function showRecommendedPluginsMenu() {
|
|
|
9453
9463
|
name: "choice",
|
|
9454
9464
|
message: i18n.t("common:enterChoice"),
|
|
9455
9465
|
validate: (value) => {
|
|
9456
|
-
const valid = ["1", "2", "3", "4", "0"];
|
|
9466
|
+
const valid = ["1", "2", "3", "4", "5", "6", "0"];
|
|
9457
9467
|
return valid.includes(value) || i18n.t("common:invalidChoice");
|
|
9458
9468
|
}
|
|
9459
9469
|
});
|
|
@@ -9473,6 +9483,14 @@ async function showRecommendedPluginsMenu() {
|
|
|
9473
9483
|
case "4":
|
|
9474
9484
|
await showSuperpowersMenu();
|
|
9475
9485
|
break;
|
|
9486
|
+
case "5":
|
|
9487
|
+
printSeparator();
|
|
9488
|
+
await showMcpMarketMenu();
|
|
9489
|
+
return;
|
|
9490
|
+
case "6":
|
|
9491
|
+
printSeparator();
|
|
9492
|
+
await showMarketplaceMenu();
|
|
9493
|
+
return;
|
|
9476
9494
|
}
|
|
9477
9495
|
printSeparator();
|
|
9478
9496
|
}
|
|
@@ -9489,31 +9507,31 @@ async function showCategorizedMenu() {
|
|
|
9489
9507
|
console.log("");
|
|
9490
9508
|
console.log(` ${i18n.t("menu:menuSections.configCenter")}`);
|
|
9491
9509
|
console.log(
|
|
9492
|
-
` ${ansis.cyan("3.")} ${i18n.t("menu:
|
|
9510
|
+
` ${ansis.cyan("3.")} ${i18n.t("menu:configCenter.api")} ${ansis.gray(`- ${i18n.t("menu:configCenter.apiDesc")}`)}`
|
|
9493
9511
|
);
|
|
9494
|
-
console.log("");
|
|
9495
|
-
console.log(` ${i18n.t("menu:menuSections.extensions")}`);
|
|
9496
9512
|
console.log(
|
|
9497
|
-
` ${ansis.cyan("4.")} ${i18n.t("menu:
|
|
9513
|
+
` ${ansis.cyan("4.")} ${i18n.t("menu:configCenter.model")} ${ansis.gray(`- ${i18n.t("menu:configCenter.modelDesc")}`)}`
|
|
9498
9514
|
);
|
|
9499
9515
|
console.log(
|
|
9500
|
-
` ${ansis.cyan("5.")} ${i18n.t("menu:
|
|
9516
|
+
` ${ansis.cyan("5.")} ${i18n.t("menu:configCenter.configSwitch")} ${ansis.gray(`- ${i18n.t("menu:configCenter.configSwitchDesc")}`)}`
|
|
9501
9517
|
);
|
|
9502
9518
|
console.log(
|
|
9503
|
-
` ${ansis.cyan("6.")} ${i18n.t("menu:categorizedMenu.
|
|
9519
|
+
` ${ansis.cyan("6.")} ${i18n.t("menu:categorizedMenu.configCenter")} \u2192 ${ansis.gray(i18n.t("menu:categorizedMenu.moreConfig"))}`
|
|
9504
9520
|
);
|
|
9505
9521
|
console.log("");
|
|
9506
|
-
console.log(` ${i18n.t("menu:menuSections.
|
|
9522
|
+
console.log(` ${i18n.t("menu:menuSections.cloudServices")}`);
|
|
9507
9523
|
console.log(
|
|
9508
|
-
` ${ansis.cyan("7.")} ${i18n.t("menu:
|
|
9524
|
+
` ${ansis.cyan("7.")} ${i18n.t("menu:menuOptions.cloudNotification")} ${ansis.gray(`- ${i18n.t("menu:menuDescriptions.cloudNotification")}`)}`
|
|
9509
9525
|
);
|
|
9526
|
+
console.log("");
|
|
9527
|
+
console.log(` ${i18n.t("menu:menuSections.extensions")}`);
|
|
9510
9528
|
console.log(
|
|
9511
|
-
` ${ansis.cyan("8.")} ${i18n.t("menu:categorizedMenu.
|
|
9529
|
+
` ${ansis.cyan("8.")} ${i18n.t("menu:categorizedMenu.extensionsHub")} \u2192 ${ansis.gray(i18n.t("menu:categorizedMenu.extensionsHubDesc"))}`
|
|
9512
9530
|
);
|
|
9513
9531
|
console.log("");
|
|
9514
9532
|
console.log(` ${ansis.dim("\u2500".repeat(50))}`);
|
|
9515
9533
|
console.log(
|
|
9516
|
-
` ${ansis.cyan("0.")} ${i18n.t("menu:menuOptions.changeLanguage").split(" / ")[0]} ${ansis.cyan("S.")} ${i18n.t("menu:menuOptions.switchCodeTool")} ${ansis.cyan("
|
|
9534
|
+
` ${ansis.cyan("0.")} ${i18n.t("menu:menuOptions.changeLanguage").split(" / ")[0]} ${ansis.cyan("S.")} ${i18n.t("menu:menuOptions.switchCodeTool")} ${ansis.cyan("D.")} ${i18n.t("menu:categorizedMenu.diagnostics")} ${ansis.cyan("+.")} ${i18n.t("menu:menuOptions.checkUpdates")} ${ansis.red("Q.")} ${i18n.t("menu:menuOptions.exit")}`
|
|
9517
9535
|
);
|
|
9518
9536
|
console.log("");
|
|
9519
9537
|
const { choice } = await inquirer.prompt({
|
|
@@ -9521,7 +9539,7 @@ async function showCategorizedMenu() {
|
|
|
9521
9539
|
name: "choice",
|
|
9522
9540
|
message: i18n.t("common:enterChoice"),
|
|
9523
9541
|
validate: (value) => {
|
|
9524
|
-
const valid = ["1", "2", "3", "4", "5", "6", "7", "8", "0", "s", "S", "
|
|
9542
|
+
const valid = ["1", "2", "3", "4", "5", "6", "7", "8", "0", "s", "S", "d", "D", "+", "-", "q", "Q", "h", "H"];
|
|
9525
9543
|
return valid.includes(value) || i18n.t("common:invalidChoice");
|
|
9526
9544
|
}
|
|
9527
9545
|
});
|
|
@@ -9538,32 +9556,29 @@ async function showCategorizedMenu() {
|
|
|
9538
9556
|
case "2":
|
|
9539
9557
|
await update({ skipBanner: true });
|
|
9540
9558
|
break;
|
|
9541
|
-
// Configuration
|
|
9559
|
+
// Configuration (direct access to important items)
|
|
9542
9560
|
case "3":
|
|
9543
|
-
|
|
9544
|
-
|
|
9545
|
-
return void 0;
|
|
9546
|
-
// Extensions
|
|
9561
|
+
await configureApiFeature();
|
|
9562
|
+
break;
|
|
9547
9563
|
case "4":
|
|
9548
|
-
|
|
9549
|
-
|
|
9550
|
-
return void 0;
|
|
9564
|
+
await configureDefaultModelFeature();
|
|
9565
|
+
break;
|
|
9551
9566
|
case "5":
|
|
9552
|
-
|
|
9553
|
-
|
|
9554
|
-
return void 0;
|
|
9567
|
+
await showConfigSwitchMenu();
|
|
9568
|
+
break;
|
|
9555
9569
|
case "6":
|
|
9556
9570
|
printSeparator();
|
|
9557
|
-
await
|
|
9571
|
+
await showConfigCenterMenu();
|
|
9558
9572
|
return void 0;
|
|
9559
|
-
//
|
|
9573
|
+
// Cloud & Notification
|
|
9560
9574
|
case "7":
|
|
9575
|
+
await notificationCommand();
|
|
9576
|
+
break;
|
|
9577
|
+
// Extensions Hub
|
|
9578
|
+
case "8":
|
|
9561
9579
|
printSeparator();
|
|
9562
|
-
await
|
|
9580
|
+
await showExtensionsHubMenu();
|
|
9563
9581
|
return void 0;
|
|
9564
|
-
case "8":
|
|
9565
|
-
await doctor();
|
|
9566
|
-
break;
|
|
9567
9582
|
// System settings
|
|
9568
9583
|
case "0": {
|
|
9569
9584
|
const currentLang = i18n.language;
|
|
@@ -9577,8 +9592,8 @@ async function showCategorizedMenu() {
|
|
|
9577
9592
|
}
|
|
9578
9593
|
break;
|
|
9579
9594
|
}
|
|
9580
|
-
case "
|
|
9581
|
-
await
|
|
9595
|
+
case "d":
|
|
9596
|
+
await doctor();
|
|
9582
9597
|
break;
|
|
9583
9598
|
case "+":
|
|
9584
9599
|
await checkUpdates();
|
|
@@ -13,8 +13,11 @@
|
|
|
13
13
|
"categorizedMenu.fullInitDesc": "One-click setup for all features",
|
|
14
14
|
"categorizedMenu.importWorkflow": "Import Workflow",
|
|
15
15
|
"categorizedMenu.importWorkflowDesc": "Add new workflow templates",
|
|
16
|
-
"categorizedMenu.configCenter": "Config
|
|
16
|
+
"categorizedMenu.configCenter": "More Config",
|
|
17
17
|
"categorizedMenu.configCenterDesc": "API/MCP/Model/Memory/Permissions",
|
|
18
|
+
"categorizedMenu.moreConfig": "MCP/Memory/Permissions/Context",
|
|
19
|
+
"categorizedMenu.extensionsHub": "Extensions Hub",
|
|
20
|
+
"categorizedMenu.extensionsHubDesc": "CCR/CCUsage/Cometix/Superpowers/MCP Market",
|
|
18
21
|
"categorizedMenu.recommendedPlugins": "Recommended Plugins",
|
|
19
22
|
"categorizedMenu.recommendedPluginsDesc": "CCR/CCUsage/Cometix/Superpowers",
|
|
20
23
|
"categorizedMenu.mcpMarket": "MCP Market",
|
|
@@ -232,5 +235,8 @@
|
|
|
232
235
|
"newUser.plugin.ccusage": "CCusage - API usage analytics tool",
|
|
233
236
|
"newUser.plugin.cometix": "Cometix - Statusline enhancement tool",
|
|
234
237
|
"newUser.plugin.superpowers": "Superpowers - Skills extension system",
|
|
235
|
-
"newUser.pressEnter": "Press Enter to continue..."
|
|
238
|
+
"newUser.pressEnter": "Press Enter to continue...",
|
|
239
|
+
|
|
240
|
+
"extensionsHub.title": "🔌 Extensions Hub",
|
|
241
|
+
"extensionsHub.markets": "📦 Markets"
|
|
236
242
|
}
|
|
@@ -17,6 +17,8 @@
|
|
|
17
17
|
"updateSuccess": "Superpowers updated successfully",
|
|
18
18
|
"updateFailed": "Failed to update Superpowers",
|
|
19
19
|
"checkingStatus": "Checking Superpowers status...",
|
|
20
|
+
"cliNotAvailable": "Claude CLI not available, using Git installation...",
|
|
21
|
+
"pluginCommandFailed": "Plugin command failed, trying Git installation...",
|
|
20
22
|
"status.installed": "Installed",
|
|
21
23
|
"status.notInstalled": "Not Installed",
|
|
22
24
|
"status.version": "Version: {version}",
|
|
@@ -13,8 +13,11 @@
|
|
|
13
13
|
"categorizedMenu.fullInitDesc": "一键配置所有功能",
|
|
14
14
|
"categorizedMenu.importWorkflow": "导入工作流",
|
|
15
15
|
"categorizedMenu.importWorkflowDesc": "添加新的工作流模板",
|
|
16
|
-
"categorizedMenu.configCenter": "
|
|
16
|
+
"categorizedMenu.configCenter": "更多配置",
|
|
17
17
|
"categorizedMenu.configCenterDesc": "API/MCP/模型/记忆/权限",
|
|
18
|
+
"categorizedMenu.moreConfig": "MCP/记忆/权限/上下文",
|
|
19
|
+
"categorizedMenu.extensionsHub": "扩展中心",
|
|
20
|
+
"categorizedMenu.extensionsHubDesc": "CCR/CCUsage/Cometix/Superpowers/MCP市场",
|
|
18
21
|
"categorizedMenu.recommendedPlugins": "推荐插件",
|
|
19
22
|
"categorizedMenu.recommendedPluginsDesc": "CCR/CCUsage/Cometix/Superpowers",
|
|
20
23
|
"categorizedMenu.mcpMarket": "MCP 市场",
|
|
@@ -232,5 +235,8 @@
|
|
|
232
235
|
"newUser.plugin.ccusage": "CCusage - API 使用量统计工具",
|
|
233
236
|
"newUser.plugin.cometix": "Cometix - 状态栏增强工具",
|
|
234
237
|
"newUser.plugin.superpowers": "Superpowers - 技能扩展系统",
|
|
235
|
-
"newUser.pressEnter": "按 Enter 继续..."
|
|
238
|
+
"newUser.pressEnter": "按 Enter 继续...",
|
|
239
|
+
|
|
240
|
+
"extensionsHub.title": "🔌 扩展中心",
|
|
241
|
+
"extensionsHub.markets": "📦 市场"
|
|
236
242
|
}
|
|
@@ -17,6 +17,8 @@
|
|
|
17
17
|
"updateSuccess": "Superpowers 更新成功",
|
|
18
18
|
"updateFailed": "Superpowers 更新失败",
|
|
19
19
|
"checkingStatus": "正在检查 Superpowers 状态...",
|
|
20
|
+
"cliNotAvailable": "Claude CLI 不可用,将使用 Git 方式安装...",
|
|
21
|
+
"pluginCommandFailed": "插件命令执行失败,尝试使用 Git 方式安装...",
|
|
20
22
|
"status.installed": "已安装",
|
|
21
23
|
"status.notInstalled": "未安装",
|
|
22
24
|
"status.version": "版本: {version}",
|
package/package.json
CHANGED