ccjk 14.2.2 → 15.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/LICENSE +1 -1
- package/README.md +58 -341
- package/dist/cli.js +59 -0
- package/dist/cli.js.map +1 -0
- package/dist/commands/detect.js +15 -0
- package/dist/commands/detect.js.map +1 -0
- package/dist/commands/doctor.js +68 -0
- package/dist/commands/doctor.js.map +1 -0
- package/dist/commands/git-install.js +50 -0
- package/dist/commands/git-install.js.map +1 -0
- package/dist/commands/init.js +102 -0
- package/dist/commands/init.js.map +1 -0
- package/dist/commands/mcp.js +66 -0
- package/dist/commands/mcp.js.map +1 -0
- package/dist/commands/menu.js +33 -0
- package/dist/commands/menu.js.map +1 -0
- package/dist/core/detect.js +24 -0
- package/dist/core/detect.js.map +1 -0
- package/dist/core/lint.js +49 -0
- package/dist/core/lint.js.map +1 -0
- package/dist/core/mcp.js +41 -0
- package/dist/core/mcp.js.map +1 -0
- package/dist/core/paths.js +9 -0
- package/dist/core/paths.js.map +1 -0
- package/dist/core/providers.js +53 -0
- package/dist/core/providers.js.map +1 -0
- package/dist/core/settings.js +31 -0
- package/dist/core/settings.js.map +1 -0
- package/dist/core/slash-templates.js +56 -0
- package/dist/core/slash-templates.js.map +1 -0
- package/dist/core/tools.js +27 -0
- package/dist/core/tools.js.map +1 -0
- package/package.json +43 -164
- package/README.HONEST.md +0 -176
- package/README.en.md +0 -67
- package/README.ja.md +0 -67
- package/README.ko.md +0 -67
- package/README.zh-CN.md +0 -86
- package/bin/ccjk.mjs +0 -5
- package/bin/ccjk.ts +0 -222
- package/dist/chunks/agent-teams.mjs +0 -145
- package/dist/chunks/agent.mjs +0 -1439
- package/dist/chunks/agents.mjs +0 -3783
- package/dist/chunks/api-cli.mjs +0 -135
- package/dist/chunks/api-config-selector.mjs +0 -159
- package/dist/chunks/api-providers.mjs +0 -144
- package/dist/chunks/api.mjs +0 -115
- package/dist/chunks/auto-bootstrap.mjs +0 -358
- package/dist/chunks/auto-fixer.mjs +0 -95
- package/dist/chunks/auto-updater.mjs +0 -507
- package/dist/chunks/banner.mjs +0 -173
- package/dist/chunks/bash.mjs +0 -187
- package/dist/chunks/boost.mjs +0 -474
- package/dist/chunks/brain-config.mjs +0 -75
- package/dist/chunks/brain-status.mjs +0 -89
- package/dist/chunks/ccjk-agents.mjs +0 -416
- package/dist/chunks/ccjk-all.mjs +0 -1046
- package/dist/chunks/ccjk-config.mjs +0 -445
- package/dist/chunks/ccjk-hooks.mjs +0 -1074
- package/dist/chunks/ccjk-mcp.mjs +0 -763
- package/dist/chunks/ccjk-setup.mjs +0 -765
- package/dist/chunks/ccjk-skills.mjs +0 -518
- package/dist/chunks/ccr.mjs +0 -109
- package/dist/chunks/ccu.mjs +0 -40
- package/dist/chunks/check-updates.mjs +0 -117
- package/dist/chunks/claude-code-incremental-manager.mjs +0 -761
- package/dist/chunks/claude-config.mjs +0 -606
- package/dist/chunks/claude-config2.mjs +0 -62
- package/dist/chunks/claude-wrapper.mjs +0 -85
- package/dist/chunks/clavue-config.mjs +0 -1454
- package/dist/chunks/cleanup-migration.mjs +0 -20
- package/dist/chunks/cli-hook.mjs +0 -4096
- package/dist/chunks/cloud-sync.mjs +0 -29
- package/dist/chunks/code-type-resolver.mjs +0 -880
- package/dist/chunks/codex-config-switch.mjs +0 -452
- package/dist/chunks/codex-provider-manager.mjs +0 -238
- package/dist/chunks/codex-uninstaller.mjs +0 -404
- package/dist/chunks/codex.mjs +0 -2141
- package/dist/chunks/commands.mjs +0 -108
- package/dist/chunks/commands2.mjs +0 -421
- package/dist/chunks/commit.mjs +0 -140
- package/dist/chunks/completion.mjs +0 -517
- package/dist/chunks/config-consolidator.mjs +0 -172
- package/dist/chunks/config-switch.mjs +0 -334
- package/dist/chunks/config.mjs +0 -558
- package/dist/chunks/config2.mjs +0 -484
- package/dist/chunks/config3.mjs +0 -486
- package/dist/chunks/constants.mjs +0 -323
- package/dist/chunks/context-opt.mjs +0 -444
- package/dist/chunks/context.mjs +0 -974
- package/dist/chunks/dashboard.mjs +0 -481
- package/dist/chunks/doctor.mjs +0 -1301
- package/dist/chunks/eval.mjs +0 -502
- package/dist/chunks/evolution.mjs +0 -322
- package/dist/chunks/features.mjs +0 -715
- package/dist/chunks/fish.mjs +0 -181
- package/dist/chunks/fs-operations.mjs +0 -180
- package/dist/chunks/health-alerts.mjs +0 -830
- package/dist/chunks/help.mjs +0 -341
- package/dist/chunks/hook-installer.mjs +0 -48
- package/dist/chunks/impact.mjs +0 -651
- package/dist/chunks/index.mjs +0 -23
- package/dist/chunks/index10.mjs +0 -19
- package/dist/chunks/index11.mjs +0 -1171
- package/dist/chunks/index12.mjs +0 -218
- package/dist/chunks/index13.mjs +0 -679
- package/dist/chunks/index14.mjs +0 -1009
- package/dist/chunks/index15.mjs +0 -194
- package/dist/chunks/index2.mjs +0 -7637
- package/dist/chunks/index3.mjs +0 -171
- package/dist/chunks/index4.mjs +0 -26
- package/dist/chunks/index5.mjs +0 -19
- package/dist/chunks/index6.mjs +0 -19092
- package/dist/chunks/index7.mjs +0 -616
- package/dist/chunks/index8.mjs +0 -1602
- package/dist/chunks/index9.mjs +0 -5384
- package/dist/chunks/init.mjs +0 -1911
- package/dist/chunks/installer.mjs +0 -757
- package/dist/chunks/installer2.mjs +0 -103
- package/dist/chunks/interview.mjs +0 -2927
- package/dist/chunks/json-config.mjs +0 -60
- package/dist/chunks/linux.mjs +0 -3863
- package/dist/chunks/macos.mjs +0 -69
- package/dist/chunks/main.mjs +0 -635
- package/dist/chunks/manager.mjs +0 -1048
- package/dist/chunks/marketplace.mjs +0 -265
- package/dist/chunks/mcp-cli.mjs +0 -205
- package/dist/chunks/mcp-performance.mjs +0 -187
- package/dist/chunks/mcp.mjs +0 -667
- package/dist/chunks/memory-check.mjs +0 -2973
- package/dist/chunks/memory-paths.mjs +0 -259
- package/dist/chunks/memory-sync.mjs +0 -209
- package/dist/chunks/memory.mjs +0 -354
- package/dist/chunks/metrics-display.mjs +0 -153
- package/dist/chunks/monitor.mjs +0 -1856
- package/dist/chunks/notification.mjs +0 -1864
- package/dist/chunks/onboarding.mjs +0 -386
- package/dist/chunks/package.mjs +0 -3
- package/dist/chunks/paradigm.mjs +0 -74
- package/dist/chunks/permission-manager.mjs +0 -250
- package/dist/chunks/permissions.mjs +0 -265
- package/dist/chunks/persistence-manager.mjs +0 -801
- package/dist/chunks/persistence.mjs +0 -707
- package/dist/chunks/platform.mjs +0 -395
- package/dist/chunks/plugin.mjs +0 -1936
- package/dist/chunks/powershell.mjs +0 -213
- package/dist/chunks/prompts.mjs +0 -244
- package/dist/chunks/providers.mjs +0 -263
- package/dist/chunks/quick-actions.mjs +0 -335
- package/dist/chunks/quick-provider.mjs +0 -755
- package/dist/chunks/quick-setup.mjs +0 -421
- package/dist/chunks/remote.mjs +0 -497
- package/dist/chunks/research.mjs +0 -1904
- package/dist/chunks/rollback.mjs +0 -38
- package/dist/chunks/session-manager.mjs +0 -1371
- package/dist/chunks/session.mjs +0 -878
- package/dist/chunks/sessions.mjs +0 -106
- package/dist/chunks/silent-updater.mjs +0 -396
- package/dist/chunks/simple-config.mjs +0 -122
- package/dist/chunks/skill.mjs +0 -117
- package/dist/chunks/skill2.mjs +0 -9052
- package/dist/chunks/skills-sync.mjs +0 -1343
- package/dist/chunks/skills.mjs +0 -577
- package/dist/chunks/slash-commands.mjs +0 -208
- package/dist/chunks/smart-guide.mjs +0 -247
- package/dist/chunks/snapshot.mjs +0 -58
- package/dist/chunks/startup.mjs +0 -487
- package/dist/chunks/stats.mjs +0 -191
- package/dist/chunks/status.mjs +0 -471
- package/dist/chunks/team.mjs +0 -63
- package/dist/chunks/thinking.mjs +0 -626
- package/dist/chunks/trace.mjs +0 -57
- package/dist/chunks/uninstall.mjs +0 -852
- package/dist/chunks/update.mjs +0 -174
- package/dist/chunks/upgrade-manager.mjs +0 -204
- package/dist/chunks/upgrade.mjs +0 -133
- package/dist/chunks/version-checker.mjs +0 -891
- package/dist/chunks/vim.mjs +0 -903
- package/dist/chunks/windows.mjs +0 -14
- package/dist/chunks/workflows.mjs +0 -633
- package/dist/chunks/wsl.mjs +0 -129
- package/dist/chunks/zero-config.mjs +0 -871
- package/dist/chunks/zsh.mjs +0 -182
- package/dist/cli.d.mts +0 -1
- package/dist/cli.d.ts +0 -1
- package/dist/cli.mjs +0 -2684
- package/dist/i18n/locales/en/agent-teams.json +0 -18
- package/dist/i18n/locales/en/agentBrowser.json +0 -80
- package/dist/i18n/locales/en/agents.json +0 -135
- package/dist/i18n/locales/en/api.json +0 -63
- package/dist/i18n/locales/en/ccjk-agents.json +0 -33
- package/dist/i18n/locales/en/ccjk-all.json +0 -23
- package/dist/i18n/locales/en/ccjk-skills.json +0 -22
- package/dist/i18n/locales/en/ccjk.json +0 -276
- package/dist/i18n/locales/en/ccr.json +0 -65
- package/dist/i18n/locales/en/claude-md.json +0 -73
- package/dist/i18n/locales/en/cli.json +0 -148
- package/dist/i18n/locales/en/cloud-setup.json +0 -31
- package/dist/i18n/locales/en/cloud-sync.json +0 -147
- package/dist/i18n/locales/en/cloud.json +0 -40
- package/dist/i18n/locales/en/cloudPlugins.json +0 -118
- package/dist/i18n/locales/en/codex.json +0 -184
- package/dist/i18n/locales/en/cometix.json +0 -29
- package/dist/i18n/locales/en/common.json +0 -68
- package/dist/i18n/locales/en/config.json +0 -108
- package/dist/i18n/locales/en/configuration.json +0 -236
- package/dist/i18n/locales/en/context.json +0 -85
- package/dist/i18n/locales/en/dashboard.json +0 -78
- package/dist/i18n/locales/en/errors.json +0 -26
- package/dist/i18n/locales/en/evolution.json +0 -54
- package/dist/i18n/locales/en/hooks.json +0 -74
- package/dist/i18n/locales/en/hooksSync.json +0 -133
- package/dist/i18n/locales/en/installation.json +0 -83
- package/dist/i18n/locales/en/interview.json +0 -104
- package/dist/i18n/locales/en/language.json +0 -19
- package/dist/i18n/locales/en/lsp.json +0 -78
- package/dist/i18n/locales/en/marketplace.json +0 -116
- package/dist/i18n/locales/en/mcp.json +0 -180
- package/dist/i18n/locales/en/memory.json +0 -23
- package/dist/i18n/locales/en/menu.json +0 -299
- package/dist/i18n/locales/en/multi-config.json +0 -79
- package/dist/i18n/locales/en/notification.json +0 -307
- package/dist/i18n/locales/en/permissions.json +0 -95
- package/dist/i18n/locales/en/persistence.json +0 -127
- package/dist/i18n/locales/en/plugins.json +0 -146
- package/dist/i18n/locales/en/quick-actions.json +0 -78
- package/dist/i18n/locales/en/registry.json +0 -54
- package/dist/i18n/locales/en/remote.json +0 -93
- package/dist/i18n/locales/en/sandbox.json +0 -44
- package/dist/i18n/locales/en/setup.json +0 -44
- package/dist/i18n/locales/en/shencha.json +0 -14
- package/dist/i18n/locales/en/skills.json +0 -100
- package/dist/i18n/locales/en/skillsSync.json +0 -74
- package/dist/i18n/locales/en/smartGuide.json +0 -49
- package/dist/i18n/locales/en/stats.json +0 -20
- package/dist/i18n/locales/en/subagent.json +0 -69
- package/dist/i18n/locales/en/superpowers.json +0 -117
- package/dist/i18n/locales/en/team.json +0 -7
- package/dist/i18n/locales/en/thinking.json +0 -65
- package/dist/i18n/locales/en/tools.json +0 -42
- package/dist/i18n/locales/en/uninstall.json +0 -56
- package/dist/i18n/locales/en/updater.json +0 -29
- package/dist/i18n/locales/en/vim.json +0 -169
- package/dist/i18n/locales/en/workflow.json +0 -55
- package/dist/i18n/locales/en/workspace.json +0 -108
- package/dist/i18n/locales/zh-CN/agent-teams.json +0 -18
- package/dist/i18n/locales/zh-CN/agentBrowser.json +0 -80
- package/dist/i18n/locales/zh-CN/agents.json +0 -135
- package/dist/i18n/locales/zh-CN/api.json +0 -63
- package/dist/i18n/locales/zh-CN/ccjk-agents.json +0 -33
- package/dist/i18n/locales/zh-CN/ccjk-all.json +0 -23
- package/dist/i18n/locales/zh-CN/ccjk-skills.json +0 -22
- package/dist/i18n/locales/zh-CN/ccjk.json +0 -276
- package/dist/i18n/locales/zh-CN/ccr.json +0 -65
- package/dist/i18n/locales/zh-CN/claude-md.json +0 -73
- package/dist/i18n/locales/zh-CN/cli.json +0 -148
- package/dist/i18n/locales/zh-CN/cloud-setup.json +0 -31
- package/dist/i18n/locales/zh-CN/cloud-sync.json +0 -147
- package/dist/i18n/locales/zh-CN/cloud.json +0 -40
- package/dist/i18n/locales/zh-CN/cloudPlugins.json +0 -118
- package/dist/i18n/locales/zh-CN/codex.json +0 -184
- package/dist/i18n/locales/zh-CN/cometix.json +0 -29
- package/dist/i18n/locales/zh-CN/common.json +0 -68
- package/dist/i18n/locales/zh-CN/config.json +0 -108
- package/dist/i18n/locales/zh-CN/configuration.json +0 -234
- package/dist/i18n/locales/zh-CN/context.json +0 -85
- package/dist/i18n/locales/zh-CN/dashboard.json +0 -78
- package/dist/i18n/locales/zh-CN/errors.json +0 -26
- package/dist/i18n/locales/zh-CN/evolution.json +0 -54
- package/dist/i18n/locales/zh-CN/hooks.json +0 -74
- package/dist/i18n/locales/zh-CN/hooksSync.json +0 -133
- package/dist/i18n/locales/zh-CN/installation.json +0 -83
- package/dist/i18n/locales/zh-CN/interview.json +0 -104
- package/dist/i18n/locales/zh-CN/language.json +0 -19
- package/dist/i18n/locales/zh-CN/lsp.json +0 -78
- package/dist/i18n/locales/zh-CN/marketplace.json +0 -116
- package/dist/i18n/locales/zh-CN/mcp.json +0 -180
- package/dist/i18n/locales/zh-CN/memory.json +0 -23
- package/dist/i18n/locales/zh-CN/menu.json +0 -299
- package/dist/i18n/locales/zh-CN/multi-config.json +0 -79
- package/dist/i18n/locales/zh-CN/notification.json +0 -307
- package/dist/i18n/locales/zh-CN/permissions.json +0 -95
- package/dist/i18n/locales/zh-CN/persistence.json +0 -127
- package/dist/i18n/locales/zh-CN/plugins.json +0 -146
- package/dist/i18n/locales/zh-CN/quick-actions.json +0 -78
- package/dist/i18n/locales/zh-CN/registry.json +0 -54
- package/dist/i18n/locales/zh-CN/remote.json +0 -93
- package/dist/i18n/locales/zh-CN/sandbox.json +0 -44
- package/dist/i18n/locales/zh-CN/setup.json +0 -44
- package/dist/i18n/locales/zh-CN/shencha.json +0 -14
- package/dist/i18n/locales/zh-CN/skills.json +0 -100
- package/dist/i18n/locales/zh-CN/skillsSync.json +0 -74
- package/dist/i18n/locales/zh-CN/smartGuide.json +0 -49
- package/dist/i18n/locales/zh-CN/stats.json +0 -20
- package/dist/i18n/locales/zh-CN/subagent.json +0 -69
- package/dist/i18n/locales/zh-CN/superpowers.json +0 -117
- package/dist/i18n/locales/zh-CN/team.json +0 -7
- package/dist/i18n/locales/zh-CN/thinking.json +0 -65
- package/dist/i18n/locales/zh-CN/tools.json +0 -42
- package/dist/i18n/locales/zh-CN/uninstall.json +0 -56
- package/dist/i18n/locales/zh-CN/updater.json +0 -29
- package/dist/i18n/locales/zh-CN/vim.json +0 -169
- package/dist/i18n/locales/zh-CN/workflow.json +0 -55
- package/dist/i18n/locales/zh-CN/workspace.json +0 -108
- package/dist/index.d.mts +0 -5658
- package/dist/index.d.ts +0 -5658
- package/dist/index.mjs +0 -3732
- package/dist/shared/ccjk.5bEolFrk.mjs +0 -254
- package/dist/shared/ccjk.8oaxX4iR.mjs +0 -90
- package/dist/shared/ccjk.B2U7DsPy.mjs +0 -31
- package/dist/shared/ccjk.B2f-cwUP.mjs +0 -468
- package/dist/shared/ccjk.BAGoDD49.mjs +0 -36
- package/dist/shared/ccjk.BBtCGd_g.mjs +0 -899
- package/dist/shared/ccjk.BFQ7yr5S.mjs +0 -16
- package/dist/shared/ccjk.BLsIiTqO.mjs +0 -449
- package/dist/shared/ccjk.BXv8aYs1.mjs +0 -170
- package/dist/shared/ccjk.BnsY5WxD.mjs +0 -171
- package/dist/shared/ccjk.BoApaI4j.mjs +0 -28
- package/dist/shared/ccjk.Bq8TqZG_.mjs +0 -189
- package/dist/shared/ccjk.BtrioX1Z.mjs +0 -25
- package/dist/shared/ccjk.Bx_rmYfN.mjs +0 -69
- package/dist/shared/ccjk.BzPbSEP2.mjs +0 -115
- package/dist/shared/ccjk.C0WLUnFV.mjs +0 -293
- package/dist/shared/ccjk.C1hANZTu.mjs +0 -19
- package/dist/shared/ccjk.C2jHOZVP.mjs +0 -52
- package/dist/shared/ccjk.CNhnT6uQ.mjs +0 -636
- package/dist/shared/ccjk.COweQ1RR.mjs +0 -5
- package/dist/shared/ccjk.CfKKcvWy.mjs +0 -126
- package/dist/shared/ccjk.Cjgrln_h.mjs +0 -297
- package/dist/shared/ccjk.CoCHVXl3.mjs +0 -3951
- package/dist/shared/ccjk.CwGZSTAK.mjs +0 -319
- package/dist/shared/ccjk.CxpGa6MC.mjs +0 -2724
- package/dist/shared/ccjk.D-magaEx.mjs +0 -763
- package/dist/shared/ccjk.D0g2ABGg.mjs +0 -171
- package/dist/shared/ccjk.D6ycHbak.mjs +0 -270
- package/dist/shared/ccjk.D75wivnp.mjs +0 -142
- package/dist/shared/ccjk.DDL-4C-k.mjs +0 -100
- package/dist/shared/ccjk.DFRPtmK_.mjs +0 -75
- package/dist/shared/ccjk.DMV3x5Sd.mjs +0 -299
- package/dist/shared/ccjk.DZ2LLOa-.mjs +0 -2195
- package/dist/shared/ccjk.DbigonEQ.mjs +0 -698
- package/dist/shared/ccjk.DcMvE7lf.mjs +0 -618
- package/dist/shared/ccjk.DeWpAShp.mjs +0 -1828
- package/dist/shared/ccjk.DhJ1kyDR.mjs +0 -30
- package/dist/shared/ccjk.DlTXS9rP.mjs +0 -224
- package/dist/shared/ccjk.DopKzo3z.mjs +0 -305
- package/dist/shared/ccjk.DsZsc4LR.mjs +0 -1280
- package/dist/shared/ccjk.DuzJZlgj.mjs +0 -418
- package/dist/shared/ccjk.Dxgd2vjc.mjs +0 -444
- package/dist/shared/ccjk.J8YiPsOw.mjs +0 -259
- package/dist/shared/ccjk.KfSWcGlE.mjs +0 -38
- package/dist/shared/ccjk.L7yC58_i.mjs +0 -225
- package/dist/shared/ccjk.MwtjAULc.mjs +0 -1447
- package/dist/shared/ccjk.OJKHVSOb.mjs +0 -2005
- package/dist/shared/ccjk.OTnevPNE.mjs +0 -225
- package/dist/shared/ccjk.RyizuzOI.mjs +0 -21
- package/dist/shared/ccjk.T_cX87dY.mjs +0 -15
- package/dist/shared/ccjk.bQ7Dh1g4.mjs +0 -249
- package/dist/shared/ccjk.gDEDGD_t.mjs +0 -38
- package/dist/shared/ccjk.hoqrwWdN.mjs +0 -333
- package/dist/shared/ccjk.i_vn-9C3.mjs +0 -317
- package/dist/shared/ccjk.lG3ccFjm.mjs +0 -885
- package/dist/shared/ccjk.wLJHO0Af.mjs +0 -244
- package/dist/shared/ccjk.y-a_1vK4.mjs +0 -5127
- package/dist/templates/agents/README.md +0 -78
- package/dist/templates/agents/fullstack-developer.json +0 -70
- package/dist/templates/agents/go-expert.json +0 -69
- package/dist/templates/agents/index.json +0 -64
- package/dist/templates/agents/python-expert.json +0 -69
- package/dist/templates/agents/react-specialist.json +0 -69
- package/dist/templates/agents/testing-automation-expert.json +0 -70
- package/dist/templates/agents/typescript-architect.json +0 -69
- package/dist/templates/claude-code/common/settings.json +0 -109
- package/dist/templates/common/error-prevention.md +0 -267
- package/dist/templates/common/karpathy-baseline.md +0 -83
- package/dist/templates/common/output-styles/zh-CN/carmack-mode.md +0 -381
- package/dist/templates/common/output-styles/zh-CN/codex-rigor-mode.md +0 -114
- package/dist/templates/common/output-styles/zh-CN/dhh-mode.md +0 -265
- package/dist/templates/common/output-styles/zh-CN/evan-you-mode.md +0 -539
- package/dist/templates/common/output-styles/zh-CN/jobs-mode.md +0 -369
- package/dist/templates/common/output-styles/zh-CN/linus-mode.md +0 -135
- package/dist/templates/common/output-styles/zh-CN/uncle-bob-mode.md +0 -221
- package/dist/templates/common/workflow/continuousDelivery/en/continuous-delivery.md +0 -628
- package/dist/templates/common/workflow/continuousDelivery/zh-CN/continuous-delivery.md +0 -628
- package/dist/templates/common/workflow/essential/en/agents/ccjk-config-agent.md +0 -187
- package/dist/templates/common/workflow/essential/en/agents/ccjk-mcp-agent.md +0 -191
- package/dist/templates/common/workflow/essential/en/agents/ccjk-skill-agent.md +0 -249
- package/dist/templates/common/workflow/essential/en/agents/ccjk-workflow-agent.md +0 -277
- package/dist/templates/common/workflow/essential/en/agents/get-current-datetime.md +0 -29
- package/dist/templates/common/workflow/essential/en/agents/init-architect.md +0 -115
- package/dist/templates/common/workflow/essential/en/agents/ui-ux-designer.md +0 -91
- package/dist/templates/common/workflow/essential/en/feat.md +0 -92
- package/dist/templates/common/workflow/essential/en/goal.md +0 -147
- package/dist/templates/common/workflow/essential/en/init-project.md +0 -53
- package/dist/templates/common/workflow/essential/zh-CN/agents/get-current-datetime.md +0 -29
- package/dist/templates/common/workflow/essential/zh-CN/agents/init-architect.md +0 -115
- package/dist/templates/common/workflow/essential/zh-CN/agents/ui-ux-designer.md +0 -91
- package/dist/templates/common/workflow/essential/zh-CN/feat.md +0 -315
- package/dist/templates/common/workflow/essential/zh-CN/goal.md +0 -146
- package/dist/templates/common/workflow/essential/zh-CN/init-project.md +0 -53
- package/dist/templates/common/workflow/git/en/git-cleanBranches.md +0 -102
- package/dist/templates/common/workflow/git/en/git-commit.md +0 -205
- package/dist/templates/common/workflow/git/en/git-rollback.md +0 -90
- package/dist/templates/common/workflow/git/en/git-worktree.md +0 -276
- package/dist/templates/common/workflow/git/zh-CN/git-cleanBranches.md +0 -102
- package/dist/templates/common/workflow/git/zh-CN/git-commit.md +0 -205
- package/dist/templates/common/workflow/git/zh-CN/git-rollback.md +0 -90
- package/dist/templates/common/workflow/git/zh-CN/git-worktree.md +0 -276
- package/dist/templates/common/workflow/interview/en/interview.md +0 -67
- package/dist/templates/common/workflow/interview/zh-CN/interview.md +0 -67
- package/dist/templates/common/workflow/linearMethod/en/linear-method.md +0 -651
- package/dist/templates/common/workflow/linearMethod/zh-CN/linear-method.md +0 -752
- package/dist/templates/common/workflow/refactoringMaster/en/refactoring-master.md +0 -516
- package/dist/templates/common/workflow/refactoringMaster/zh-CN/refactoring-master.md +0 -812
- package/dist/templates/common/workflow/sixStep/en/workflow.md +0 -83
- package/dist/templates/common/workflow/sixStep/zh-CN/workflow.md +0 -359
- package/dist/templates/common/workflow/specFirstTDD/en/spec-first-tdd.md +0 -364
- package/dist/templates/common/workflow/specFirstTDD/zh-CN/spec-first-tdd.md +0 -366
- package/dist/templates/hooks/README.md +0 -212
- package/dist/templates/hooks/git-workflow-hooks.md +0 -551
- package/dist/templates/hooks/post-test/coverage.json +0 -21
- package/dist/templates/hooks/post-test/summary.json +0 -21
- package/dist/templates/hooks/post-test-coverage.md +0 -434
- package/dist/templates/hooks/pre-commit/eslint.json +0 -22
- package/dist/templates/hooks/pre-commit/prettier.json +0 -22
- package/dist/templates/hooks/pre-commit-black.md +0 -274
- package/dist/templates/hooks/pre-commit-eslint.md +0 -153
- package/dist/templates/hooks/pre-commit-gofmt.md +0 -284
- package/dist/templates/hooks/pre-commit-prettier.md +0 -212
- package/dist/templates/hooks/pre-commit-type-check.md +0 -377
- package/dist/templates/skills/ccjk-init.md +0 -154
- package/dist/templates/skills/ccjk-mcp-setup.md +0 -205
- package/dist/templates/skills/ccjk-troubleshoot.md +0 -228
- package/dist/templates/skills/django-patterns.md +0 -1016
- package/dist/templates/skills/git-workflow.md +0 -748
- package/dist/templates/skills/go-idioms.md +0 -963
- package/dist/templates/skills/index.json +0 -132
- package/dist/templates/skills/nextjs-optimization.md +0 -694
- package/dist/templates/skills/python-pep8.md +0 -852
- package/dist/templates/skills/react-patterns.md +0 -686
- package/dist/templates/skills/rust-patterns.md +0 -1057
- package/dist/templates/skills/security-best-practices.md +0 -1413
- package/dist/templates/skills/testing-best-practices.md +0 -1315
- package/dist/templates/skills/ts-best-practices.md +0 -354
- package/templates/agents/README.md +0 -78
- package/templates/agents/fullstack-developer.json +0 -70
- package/templates/agents/go-expert.json +0 -69
- package/templates/agents/index.json +0 -64
- package/templates/agents/python-expert.json +0 -69
- package/templates/agents/react-specialist.json +0 -69
- package/templates/agents/testing-automation-expert.json +0 -70
- package/templates/agents/typescript-architect.json +0 -69
- package/templates/claude-code/common/settings.json +0 -109
- package/templates/common/error-prevention.md +0 -267
- package/templates/common/karpathy-baseline.md +0 -83
- package/templates/common/output-styles/zh-CN/carmack-mode.md +0 -381
- package/templates/common/output-styles/zh-CN/codex-rigor-mode.md +0 -114
- package/templates/common/output-styles/zh-CN/dhh-mode.md +0 -265
- package/templates/common/output-styles/zh-CN/evan-you-mode.md +0 -539
- package/templates/common/output-styles/zh-CN/jobs-mode.md +0 -369
- package/templates/common/output-styles/zh-CN/linus-mode.md +0 -135
- package/templates/common/output-styles/zh-CN/uncle-bob-mode.md +0 -221
- package/templates/common/workflow/continuousDelivery/en/continuous-delivery.md +0 -628
- package/templates/common/workflow/continuousDelivery/zh-CN/continuous-delivery.md +0 -628
- package/templates/common/workflow/essential/en/agents/ccjk-config-agent.md +0 -187
- package/templates/common/workflow/essential/en/agents/ccjk-mcp-agent.md +0 -191
- package/templates/common/workflow/essential/en/agents/ccjk-skill-agent.md +0 -249
- package/templates/common/workflow/essential/en/agents/ccjk-workflow-agent.md +0 -277
- package/templates/common/workflow/essential/en/agents/get-current-datetime.md +0 -29
- package/templates/common/workflow/essential/en/agents/init-architect.md +0 -115
- package/templates/common/workflow/essential/en/agents/ui-ux-designer.md +0 -91
- package/templates/common/workflow/essential/en/feat.md +0 -92
- package/templates/common/workflow/essential/en/goal.md +0 -147
- package/templates/common/workflow/essential/en/init-project.md +0 -53
- package/templates/common/workflow/essential/zh-CN/agents/get-current-datetime.md +0 -29
- package/templates/common/workflow/essential/zh-CN/agents/init-architect.md +0 -115
- package/templates/common/workflow/essential/zh-CN/agents/ui-ux-designer.md +0 -91
- package/templates/common/workflow/essential/zh-CN/feat.md +0 -315
- package/templates/common/workflow/essential/zh-CN/goal.md +0 -146
- package/templates/common/workflow/essential/zh-CN/init-project.md +0 -53
- package/templates/common/workflow/git/en/git-cleanBranches.md +0 -102
- package/templates/common/workflow/git/en/git-commit.md +0 -205
- package/templates/common/workflow/git/en/git-rollback.md +0 -90
- package/templates/common/workflow/git/en/git-worktree.md +0 -276
- package/templates/common/workflow/git/zh-CN/git-cleanBranches.md +0 -102
- package/templates/common/workflow/git/zh-CN/git-commit.md +0 -205
- package/templates/common/workflow/git/zh-CN/git-rollback.md +0 -90
- package/templates/common/workflow/git/zh-CN/git-worktree.md +0 -276
- package/templates/common/workflow/interview/en/interview.md +0 -67
- package/templates/common/workflow/interview/zh-CN/interview.md +0 -67
- package/templates/common/workflow/linearMethod/en/linear-method.md +0 -651
- package/templates/common/workflow/linearMethod/zh-CN/linear-method.md +0 -752
- package/templates/common/workflow/refactoringMaster/en/refactoring-master.md +0 -516
- package/templates/common/workflow/refactoringMaster/zh-CN/refactoring-master.md +0 -812
- package/templates/common/workflow/sixStep/en/workflow.md +0 -83
- package/templates/common/workflow/sixStep/zh-CN/workflow.md +0 -359
- package/templates/common/workflow/specFirstTDD/en/spec-first-tdd.md +0 -364
- package/templates/common/workflow/specFirstTDD/zh-CN/spec-first-tdd.md +0 -366
- package/templates/hooks/README.md +0 -212
- package/templates/hooks/git-workflow-hooks.md +0 -551
- package/templates/hooks/post-test/coverage.json +0 -21
- package/templates/hooks/post-test/summary.json +0 -21
- package/templates/hooks/post-test-coverage.md +0 -434
- package/templates/hooks/pre-commit/eslint.json +0 -22
- package/templates/hooks/pre-commit/prettier.json +0 -22
- package/templates/hooks/pre-commit-black.md +0 -274
- package/templates/hooks/pre-commit-eslint.md +0 -153
- package/templates/hooks/pre-commit-gofmt.md +0 -284
- package/templates/hooks/pre-commit-prettier.md +0 -212
- package/templates/hooks/pre-commit-type-check.md +0 -377
- package/templates/skills/basic.hbs +0 -72
- package/templates/skills/ccjk-init.md +0 -154
- package/templates/skills/ccjk-mcp-setup.md +0 -205
- package/templates/skills/ccjk-troubleshoot.md +0 -228
- package/templates/skills/code-refactor.hbs +0 -133
- package/templates/skills/code-review.hbs +0 -141
- package/templates/skills/django-patterns.md +0 -1016
- package/templates/skills/git-workflow.md +0 -748
- package/templates/skills/go-idioms.md +0 -963
- package/templates/skills/index.json +0 -132
- package/templates/skills/nextjs-optimization.md +0 -694
- package/templates/skills/python-pep8.md +0 -852
- package/templates/skills/react-patterns.md +0 -686
- package/templates/skills/rust-patterns.md +0 -1057
- package/templates/skills/security-best-practices.md +0 -1413
- package/templates/skills/testing-best-practices.md +0 -1315
- package/templates/skills/ts-best-practices.md +0 -354
- package/templates/skills/type-fix.hbs +0 -132
|
@@ -1,265 +0,0 @@
|
|
|
1
|
-
import a from './index5.mjs';
|
|
2
|
-
import { i18n } from './index2.mjs';
|
|
3
|
-
import { g as getPackage, i as isPackageInstalled, a as getInstalledPackages, u as updatePackage, c as checkForUpdates, b as uninstallPackage, d as installPackage, s as searchPackages } from '../shared/ccjk.DbigonEQ.mjs';
|
|
4
|
-
import '../shared/ccjk.BAGoDD49.mjs';
|
|
5
|
-
import 'node:fs';
|
|
6
|
-
import 'node:process';
|
|
7
|
-
import 'node:url';
|
|
8
|
-
import '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
9
|
-
import 'node:crypto';
|
|
10
|
-
import 'node:fs/promises';
|
|
11
|
-
import 'node:os';
|
|
12
|
-
import 'node:stream';
|
|
13
|
-
import 'node:stream/promises';
|
|
14
|
-
import 'tar';
|
|
15
|
-
import './main.mjs';
|
|
16
|
-
import 'module';
|
|
17
|
-
import 'node:child_process';
|
|
18
|
-
import 'node:path';
|
|
19
|
-
import 'node:readline';
|
|
20
|
-
import './fs-operations.mjs';
|
|
21
|
-
|
|
22
|
-
async function searchCommand(query, _options) {
|
|
23
|
-
try {
|
|
24
|
-
console.log(a.green(i18n.t("marketplace:searching", { query })));
|
|
25
|
-
const results = await searchPackages({ query });
|
|
26
|
-
if (results.packages.length === 0) {
|
|
27
|
-
console.log(a.yellow(i18n.t("marketplace:noResults")));
|
|
28
|
-
return;
|
|
29
|
-
}
|
|
30
|
-
console.log(a.green(i18n.t("marketplace:searchResults", { count: results.packages.length })));
|
|
31
|
-
console.log();
|
|
32
|
-
for (const pkg of results.packages) {
|
|
33
|
-
const installed = await isPackageInstalled(pkg.name);
|
|
34
|
-
const installedMark = installed ? a.green("\u2713") : a.gray("\u25CB");
|
|
35
|
-
console.log(`${installedMark} ${a.bold(pkg.name)} ${a.gray(`v${pkg.version}`)}`);
|
|
36
|
-
console.log(` ${pkg.description.en || Object.values(pkg.description)[0]}`);
|
|
37
|
-
console.log(` ${a.gray(i18n.t("marketplace:packageInfo.category"))}: ${pkg.category}`);
|
|
38
|
-
if (pkg.verified === "verified") {
|
|
39
|
-
console.log(` ${a.green("\u2713")} ${i18n.t("marketplace:packageInfo.verified")}`);
|
|
40
|
-
}
|
|
41
|
-
console.log();
|
|
42
|
-
}
|
|
43
|
-
} catch (err) {
|
|
44
|
-
console.error(a.red(i18n.t("marketplace:searchFailed")));
|
|
45
|
-
console.error(err);
|
|
46
|
-
throw err;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
async function installCommand(packageName, options) {
|
|
50
|
-
try {
|
|
51
|
-
if (await isPackageInstalled(packageName)) {
|
|
52
|
-
console.log(a.yellow(`Package '${packageName}' is already installed`));
|
|
53
|
-
return;
|
|
54
|
-
}
|
|
55
|
-
const pkg = await getPackage(packageName);
|
|
56
|
-
if (!pkg) {
|
|
57
|
-
console.error(a.red(i18n.t("marketplace:packageNotFound", { name: packageName })));
|
|
58
|
-
throw new Error(`Package not found: ${packageName}`);
|
|
59
|
-
}
|
|
60
|
-
console.log(a.green(i18n.t("marketplace:installing", { name: packageName })));
|
|
61
|
-
const result = await installPackage(packageName, {
|
|
62
|
-
force: options.force,
|
|
63
|
-
skipVerification: options.skipVerification
|
|
64
|
-
});
|
|
65
|
-
if (result.success) {
|
|
66
|
-
console.log(a.green(i18n.t("marketplace:installSuccess", { name: packageName })));
|
|
67
|
-
if (result.installedPath) {
|
|
68
|
-
console.log(a.gray(`${i18n.t("marketplace:installedAt")}: ${result.installedPath}`));
|
|
69
|
-
}
|
|
70
|
-
} else {
|
|
71
|
-
console.error(a.red(i18n.t("marketplace:installFailed", { name: packageName })));
|
|
72
|
-
if (result.error) {
|
|
73
|
-
console.error(a.red(i18n.t("marketplace:errors.installError", { error: result.error })));
|
|
74
|
-
}
|
|
75
|
-
throw new Error(`Install failed: ${packageName}`);
|
|
76
|
-
}
|
|
77
|
-
} catch (err) {
|
|
78
|
-
console.error(a.red(i18n.t("marketplace:installFailed", { name: packageName })));
|
|
79
|
-
console.error(err);
|
|
80
|
-
throw err;
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
async function uninstallCommand(packageName, options) {
|
|
84
|
-
try {
|
|
85
|
-
if (!await isPackageInstalled(packageName)) {
|
|
86
|
-
console.error(a.red(i18n.t("marketplace:packageNotInstalled", { name: packageName })));
|
|
87
|
-
throw new Error(`Package not installed: ${packageName}`);
|
|
88
|
-
}
|
|
89
|
-
console.log(a.green(i18n.t("marketplace:uninstalling", { name: packageName })));
|
|
90
|
-
const result = await uninstallPackage(packageName, {
|
|
91
|
-
force: options.force
|
|
92
|
-
});
|
|
93
|
-
if (result.success) {
|
|
94
|
-
console.log(a.green(i18n.t("marketplace:uninstallSuccess", { name: packageName })));
|
|
95
|
-
} else {
|
|
96
|
-
console.error(a.red(i18n.t("marketplace:uninstallFailed", { name: packageName })));
|
|
97
|
-
if (result.error) {
|
|
98
|
-
console.error(a.red(i18n.t("marketplace:errors.uninstallError", { error: result.error })));
|
|
99
|
-
}
|
|
100
|
-
throw new Error(`Uninstall failed: ${packageName}`);
|
|
101
|
-
}
|
|
102
|
-
} catch (err) {
|
|
103
|
-
console.error(a.red(i18n.t("marketplace:uninstallFailed", { name: packageName })));
|
|
104
|
-
console.error(err);
|
|
105
|
-
throw err;
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
async function updateCommand(packageName, _options) {
|
|
109
|
-
try {
|
|
110
|
-
if (packageName) {
|
|
111
|
-
console.log(a.green(i18n.t("marketplace:updating", { name: packageName })));
|
|
112
|
-
const result = await updatePackage(packageName);
|
|
113
|
-
if (result.success) {
|
|
114
|
-
console.log(a.green(i18n.t("marketplace:updateSuccess", { name: packageName })));
|
|
115
|
-
} else {
|
|
116
|
-
console.error(a.red(i18n.t("marketplace:updateFailed", { name: packageName })));
|
|
117
|
-
if (result.error) {
|
|
118
|
-
console.error(a.red(result.error));
|
|
119
|
-
}
|
|
120
|
-
throw new Error(`Update failed: ${packageName}`);
|
|
121
|
-
}
|
|
122
|
-
} else {
|
|
123
|
-
console.log(a.green(i18n.t("marketplace:checkingUpdates")));
|
|
124
|
-
const updates = await checkForUpdates();
|
|
125
|
-
if (updates.length === 0) {
|
|
126
|
-
console.log(a.green(i18n.t("marketplace:noUpdates")));
|
|
127
|
-
return;
|
|
128
|
-
}
|
|
129
|
-
console.log(a.yellow(i18n.t("marketplace:updatesAvailable", { count: updates.length })));
|
|
130
|
-
console.log();
|
|
131
|
-
for (const update of updates) {
|
|
132
|
-
console.log(` ${a.bold(update.id)}: ${a.gray(update.currentVersion)} \u2192 ${a.green(update.latestVersion)}`);
|
|
133
|
-
}
|
|
134
|
-
console.log();
|
|
135
|
-
console.log(a.gray(i18n.t("marketplace:updateHint")));
|
|
136
|
-
}
|
|
137
|
-
} catch (err) {
|
|
138
|
-
console.error(a.red(i18n.t("marketplace:updateCheckFailed")));
|
|
139
|
-
console.error(err);
|
|
140
|
-
throw err;
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
async function listCommand(_options) {
|
|
144
|
-
try {
|
|
145
|
-
const installedList = await getInstalledPackages();
|
|
146
|
-
if (installedList.length === 0) {
|
|
147
|
-
console.log(a.yellow(i18n.t("marketplace:noInstalled")));
|
|
148
|
-
return;
|
|
149
|
-
}
|
|
150
|
-
console.log(a.green(i18n.t("marketplace:installedPackages", { count: installedList.length })));
|
|
151
|
-
console.log();
|
|
152
|
-
for (const installed of installedList) {
|
|
153
|
-
const pkg = installed.package;
|
|
154
|
-
console.log(`${a.green("\u2713")} ${a.bold(pkg.name)} ${a.gray(`v${pkg.version}`)}`);
|
|
155
|
-
console.log(` ${pkg.description.en || Object.values(pkg.description)[0]}`);
|
|
156
|
-
console.log(` ${a.gray(i18n.t("marketplace:packageInfo.category"))}: ${pkg.category}`);
|
|
157
|
-
console.log();
|
|
158
|
-
}
|
|
159
|
-
} catch (err) {
|
|
160
|
-
console.error(a.red(i18n.t("marketplace:listFailed")));
|
|
161
|
-
console.error(err);
|
|
162
|
-
throw err;
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
async function infoCommand(packageName, _options) {
|
|
166
|
-
try {
|
|
167
|
-
const pkg = await getPackage(packageName);
|
|
168
|
-
if (!pkg) {
|
|
169
|
-
console.error(a.red(i18n.t("marketplace:packageNotFound", { name: packageName })));
|
|
170
|
-
throw new Error(`Package not found: ${packageName}`);
|
|
171
|
-
}
|
|
172
|
-
const installed = await isPackageInstalled(packageName);
|
|
173
|
-
console.log();
|
|
174
|
-
console.log(a.bold.cyan(pkg.name));
|
|
175
|
-
console.log(a.gray("\u2500".repeat(50)));
|
|
176
|
-
console.log();
|
|
177
|
-
console.log(`${a.bold(i18n.t("marketplace:packageInfo.description"))}: ${pkg.description.en || Object.values(pkg.description)[0]}`);
|
|
178
|
-
console.log(`${a.bold(i18n.t("marketplace:packageInfo.version"))}: ${pkg.version}`);
|
|
179
|
-
console.log(`${a.bold(i18n.t("marketplace:packageInfo.category"))}: ${pkg.category}`);
|
|
180
|
-
if (pkg.author) {
|
|
181
|
-
console.log(`${a.bold(i18n.t("marketplace:packageInfo.author"))}: ${pkg.author}`);
|
|
182
|
-
}
|
|
183
|
-
if (pkg.license) {
|
|
184
|
-
console.log(`${a.bold(i18n.t("marketplace:packageInfo.license"))}: ${pkg.license}`);
|
|
185
|
-
}
|
|
186
|
-
if (pkg.repository) {
|
|
187
|
-
console.log(`${a.bold(i18n.t("marketplace:packageInfo.repository"))}: ${pkg.repository}`);
|
|
188
|
-
}
|
|
189
|
-
if (pkg.downloads !== void 0) {
|
|
190
|
-
console.log(`${a.bold(i18n.t("marketplace:packageInfo.downloads"))}: ${pkg.downloads.toLocaleString()}`);
|
|
191
|
-
}
|
|
192
|
-
if (pkg.rating !== void 0) {
|
|
193
|
-
const stars = "\u2605".repeat(Math.round(pkg.rating));
|
|
194
|
-
const emptyStars = "\u2606".repeat(5 - Math.round(pkg.rating));
|
|
195
|
-
console.log(`${a.bold(i18n.t("marketplace:packageInfo.rating"))}: ${a.yellow(stars)}${a.gray(emptyStars)} (${pkg.rating}/5)`);
|
|
196
|
-
}
|
|
197
|
-
if (pkg.keywords && pkg.keywords.length > 0) {
|
|
198
|
-
console.log(`${a.bold(i18n.t("marketplace:packageInfo.keywords"))}: ${pkg.keywords.join(", ")}`);
|
|
199
|
-
}
|
|
200
|
-
if (pkg.verified === "verified") {
|
|
201
|
-
console.log(`${a.green("\u2713")} ${i18n.t("marketplace:packageInfo.verified")}`);
|
|
202
|
-
}
|
|
203
|
-
console.log();
|
|
204
|
-
console.log(`${a.bold("Status")}: ${installed ? a.green("Installed") : a.gray("Not installed")}`);
|
|
205
|
-
console.log();
|
|
206
|
-
} catch (err) {
|
|
207
|
-
console.error(a.red(i18n.t("marketplace:infoFailed")));
|
|
208
|
-
console.error(err);
|
|
209
|
-
throw err;
|
|
210
|
-
}
|
|
211
|
-
}
|
|
212
|
-
async function marketplaceMenu(action, options) {
|
|
213
|
-
const opts = options || {};
|
|
214
|
-
if (!action) {
|
|
215
|
-
console.log(a.green("\n\u{1F6D2} Marketplace Commands:\n"));
|
|
216
|
-
console.log(" ccjk cloud plugins search <query> - Search packages");
|
|
217
|
-
console.log(" ccjk cloud plugins install <pkg> - Install package");
|
|
218
|
-
console.log(" ccjk cloud plugins uninstall <pkg> - Uninstall package");
|
|
219
|
-
console.log(" ccjk cloud plugins update [pkg] - Update packages");
|
|
220
|
-
console.log(" ccjk cloud plugins list - List installed");
|
|
221
|
-
console.log(" ccjk cloud plugins info <pkg> - Package details\n");
|
|
222
|
-
return;
|
|
223
|
-
}
|
|
224
|
-
const args = action.split(" ");
|
|
225
|
-
const cmd = args[0];
|
|
226
|
-
const param = args.slice(1).join(" ");
|
|
227
|
-
switch (cmd) {
|
|
228
|
-
case "search":
|
|
229
|
-
if (param)
|
|
230
|
-
await searchCommand(param);
|
|
231
|
-
else
|
|
232
|
-
console.log(a.yellow("Usage: ccjk cloud plugins search <query>"));
|
|
233
|
-
break;
|
|
234
|
-
case "install":
|
|
235
|
-
if (param)
|
|
236
|
-
await installCommand(param, opts);
|
|
237
|
-
else
|
|
238
|
-
console.log(a.yellow("Usage: ccjk cloud plugins install <package>"));
|
|
239
|
-
break;
|
|
240
|
-
case "uninstall":
|
|
241
|
-
if (param)
|
|
242
|
-
await uninstallCommand(param, opts);
|
|
243
|
-
else
|
|
244
|
-
console.log(a.yellow("Usage: ccjk cloud plugins uninstall <package>"));
|
|
245
|
-
break;
|
|
246
|
-
case "update":
|
|
247
|
-
await updateCommand(param || void 0);
|
|
248
|
-
break;
|
|
249
|
-
case "list":
|
|
250
|
-
case "ls":
|
|
251
|
-
await listCommand();
|
|
252
|
-
break;
|
|
253
|
-
case "info":
|
|
254
|
-
if (param)
|
|
255
|
-
await infoCommand(param);
|
|
256
|
-
else
|
|
257
|
-
console.log(a.yellow("Usage: ccjk cloud plugins info <package>"));
|
|
258
|
-
break;
|
|
259
|
-
default:
|
|
260
|
-
console.log(a.yellow(`Unknown action: ${cmd}`));
|
|
261
|
-
await marketplaceMenu(void 0, opts);
|
|
262
|
-
}
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
export { marketplaceMenu };
|
package/dist/chunks/mcp-cli.mjs
DELETED
|
@@ -1,205 +0,0 @@
|
|
|
1
|
-
import a from './index5.mjs';
|
|
2
|
-
import { g as getMcpServices, r as readMcpConfig } from './claude-config.mjs';
|
|
3
|
-
import { i18n } from './index2.mjs';
|
|
4
|
-
import { i as installMcpService, u as uninstallMcpService } from '../shared/ccjk.CwGZSTAK.mjs';
|
|
5
|
-
import '../shared/ccjk.BAGoDD49.mjs';
|
|
6
|
-
import 'node:child_process';
|
|
7
|
-
import 'node:process';
|
|
8
|
-
import './constants.mjs';
|
|
9
|
-
import 'node:os';
|
|
10
|
-
import '../shared/ccjk.bQ7Dh1g4.mjs';
|
|
11
|
-
import '../shared/ccjk.DDL-4C-k.mjs';
|
|
12
|
-
import './ccjk-config.mjs';
|
|
13
|
-
import 'node:fs';
|
|
14
|
-
import '../shared/ccjk.BBtCGd_g.mjs';
|
|
15
|
-
import './index3.mjs';
|
|
16
|
-
import './fs-operations.mjs';
|
|
17
|
-
import 'node:crypto';
|
|
18
|
-
import 'node:fs/promises';
|
|
19
|
-
import './json-config.mjs';
|
|
20
|
-
import '../shared/ccjk.RyizuzOI.mjs';
|
|
21
|
-
import './platform.mjs';
|
|
22
|
-
import './main.mjs';
|
|
23
|
-
import 'module';
|
|
24
|
-
import 'node:path';
|
|
25
|
-
import 'node:stream';
|
|
26
|
-
import 'node:readline';
|
|
27
|
-
import 'node:url';
|
|
28
|
-
import './index6.mjs';
|
|
29
|
-
import 'stream';
|
|
30
|
-
import 'node:tty';
|
|
31
|
-
import 'node:async_hooks';
|
|
32
|
-
import '../shared/ccjk.Cjgrln_h.mjs';
|
|
33
|
-
import 'node:util';
|
|
34
|
-
import 'tty';
|
|
35
|
-
import 'fs';
|
|
36
|
-
import 'child_process';
|
|
37
|
-
import 'buffer';
|
|
38
|
-
import 'string_decoder';
|
|
39
|
-
import './codex.mjs';
|
|
40
|
-
import './index8.mjs';
|
|
41
|
-
import '../shared/ccjk.DeWpAShp.mjs';
|
|
42
|
-
import '../shared/ccjk.CxpGa6MC.mjs';
|
|
43
|
-
import './config.mjs';
|
|
44
|
-
import '../shared/ccjk.BFQ7yr5S.mjs';
|
|
45
|
-
import './prompts.mjs';
|
|
46
|
-
import '../shared/ccjk.gDEDGD_t.mjs';
|
|
47
|
-
import '../shared/ccjk.DZ2LLOa-.mjs';
|
|
48
|
-
|
|
49
|
-
async function mcpInstallCli(options) {
|
|
50
|
-
const lang = options.lang || i18n.language || "en";
|
|
51
|
-
const isZh = lang === "zh-CN";
|
|
52
|
-
if (!options.services || options.services.length === 0) {
|
|
53
|
-
console.log(a.red(isZh ? "\u9519\u8BEF: \u5FC5\u987B\u6307\u5B9A\u670D\u52A1\u540D\u79F0" : "Error: Service names required"));
|
|
54
|
-
console.log(a.dim(isZh ? "\u7528\u6CD5: ccjk mcp install <service1> [service2...]" : "Usage: ccjk mcp install <service1> [service2...]"));
|
|
55
|
-
process.exit(1);
|
|
56
|
-
}
|
|
57
|
-
const availableServices = await getMcpServices();
|
|
58
|
-
const invalidServices = options.services.filter(
|
|
59
|
-
(s) => !availableServices.some((svc) => svc.id === s)
|
|
60
|
-
);
|
|
61
|
-
if (invalidServices.length > 0) {
|
|
62
|
-
console.log(a.red(isZh ? `\u9519\u8BEF: \u672A\u77E5\u7684\u670D\u52A1: ${invalidServices.join(", ")}` : `Error: Unknown services: ${invalidServices.join(", ")}`));
|
|
63
|
-
console.log(a.dim(isZh ? "\u63D0\u793A: \u4F7F\u7528 ccjk mcp list \u67E5\u770B\u53EF\u7528\u670D\u52A1" : "Tip: Use ccjk mcp list to see available services"));
|
|
64
|
-
process.exit(1);
|
|
65
|
-
}
|
|
66
|
-
if (!options.yes) {
|
|
67
|
-
const inquirer = await import('./index6.mjs').then(function (n) { return n.c; });
|
|
68
|
-
const { confirm } = await inquirer.default.prompt([{
|
|
69
|
-
type: "confirm",
|
|
70
|
-
name: "confirm",
|
|
71
|
-
message: isZh ? `\u786E\u8BA4\u5B89\u88C5 ${options.services.length} \u4E2A MCP \u670D\u52A1?` : `Install ${options.services.length} MCP service(s)?`,
|
|
72
|
-
default: true
|
|
73
|
-
}]);
|
|
74
|
-
if (!confirm) {
|
|
75
|
-
console.log(a.yellow(isZh ? "\u5DF2\u53D6\u6D88" : "Cancelled"));
|
|
76
|
-
return;
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
let successCount = 0;
|
|
80
|
-
let failCount = 0;
|
|
81
|
-
for (const serviceId of options.services) {
|
|
82
|
-
const result = await installMcpService(serviceId, options.tool);
|
|
83
|
-
if (result.success) {
|
|
84
|
-
successCount++;
|
|
85
|
-
} else {
|
|
86
|
-
failCount++;
|
|
87
|
-
console.log(a.red(isZh ? `\u2717 \u5B89\u88C5 ${serviceId} \u5931\u8D25: ${result.error || "\u672A\u77E5\u9519\u8BEF"}` : `\u2717 Failed to install ${serviceId}: ${result.error || "Unknown error"}`));
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
if (successCount > 0) {
|
|
91
|
-
console.log(a.green(isZh ? `\u2713 \u5DF2\u5B89\u88C5 ${successCount} \u4E2A\u670D\u52A1` : `\u2713 Installed ${successCount} service(s)`));
|
|
92
|
-
}
|
|
93
|
-
if (failCount > 0) {
|
|
94
|
-
console.log(a.red(isZh ? `\u2717 ${failCount} \u4E2A\u670D\u52A1\u5B89\u88C5\u5931\u8D25` : `\u2717 ${failCount} service(s) failed`));
|
|
95
|
-
}
|
|
96
|
-
if (successCount > 0) {
|
|
97
|
-
console.log(a.dim(isZh ? "\u63D0\u793A: \u91CD\u542F Claude Code \u4EE5\u5E94\u7528\u66F4\u6539" : "Tip: Restart Claude Code to apply changes"));
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
async function mcpUninstallCli(options) {
|
|
101
|
-
const lang = options.lang || i18n.language || "en";
|
|
102
|
-
const isZh = lang === "zh-CN";
|
|
103
|
-
if (!options.services || options.services.length === 0) {
|
|
104
|
-
console.log(a.red(isZh ? "\u9519\u8BEF: \u5FC5\u987B\u6307\u5B9A\u670D\u52A1\u540D\u79F0" : "Error: Service names required"));
|
|
105
|
-
console.log(a.dim(isZh ? "\u7528\u6CD5: ccjk mcp uninstall <service1> [service2...]" : "Usage: ccjk mcp uninstall <service1> [service2...]"));
|
|
106
|
-
process.exit(1);
|
|
107
|
-
}
|
|
108
|
-
const config = readMcpConfig(options.tool);
|
|
109
|
-
if (!config || !config.mcpServers) {
|
|
110
|
-
console.log(a.yellow(isZh ? "\u672A\u5B89\u88C5\u4EFB\u4F55 MCP \u670D\u52A1" : "No MCP services installed"));
|
|
111
|
-
return;
|
|
112
|
-
}
|
|
113
|
-
const notInstalled = options.services.filter((s) => !config.mcpServers[s]);
|
|
114
|
-
if (notInstalled.length > 0) {
|
|
115
|
-
console.log(a.yellow(isZh ? `\u8B66\u544A: \u4EE5\u4E0B\u670D\u52A1\u672A\u5B89\u88C5: ${notInstalled.join(", ")}` : `Warning: Not installed: ${notInstalled.join(", ")}`));
|
|
116
|
-
}
|
|
117
|
-
const toRemove = options.services.filter((s) => config.mcpServers[s]);
|
|
118
|
-
if (toRemove.length === 0) {
|
|
119
|
-
console.log(a.yellow(isZh ? "\u6CA1\u6709\u670D\u52A1\u9700\u8981\u5378\u8F7D" : "No services to uninstall"));
|
|
120
|
-
return;
|
|
121
|
-
}
|
|
122
|
-
if (!options.yes) {
|
|
123
|
-
const inquirer = await import('./index6.mjs').then(function (n) { return n.c; });
|
|
124
|
-
const { confirm } = await inquirer.default.prompt([{
|
|
125
|
-
type: "confirm",
|
|
126
|
-
name: "confirm",
|
|
127
|
-
message: isZh ? `\u786E\u8BA4\u5378\u8F7D ${toRemove.length} \u4E2A MCP \u670D\u52A1?` : `Uninstall ${toRemove.length} MCP service(s)?`,
|
|
128
|
-
default: true
|
|
129
|
-
}]);
|
|
130
|
-
if (!confirm) {
|
|
131
|
-
console.log(a.yellow(isZh ? "\u5DF2\u53D6\u6D88" : "Cancelled"));
|
|
132
|
-
return;
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
let successCount = 0;
|
|
136
|
-
let failCount = 0;
|
|
137
|
-
for (const serviceId of toRemove) {
|
|
138
|
-
const result = await uninstallMcpService(serviceId, options.tool);
|
|
139
|
-
if (result.success) {
|
|
140
|
-
successCount++;
|
|
141
|
-
} else {
|
|
142
|
-
failCount++;
|
|
143
|
-
console.log(a.red(isZh ? `\u2717 \u5378\u8F7D ${serviceId} \u5931\u8D25: ${result.error || "\u672A\u77E5\u9519\u8BEF"}` : `\u2717 Failed to uninstall ${serviceId}: ${result.error || "Unknown error"}`));
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
if (successCount > 0) {
|
|
147
|
-
console.log(a.green(isZh ? `\u2713 \u5DF2\u5378\u8F7D ${successCount} \u4E2A\u670D\u52A1` : `\u2713 Uninstalled ${successCount} service(s)`));
|
|
148
|
-
}
|
|
149
|
-
if (failCount > 0) {
|
|
150
|
-
console.log(a.red(isZh ? `\u2717 ${failCount} \u4E2A\u670D\u52A1\u5378\u8F7D\u5931\u8D25` : `\u2717 ${failCount} service(s) failed`));
|
|
151
|
-
}
|
|
152
|
-
if (successCount > 0) {
|
|
153
|
-
console.log(a.dim(isZh ? "\u63D0\u793A: \u91CD\u542F Claude Code \u4EE5\u5E94\u7528\u66F4\u6539" : "Tip: Restart Claude Code to apply changes"));
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
async function mcpListCli(options = {}) {
|
|
157
|
-
const lang = options.lang || i18n.language || "en";
|
|
158
|
-
const isZh = lang === "zh-CN";
|
|
159
|
-
const availableServices = await getMcpServices();
|
|
160
|
-
const config = readMcpConfig(options.tool);
|
|
161
|
-
const installedServices = Object.keys(config?.mcpServers || {});
|
|
162
|
-
if (options.json) {
|
|
163
|
-
const output = {
|
|
164
|
-
installed: installedServices,
|
|
165
|
-
available: availableServices.map((s) => ({
|
|
166
|
-
id: s.id,
|
|
167
|
-
name: s.name,
|
|
168
|
-
description: s.description,
|
|
169
|
-
installed: installedServices.includes(s.id)
|
|
170
|
-
}))
|
|
171
|
-
};
|
|
172
|
-
console.log(JSON.stringify(output, null, 2));
|
|
173
|
-
return;
|
|
174
|
-
}
|
|
175
|
-
console.log("");
|
|
176
|
-
console.log(a.bold.cyan(isZh ? "\u{1F4E6} MCP \u670D\u52A1" : "\u{1F4E6} MCP Services"));
|
|
177
|
-
console.log(a.dim("\u2500".repeat(50)));
|
|
178
|
-
console.log("");
|
|
179
|
-
if (options.installed) {
|
|
180
|
-
if (installedServices.length === 0) {
|
|
181
|
-
console.log(a.yellow(isZh ? "\u672A\u5B89\u88C5\u4EFB\u4F55\u670D\u52A1" : "No services installed"));
|
|
182
|
-
} else {
|
|
183
|
-
console.log(a.green(isZh ? `\u5DF2\u5B89\u88C5 ${installedServices.length} \u4E2A\u670D\u52A1:` : `${installedServices.length} service(s) installed:`));
|
|
184
|
-
for (const serviceId of installedServices) {
|
|
185
|
-
const service = availableServices.find((s) => s.id === serviceId);
|
|
186
|
-
const name = service ? service.name : serviceId;
|
|
187
|
-
console.log(` ${a.green("\u25CF")} ${name} ${a.dim(`(${serviceId})`)}`);
|
|
188
|
-
}
|
|
189
|
-
}
|
|
190
|
-
} else {
|
|
191
|
-
console.log(a.dim(isZh ? "\u53EF\u7528\u670D\u52A1:" : "Available services:"));
|
|
192
|
-
for (const service of availableServices) {
|
|
193
|
-
const installed = installedServices.includes(service.id);
|
|
194
|
-
const icon = installed ? a.green("\u2713") : a.dim("\u25CB");
|
|
195
|
-
const name = service.name;
|
|
196
|
-
const desc = service.description;
|
|
197
|
-
console.log(` ${icon} ${a.bold(name)} ${a.dim(`(${service.id})`)}`);
|
|
198
|
-
console.log(` ${a.dim(desc)}`);
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
console.log("");
|
|
202
|
-
console.log(a.dim(isZh ? "\u63D0\u793A: \u4F7F\u7528 ccjk mcp install <service> \u5B89\u88C5\u670D\u52A1" : "Tip: Use ccjk mcp install <service> to install a service"));
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
export { mcpInstallCli, mcpListCli, mcpUninstallCli };
|
|
@@ -1,187 +0,0 @@
|
|
|
1
|
-
const MCP_TIER_DEFAULTS = {
|
|
2
|
-
core: {
|
|
3
|
-
tier: "core",
|
|
4
|
-
autoStart: true,
|
|
5
|
-
idleTimeout: void 0,
|
|
6
|
-
// Never timeout
|
|
7
|
-
description: "Essential services, always available"
|
|
8
|
-
},
|
|
9
|
-
ondemand: {
|
|
10
|
-
tier: "ondemand",
|
|
11
|
-
autoStart: false,
|
|
12
|
-
idleTimeout: 300,
|
|
13
|
-
// 5 minutes
|
|
14
|
-
description: "Loaded when needed, auto-released after idle"
|
|
15
|
-
},
|
|
16
|
-
scenario: {
|
|
17
|
-
tier: "scenario",
|
|
18
|
-
autoStart: false,
|
|
19
|
-
idleTimeout: 600,
|
|
20
|
-
// 10 minutes
|
|
21
|
-
description: "Loaded for specific scenarios"
|
|
22
|
-
}
|
|
23
|
-
};
|
|
24
|
-
const MCP_SERVICE_TIERS = {
|
|
25
|
-
// Core services - high frequency, essential
|
|
26
|
-
"context7": "core",
|
|
27
|
-
"open-websearch": "core",
|
|
28
|
-
// On-demand services - medium frequency
|
|
29
|
-
"mcp-deepwiki": "ondemand",
|
|
30
|
-
"Playwright": "ondemand",
|
|
31
|
-
// Removed: puppeteer (duplicate of Playwright), filesystem (buggy),
|
|
32
|
-
// memory (Claude built-in), sequential-thinking (limited value), fetch (Claude WebFetch)
|
|
33
|
-
// Scenario services - low frequency, specific use cases
|
|
34
|
-
"sqlite": "scenario",
|
|
35
|
-
"spec-workflow": "scenario",
|
|
36
|
-
"serena": "scenario"
|
|
37
|
-
};
|
|
38
|
-
function getMcpTierConfig(serviceId) {
|
|
39
|
-
const tier = MCP_SERVICE_TIERS[serviceId] || "ondemand";
|
|
40
|
-
return MCP_TIER_DEFAULTS[tier];
|
|
41
|
-
}
|
|
42
|
-
function getServicesByTier(tier) {
|
|
43
|
-
return Object.entries(MCP_SERVICE_TIERS).filter(([_, t]) => t === tier).map(([id]) => id);
|
|
44
|
-
}
|
|
45
|
-
function isCoreService(serviceId) {
|
|
46
|
-
return MCP_SERVICE_TIERS[serviceId] === "core";
|
|
47
|
-
}
|
|
48
|
-
const MCP_PERFORMANCE_THRESHOLDS = {
|
|
49
|
-
/** Warning threshold for number of services */
|
|
50
|
-
warningCount: 5,
|
|
51
|
-
/** Critical threshold for number of services */
|
|
52
|
-
criticalCount: 8,
|
|
53
|
-
/** Maximum recommended services */
|
|
54
|
-
maxRecommended: 6,
|
|
55
|
-
/** Estimated memory per service (MB) */
|
|
56
|
-
estimatedMemoryPerService: 50,
|
|
57
|
-
/** Estimated CPU overhead per service (%) */
|
|
58
|
-
estimatedCpuPerService: 5
|
|
59
|
-
};
|
|
60
|
-
|
|
61
|
-
const mcpTiers = {
|
|
62
|
-
__proto__: null,
|
|
63
|
-
MCP_PERFORMANCE_THRESHOLDS: MCP_PERFORMANCE_THRESHOLDS,
|
|
64
|
-
MCP_SERVICE_TIERS: MCP_SERVICE_TIERS,
|
|
65
|
-
MCP_TIER_DEFAULTS: MCP_TIER_DEFAULTS,
|
|
66
|
-
getMcpTierConfig: getMcpTierConfig,
|
|
67
|
-
getServicesByTier: getServicesByTier,
|
|
68
|
-
isCoreService: isCoreService
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
function checkMcpPerformance(serviceCount) {
|
|
72
|
-
const { warningCount, criticalCount, estimatedMemoryPerService, estimatedCpuPerService } = MCP_PERFORMANCE_THRESHOLDS;
|
|
73
|
-
const estimatedMemory = serviceCount * estimatedMemoryPerService;
|
|
74
|
-
const estimatedCpu = serviceCount * estimatedCpuPerService;
|
|
75
|
-
if (serviceCount >= criticalCount) {
|
|
76
|
-
return {
|
|
77
|
-
level: "critical",
|
|
78
|
-
message: `\u26A0\uFE0F ${serviceCount} MCP services configured - may cause severe performance issues`,
|
|
79
|
-
messageZh: `\u26A0\uFE0F \u5DF2\u914D\u7F6E ${serviceCount} \u4E2A MCP \u670D\u52A1\uFF0C\u53EF\u80FD\u5BFC\u81F4\u4E25\u91CD\u6027\u80FD\u95EE\u9898`,
|
|
80
|
-
suggestion: "Use `ccjk mcp profile use minimal` to switch to minimal mode",
|
|
81
|
-
suggestionZh: "\u5EFA\u8BAE\u4F7F\u7528 `ccjk mcp profile use minimal` \u5207\u6362\u5230\u6781\u7B80\u6A21\u5F0F",
|
|
82
|
-
serviceCount,
|
|
83
|
-
estimatedMemory,
|
|
84
|
-
estimatedCpu
|
|
85
|
-
};
|
|
86
|
-
}
|
|
87
|
-
if (serviceCount >= warningCount) {
|
|
88
|
-
return {
|
|
89
|
-
level: "warning",
|
|
90
|
-
message: `\u26A1 ${serviceCount} MCP services configured - may affect response speed`,
|
|
91
|
-
messageZh: `\u26A1 \u5DF2\u914D\u7F6E ${serviceCount} \u4E2A MCP \u670D\u52A1\uFF0C\u53EF\u80FD\u5F71\u54CD\u54CD\u5E94\u901F\u5EA6`,
|
|
92
|
-
suggestion: "Consider disabling unused services or use `ccjk mcp profile` to manage",
|
|
93
|
-
suggestionZh: "\u5EFA\u8BAE\u7981\u7528\u4E0D\u5E38\u7528\u7684\u670D\u52A1\uFF0C\u6216\u4F7F\u7528 `ccjk mcp profile` \u7BA1\u7406",
|
|
94
|
-
serviceCount,
|
|
95
|
-
estimatedMemory,
|
|
96
|
-
estimatedCpu
|
|
97
|
-
};
|
|
98
|
-
}
|
|
99
|
-
return null;
|
|
100
|
-
}
|
|
101
|
-
function analyzeServices(serviceIds) {
|
|
102
|
-
return serviceIds.map((serviceId) => {
|
|
103
|
-
const tierConfig = getMcpTierConfig(serviceId);
|
|
104
|
-
const tier = MCP_SERVICE_TIERS[serviceId] || "ondemand";
|
|
105
|
-
const analysis = {
|
|
106
|
-
serviceId,
|
|
107
|
-
tier,
|
|
108
|
-
autoStart: tierConfig.autoStart,
|
|
109
|
-
idleTimeout: tierConfig.idleTimeout
|
|
110
|
-
};
|
|
111
|
-
if (tier !== "core") {
|
|
112
|
-
analysis.recommendation = `Consider using on-demand loading for ${serviceId}`;
|
|
113
|
-
analysis.recommendationZh = `\u5EFA\u8BAE\u5BF9 ${serviceId} \u4F7F\u7528\u6309\u9700\u52A0\u8F7D`;
|
|
114
|
-
}
|
|
115
|
-
return analysis;
|
|
116
|
-
});
|
|
117
|
-
}
|
|
118
|
-
function getOptimizationSuggestions(serviceIds) {
|
|
119
|
-
const suggestions = [];
|
|
120
|
-
const analysis = analyzeServices(serviceIds);
|
|
121
|
-
const tierCounts = {
|
|
122
|
-
core: 0,
|
|
123
|
-
ondemand: 0,
|
|
124
|
-
scenario: 0
|
|
125
|
-
};
|
|
126
|
-
for (const a of analysis) {
|
|
127
|
-
tierCounts[a.tier]++;
|
|
128
|
-
}
|
|
129
|
-
if (tierCounts.scenario > 2) {
|
|
130
|
-
suggestions.push("Consider disabling some scenario-specific services when not needed");
|
|
131
|
-
}
|
|
132
|
-
const hasBothBrowserServices = serviceIds.includes("Playwright") && serviceIds.includes("puppeteer");
|
|
133
|
-
if (hasBothBrowserServices) {
|
|
134
|
-
suggestions.push("Both Playwright and Puppeteer are enabled - consider using only one");
|
|
135
|
-
}
|
|
136
|
-
if (serviceIds.length > MCP_PERFORMANCE_THRESHOLDS.maxRecommended) {
|
|
137
|
-
suggestions.push(`You have ${serviceIds.length} services. Recommended maximum is ${MCP_PERFORMANCE_THRESHOLDS.maxRecommended}`);
|
|
138
|
-
}
|
|
139
|
-
if (tierCounts.core === 0) {
|
|
140
|
-
suggestions.push("Consider enabling core services (context7, open-websearch) for better experience");
|
|
141
|
-
}
|
|
142
|
-
return suggestions;
|
|
143
|
-
}
|
|
144
|
-
function calculateResourceUsage(serviceCount) {
|
|
145
|
-
const { estimatedMemoryPerService, estimatedCpuPerService, warningCount, criticalCount } = MCP_PERFORMANCE_THRESHOLDS;
|
|
146
|
-
const memory = serviceCount * estimatedMemoryPerService;
|
|
147
|
-
const cpu = serviceCount * estimatedCpuPerService;
|
|
148
|
-
let rating;
|
|
149
|
-
if (serviceCount >= criticalCount) {
|
|
150
|
-
rating = "critical";
|
|
151
|
-
} else if (serviceCount >= warningCount) {
|
|
152
|
-
rating = "high";
|
|
153
|
-
} else if (serviceCount >= 3) {
|
|
154
|
-
rating = "medium";
|
|
155
|
-
} else {
|
|
156
|
-
rating = "low";
|
|
157
|
-
}
|
|
158
|
-
return {
|
|
159
|
-
memory: { value: memory, unit: "MB" },
|
|
160
|
-
cpu: { value: cpu, unit: "%" },
|
|
161
|
-
rating
|
|
162
|
-
};
|
|
163
|
-
}
|
|
164
|
-
function formatPerformanceWarning(warning, lang = "en") {
|
|
165
|
-
const message = lang === "zh-CN" ? warning.messageZh : warning.message;
|
|
166
|
-
const suggestion = lang === "zh-CN" ? warning.suggestionZh : warning.suggestion;
|
|
167
|
-
const lines = [
|
|
168
|
-
message,
|
|
169
|
-
"",
|
|
170
|
-
` ${lang === "zh-CN" ? "\u9884\u4F30\u5185\u5B58" : "Est. Memory"}: ~${warning.estimatedMemory}MB`,
|
|
171
|
-
` ${lang === "zh-CN" ? "\u9884\u4F30CPU" : "Est. CPU"}: ~${warning.estimatedCpu}%`,
|
|
172
|
-
"",
|
|
173
|
-
`\u{1F4A1} ${suggestion}`
|
|
174
|
-
];
|
|
175
|
-
return lines.join("\n");
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
const mcpPerformance = {
|
|
179
|
-
__proto__: null,
|
|
180
|
-
analyzeServices: analyzeServices,
|
|
181
|
-
calculateResourceUsage: calculateResourceUsage,
|
|
182
|
-
checkMcpPerformance: checkMcpPerformance,
|
|
183
|
-
formatPerformanceWarning: formatPerformanceWarning,
|
|
184
|
-
getOptimizationSuggestions: getOptimizationSuggestions
|
|
185
|
-
};
|
|
186
|
-
|
|
187
|
-
export { MCP_SERVICE_TIERS as M, calculateResourceUsage as a, getOptimizationSuggestions as b, checkMcpPerformance as c, getMcpTierConfig as d, mcpPerformance as e, formatPerformanceWarning as f, getServicesByTier as g, isCoreService as i, mcpTiers as m };
|