agentsys 5.1.0 → 5.2.1
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/.claude-plugin/marketplace.json +105 -42
- package/.claude-plugin/plugin.json +2 -2
- package/AGENTS.md +2 -15
- package/CHANGELOG.md +55 -5
- package/README.md +143 -45
- package/SECURITY.md +1 -1
- package/adapters/README.md +6 -6
- package/adapters/codex/README.md +3 -3
- package/adapters/codex/install.sh +2 -2
- package/adapters/opencode/README.md +3 -3
- package/adapters/opencode/install.sh +2 -2
- package/agent-knowledge/AGENTS.md +144 -5
- package/agent-knowledge/all-in-one-plus-modular-packages.md +576 -0
- package/agent-knowledge/cli-browser-automation-agents.md +936 -0
- package/agent-knowledge/github-org-project-management.md +319 -0
- package/agent-knowledge/github-org-structure-patterns.md +268 -0
- package/agent-knowledge/multi-product-org-docs.md +622 -0
- package/agent-knowledge/oss-org-naming-patterns.md +368 -0
- package/agent-knowledge/resources/all-in-one-plus-modular-packages-sources.json +310 -0
- package/agent-knowledge/resources/cli-browser-automation-agents-sources.json +428 -0
- package/agent-knowledge/resources/github-org-project-management-sources.json +239 -0
- package/agent-knowledge/resources/github-org-structure-patterns-sources.json +293 -0
- package/agent-knowledge/resources/multi-product-org-docs-sources.json +514 -0
- package/agent-knowledge/resources/oss-org-naming-patterns-sources.json +458 -0
- package/agent-knowledge/resources/skill-plugin-distribution-patterns-sources.json +290 -0
- package/agent-knowledge/resources/terminal-browsers-agent-automation-sources.json +758 -0
- package/agent-knowledge/resources/web-session-persistence-cli-agents-sources.json +528 -0
- package/agent-knowledge/skill-plugin-distribution-patterns.md +661 -0
- package/agent-knowledge/terminal-browsers-agent-automation.md +776 -0
- package/agent-knowledge/web-session-persistence-cli-agents.md +1352 -0
- package/bin/cli.js +1369 -18
- package/bin/dev-cli.js +15 -24
- package/lib/adapter-transforms.js +147 -3
- package/lib/cross-platform/index.js +7 -3
- package/lib/discovery/index.js +26 -1
- package/lib/index.js +2 -0
- package/lib/package.json +1 -1
- package/lib/patterns/cli-enhancers.js +11 -2
- package/lib/sources/policy-questions.js +76 -2
- package/lib/state/workflow-state.js +18 -7
- package/meta/skills/maintain-cross-platform/SKILL.md +1 -1
- package/package.json +4 -4
- package/scripts/bump-version.js +1 -6
- package/scripts/dev-install.js +1 -1
- package/scripts/fix-graduated-repos.js +288 -0
- package/scripts/graduate-plugin.js +433 -0
- package/scripts/preflight.js +19 -48
- package/scripts/scaffold.js +2 -2
- package/scripts/setup-hooks.js +2 -9
- package/scripts/stamp-version.js +3 -34
- package/scripts/validate-agent-skill-compliance.js +2 -0
- package/scripts/validate-counts.js +27 -0
- package/site/assets/css/design-system/base.css +151 -0
- package/site/assets/css/design-system/tokens.css +354 -0
- package/site/assets/css/tokens.css +5 -469
- package/site/content.json +13 -13
- package/site/index.html +14 -13
- package/site/ux-spec.md +7 -7
- package/adapters/codex/skills/agnix/SKILL.md +0 -137
- package/adapters/codex/skills/audit-project/SKILL.md +0 -333
- package/adapters/codex/skills/audit-project-agents/SKILL.md +0 -458
- package/adapters/codex/skills/audit-project-github/SKILL.md +0 -145
- package/adapters/codex/skills/consult/SKILL.md +0 -320
- package/adapters/codex/skills/debate/SKILL.md +0 -214
- package/adapters/codex/skills/delivery-approval/SKILL.md +0 -338
- package/adapters/codex/skills/deslop/SKILL.md +0 -166
- package/adapters/codex/skills/drift-detect/SKILL.md +0 -267
- package/adapters/codex/skills/enhance/SKILL.md +0 -176
- package/adapters/codex/skills/learn/SKILL.md +0 -187
- package/adapters/codex/skills/next-task/SKILL.md +0 -545
- package/adapters/codex/skills/perf/SKILL.md +0 -468
- package/adapters/codex/skills/repo-map/SKILL.md +0 -131
- package/adapters/codex/skills/ship/SKILL.md +0 -490
- package/adapters/codex/skills/ship-ci-review-loop/SKILL.md +0 -472
- package/adapters/codex/skills/ship-deployment/SKILL.md +0 -335
- package/adapters/codex/skills/ship-error-handling/SKILL.md +0 -259
- package/adapters/codex/skills/sync-docs/SKILL.md +0 -185
- package/adapters/opencode/agents/agent-enhancer.md +0 -64
- package/adapters/opencode/agents/agnix-agent.md +0 -55
- package/adapters/opencode/agents/ci-fixer.md +0 -103
- package/adapters/opencode/agents/ci-monitor.md +0 -126
- package/adapters/opencode/agents/claudemd-enhancer.md +0 -65
- package/adapters/opencode/agents/consult-agent.md +0 -216
- package/adapters/opencode/agents/cross-file-enhancer.md +0 -53
- package/adapters/opencode/agents/debate-orchestrator.md +0 -169
- package/adapters/opencode/agents/delivery-validator.md +0 -114
- package/adapters/opencode/agents/deslop-agent.md +0 -87
- package/adapters/opencode/agents/docs-enhancer.md +0 -64
- package/adapters/opencode/agents/exploration-agent.md +0 -142
- package/adapters/opencode/agents/hooks-enhancer.md +0 -65
- package/adapters/opencode/agents/implementation-agent.md +0 -205
- package/adapters/opencode/agents/learn-agent.md +0 -278
- package/adapters/opencode/agents/map-validator.md +0 -64
- package/adapters/opencode/agents/perf-analyzer.md +0 -39
- package/adapters/opencode/agents/perf-code-paths.md +0 -11
- package/adapters/opencode/agents/perf-investigation-logger.md +0 -43
- package/adapters/opencode/agents/perf-orchestrator.md +0 -146
- package/adapters/opencode/agents/perf-theory-gatherer.md +0 -17
- package/adapters/opencode/agents/perf-theory-tester.md +0 -42
- package/adapters/opencode/agents/plan-synthesizer.md +0 -228
- package/adapters/opencode/agents/planning-agent.md +0 -234
- package/adapters/opencode/agents/plugin-enhancer.md +0 -63
- package/adapters/opencode/agents/prompt-enhancer.md +0 -57
- package/adapters/opencode/agents/simple-fixer.md +0 -106
- package/adapters/opencode/agents/skills-enhancer.md +0 -65
- package/adapters/opencode/agents/sync-docs-agent.md +0 -152
- package/adapters/opencode/agents/task-discoverer.md +0 -79
- package/adapters/opencode/agents/test-coverage-checker.md +0 -143
- package/adapters/opencode/agents/worktree-manager.md +0 -208
- package/adapters/opencode/commands/agnix.md +0 -105
- package/adapters/opencode/commands/audit-project-agents.md +0 -124
- package/adapters/opencode/commands/audit-project-github.md +0 -144
- package/adapters/opencode/commands/audit-project.md +0 -267
- package/adapters/opencode/commands/consult.md +0 -328
- package/adapters/opencode/commands/debate.md +0 -224
- package/adapters/opencode/commands/delivery-approval.md +0 -211
- package/adapters/opencode/commands/deslop.md +0 -131
- package/adapters/opencode/commands/drift-detect.md +0 -172
- package/adapters/opencode/commands/enhance.md +0 -182
- package/adapters/opencode/commands/learn.md +0 -115
- package/adapters/opencode/commands/next-task.md +0 -392
- package/adapters/opencode/commands/perf.md +0 -48
- package/adapters/opencode/commands/repo-map.md +0 -68
- package/adapters/opencode/commands/ship-ci-review-loop.md +0 -333
- package/adapters/opencode/commands/ship-deployment.md +0 -335
- package/adapters/opencode/commands/ship-error-handling.md +0 -247
- package/adapters/opencode/commands/ship.md +0 -370
- package/adapters/opencode/commands/sync-docs.md +0 -107
- package/adapters/opencode/skills/agnix/SKILL.md +0 -138
- package/adapters/opencode/skills/consult/SKILL.md +0 -318
- package/adapters/opencode/skills/debate/SKILL.md +0 -245
- package/adapters/opencode/skills/deslop/SKILL.md +0 -168
- package/adapters/opencode/skills/discover-tasks/SKILL.md +0 -101
- package/adapters/opencode/skills/drift-analysis/SKILL.md +0 -278
- package/adapters/opencode/skills/enhance-agent-prompts/SKILL.md +0 -278
- package/adapters/opencode/skills/enhance-claude-memory/SKILL.md +0 -389
- package/adapters/opencode/skills/enhance-cross-file/SKILL.md +0 -111
- package/adapters/opencode/skills/enhance-docs/SKILL.md +0 -287
- package/adapters/opencode/skills/enhance-hooks/SKILL.md +0 -556
- package/adapters/opencode/skills/enhance-orchestrator/SKILL.md +0 -113
- package/adapters/opencode/skills/enhance-plugins/SKILL.md +0 -313
- package/adapters/opencode/skills/enhance-prompts/SKILL.md +0 -340
- package/adapters/opencode/skills/enhance-skills/SKILL.md +0 -442
- package/adapters/opencode/skills/learn/SKILL.md +0 -351
- package/adapters/opencode/skills/orchestrate-review/SKILL.md +0 -94
- package/adapters/opencode/skills/perf-analyzer/SKILL.md +0 -37
- package/adapters/opencode/skills/perf-baseline-manager/SKILL.md +0 -30
- package/adapters/opencode/skills/perf-benchmarker/SKILL.md +0 -48
- package/adapters/opencode/skills/perf-code-paths/SKILL.md +0 -32
- package/adapters/opencode/skills/perf-investigation-logger/SKILL.md +0 -41
- package/adapters/opencode/skills/perf-profiler/SKILL.md +0 -38
- package/adapters/opencode/skills/perf-theory-gatherer/SKILL.md +0 -35
- package/adapters/opencode/skills/perf-theory-tester/SKILL.md +0 -36
- package/adapters/opencode/skills/repo-mapping/SKILL.md +0 -85
- package/adapters/opencode/skills/sync-docs/SKILL.md +0 -245
- package/adapters/opencode/skills/validate-delivery/SKILL.md +0 -111
- package/plugins/agnix/.claude-plugin/plugin.json +0 -22
- package/plugins/agnix/agents/agnix-agent.md +0 -56
- package/plugins/agnix/commands/agnix.md +0 -139
- package/plugins/agnix/skills/agnix/SKILL.md +0 -138
- package/plugins/audit-project/.claude-plugin/plugin.json +0 -20
- package/plugins/audit-project/commands/audit-project-agents.md +0 -458
- package/plugins/audit-project/commands/audit-project-github.md +0 -144
- package/plugins/audit-project/commands/audit-project.md +0 -336
- package/plugins/audit-project/lib/adapter-transforms.js +0 -298
- package/plugins/audit-project/lib/collectors/codebase.js +0 -392
- package/plugins/audit-project/lib/collectors/docs-patterns.js +0 -713
- package/plugins/audit-project/lib/collectors/documentation.js +0 -219
- package/plugins/audit-project/lib/collectors/github.js +0 -330
- package/plugins/audit-project/lib/collectors/index.js +0 -126
- package/plugins/audit-project/lib/config/index.js +0 -14
- package/plugins/audit-project/lib/cross-platform/index.js +0 -539
- package/plugins/audit-project/lib/discovery/index.js +0 -352
- package/plugins/audit-project/lib/drift-detect/collectors.js +0 -37
- package/plugins/audit-project/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/audit-project/lib/enhance/agent-patterns.js +0 -571
- package/plugins/audit-project/lib/enhance/auto-suppression.js +0 -622
- package/plugins/audit-project/lib/enhance/benchmark.js +0 -417
- package/plugins/audit-project/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/audit-project/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/audit-project/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/audit-project/lib/enhance/docs-patterns.js +0 -671
- package/plugins/audit-project/lib/enhance/fixer.js +0 -721
- package/plugins/audit-project/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/audit-project/lib/enhance/hook-patterns.js +0 -40
- package/plugins/audit-project/lib/enhance/index.js +0 -127
- package/plugins/audit-project/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/audit-project/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/audit-project/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/audit-project/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/audit-project/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/audit-project/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/audit-project/lib/enhance/reporter.js +0 -1348
- package/plugins/audit-project/lib/enhance/security-patterns.js +0 -284
- package/plugins/audit-project/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/audit-project/lib/enhance/skill-patterns.js +0 -147
- package/plugins/audit-project/lib/enhance/suppression.js +0 -352
- package/plugins/audit-project/lib/enhance/tool-patterns.js +0 -373
- package/plugins/audit-project/lib/index.js +0 -270
- package/plugins/audit-project/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/audit-project/lib/patterns/pipeline.js +0 -948
- package/plugins/audit-project/lib/patterns/review-patterns.js +0 -558
- package/plugins/audit-project/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/audit-project/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/audit-project/lib/perf/analyzer/index.js +0 -22
- package/plugins/audit-project/lib/perf/argument-parser.js +0 -105
- package/plugins/audit-project/lib/perf/baseline-comparator.js +0 -50
- package/plugins/audit-project/lib/perf/baseline-store.js +0 -127
- package/plugins/audit-project/lib/perf/benchmark-runner.js +0 -404
- package/plugins/audit-project/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/audit-project/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/audit-project/lib/perf/checkpoint.js +0 -123
- package/plugins/audit-project/lib/perf/code-paths.js +0 -86
- package/plugins/audit-project/lib/perf/consolidation.js +0 -37
- package/plugins/audit-project/lib/perf/constraint-runner.js +0 -71
- package/plugins/audit-project/lib/perf/experiment-runner.js +0 -32
- package/plugins/audit-project/lib/perf/index.js +0 -41
- package/plugins/audit-project/lib/perf/investigation-state.js +0 -874
- package/plugins/audit-project/lib/perf/optimization-runner.js +0 -79
- package/plugins/audit-project/lib/perf/profilers/go.js +0 -22
- package/plugins/audit-project/lib/perf/profilers/index.js +0 -46
- package/plugins/audit-project/lib/perf/profilers/java.js +0 -23
- package/plugins/audit-project/lib/perf/profilers/node.js +0 -27
- package/plugins/audit-project/lib/perf/profilers/python.js +0 -23
- package/plugins/audit-project/lib/perf/profilers/rust.js +0 -23
- package/plugins/audit-project/lib/perf/profiling-runner.js +0 -75
- package/plugins/audit-project/lib/perf/schemas.js +0 -140
- package/plugins/audit-project/lib/platform/detect-platform.js +0 -413
- package/plugins/audit-project/lib/platform/detection-configs.js +0 -93
- package/plugins/audit-project/lib/platform/state-dir.js +0 -132
- package/plugins/audit-project/lib/platform/verify-tools.js +0 -182
- package/plugins/audit-project/lib/repo-map/cache.js +0 -152
- package/plugins/audit-project/lib/repo-map/concurrency.js +0 -29
- package/plugins/audit-project/lib/repo-map/index.js +0 -222
- package/plugins/audit-project/lib/repo-map/installer.js +0 -212
- package/plugins/audit-project/lib/repo-map/queries/go.js +0 -27
- package/plugins/audit-project/lib/repo-map/queries/index.js +0 -100
- package/plugins/audit-project/lib/repo-map/queries/java.js +0 -38
- package/plugins/audit-project/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/audit-project/lib/repo-map/queries/python.js +0 -24
- package/plugins/audit-project/lib/repo-map/queries/rust.js +0 -73
- package/plugins/audit-project/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/audit-project/lib/repo-map/runner.js +0 -1364
- package/plugins/audit-project/lib/repo-map/updater.js +0 -562
- package/plugins/audit-project/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/audit-project/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/audit-project/lib/schemas/validator.js +0 -247
- package/plugins/audit-project/lib/sources/custom-handler.js +0 -199
- package/plugins/audit-project/lib/sources/policy-questions.js +0 -246
- package/plugins/audit-project/lib/sources/source-cache.js +0 -165
- package/plugins/audit-project/lib/state/workflow-state.js +0 -576
- package/plugins/audit-project/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/audit-project/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/audit-project/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/audit-project/lib/types/index.d.ts +0 -84
- package/plugins/audit-project/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/audit-project/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/audit-project/lib/utils/atomic-write.js +0 -94
- package/plugins/audit-project/lib/utils/cache-manager.js +0 -159
- package/plugins/audit-project/lib/utils/command-parser.js +0 -0
- package/plugins/audit-project/lib/utils/context-optimizer.js +0 -300
- package/plugins/audit-project/lib/utils/deprecation.js +0 -37
- package/plugins/audit-project/lib/utils/shell-escape.js +0 -88
- package/plugins/audit-project/lib/utils/state-helpers.js +0 -61
- package/plugins/consult/.claude-plugin/plugin.json +0 -24
- package/plugins/consult/agents/consult-agent.md +0 -222
- package/plugins/consult/commands/consult.md +0 -325
- package/plugins/consult/skills/consult/SKILL.md +0 -312
- package/plugins/debate/.claude-plugin/plugin.json +0 -21
- package/plugins/debate/agents/debate-orchestrator.md +0 -175
- package/plugins/debate/commands/debate.md +0 -221
- package/plugins/debate/lib/adapter-transforms.js +0 -298
- package/plugins/debate/lib/collectors/codebase.js +0 -392
- package/plugins/debate/lib/collectors/docs-patterns.js +0 -713
- package/plugins/debate/lib/collectors/documentation.js +0 -219
- package/plugins/debate/lib/collectors/github.js +0 -330
- package/plugins/debate/lib/collectors/index.js +0 -126
- package/plugins/debate/lib/config/index.js +0 -14
- package/plugins/debate/lib/cross-platform/index.js +0 -539
- package/plugins/debate/lib/discovery/index.js +0 -352
- package/plugins/debate/lib/drift-detect/collectors.js +0 -37
- package/plugins/debate/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/debate/lib/enhance/agent-patterns.js +0 -571
- package/plugins/debate/lib/enhance/auto-suppression.js +0 -622
- package/plugins/debate/lib/enhance/benchmark.js +0 -417
- package/plugins/debate/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/debate/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/debate/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/debate/lib/enhance/docs-patterns.js +0 -671
- package/plugins/debate/lib/enhance/fixer.js +0 -721
- package/plugins/debate/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/debate/lib/enhance/hook-patterns.js +0 -40
- package/plugins/debate/lib/enhance/index.js +0 -127
- package/plugins/debate/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/debate/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/debate/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/debate/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/debate/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/debate/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/debate/lib/enhance/reporter.js +0 -1348
- package/plugins/debate/lib/enhance/security-patterns.js +0 -284
- package/plugins/debate/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/debate/lib/enhance/skill-patterns.js +0 -147
- package/plugins/debate/lib/enhance/suppression.js +0 -352
- package/plugins/debate/lib/enhance/tool-patterns.js +0 -373
- package/plugins/debate/lib/index.js +0 -270
- package/plugins/debate/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/debate/lib/patterns/pipeline.js +0 -948
- package/plugins/debate/lib/patterns/review-patterns.js +0 -558
- package/plugins/debate/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/debate/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/debate/lib/perf/analyzer/index.js +0 -22
- package/plugins/debate/lib/perf/argument-parser.js +0 -105
- package/plugins/debate/lib/perf/baseline-comparator.js +0 -50
- package/plugins/debate/lib/perf/baseline-store.js +0 -127
- package/plugins/debate/lib/perf/benchmark-runner.js +0 -404
- package/plugins/debate/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/debate/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/debate/lib/perf/checkpoint.js +0 -123
- package/plugins/debate/lib/perf/code-paths.js +0 -86
- package/plugins/debate/lib/perf/consolidation.js +0 -37
- package/plugins/debate/lib/perf/constraint-runner.js +0 -71
- package/plugins/debate/lib/perf/experiment-runner.js +0 -32
- package/plugins/debate/lib/perf/index.js +0 -41
- package/plugins/debate/lib/perf/investigation-state.js +0 -874
- package/plugins/debate/lib/perf/optimization-runner.js +0 -79
- package/plugins/debate/lib/perf/profilers/go.js +0 -22
- package/plugins/debate/lib/perf/profilers/index.js +0 -46
- package/plugins/debate/lib/perf/profilers/java.js +0 -23
- package/plugins/debate/lib/perf/profilers/node.js +0 -27
- package/plugins/debate/lib/perf/profilers/python.js +0 -23
- package/plugins/debate/lib/perf/profilers/rust.js +0 -23
- package/plugins/debate/lib/perf/profiling-runner.js +0 -75
- package/plugins/debate/lib/perf/schemas.js +0 -140
- package/plugins/debate/lib/platform/detect-platform.js +0 -413
- package/plugins/debate/lib/platform/detection-configs.js +0 -93
- package/plugins/debate/lib/platform/state-dir.js +0 -132
- package/plugins/debate/lib/platform/verify-tools.js +0 -182
- package/plugins/debate/lib/repo-map/cache.js +0 -152
- package/plugins/debate/lib/repo-map/concurrency.js +0 -29
- package/plugins/debate/lib/repo-map/index.js +0 -222
- package/plugins/debate/lib/repo-map/installer.js +0 -212
- package/plugins/debate/lib/repo-map/queries/go.js +0 -27
- package/plugins/debate/lib/repo-map/queries/index.js +0 -100
- package/plugins/debate/lib/repo-map/queries/java.js +0 -38
- package/plugins/debate/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/debate/lib/repo-map/queries/python.js +0 -24
- package/plugins/debate/lib/repo-map/queries/rust.js +0 -73
- package/plugins/debate/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/debate/lib/repo-map/runner.js +0 -1364
- package/plugins/debate/lib/repo-map/updater.js +0 -562
- package/plugins/debate/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/debate/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/debate/lib/schemas/validator.js +0 -247
- package/plugins/debate/lib/sources/custom-handler.js +0 -199
- package/plugins/debate/lib/sources/policy-questions.js +0 -246
- package/plugins/debate/lib/sources/source-cache.js +0 -165
- package/plugins/debate/lib/state/workflow-state.js +0 -576
- package/plugins/debate/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/debate/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/debate/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/debate/lib/types/index.d.ts +0 -84
- package/plugins/debate/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/debate/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/debate/lib/utils/atomic-write.js +0 -94
- package/plugins/debate/lib/utils/cache-manager.js +0 -159
- package/plugins/debate/lib/utils/command-parser.js +0 -0
- package/plugins/debate/lib/utils/context-optimizer.js +0 -300
- package/plugins/debate/lib/utils/deprecation.js +0 -37
- package/plugins/debate/lib/utils/shell-escape.js +0 -88
- package/plugins/debate/lib/utils/state-helpers.js +0 -61
- package/plugins/debate/skills/debate/SKILL.md +0 -264
- package/plugins/deslop/.claude-plugin/plugin.json +0 -20
- package/plugins/deslop/agents/deslop-agent.md +0 -88
- package/plugins/deslop/commands/deslop.md +0 -168
- package/plugins/deslop/lib/adapter-transforms.js +0 -298
- package/plugins/deslop/lib/collectors/codebase.js +0 -392
- package/plugins/deslop/lib/collectors/docs-patterns.js +0 -713
- package/plugins/deslop/lib/collectors/documentation.js +0 -219
- package/plugins/deslop/lib/collectors/github.js +0 -330
- package/plugins/deslop/lib/collectors/index.js +0 -126
- package/plugins/deslop/lib/config/index.js +0 -14
- package/plugins/deslop/lib/cross-platform/index.js +0 -539
- package/plugins/deslop/lib/discovery/index.js +0 -352
- package/plugins/deslop/lib/drift-detect/collectors.js +0 -37
- package/plugins/deslop/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/deslop/lib/enhance/agent-patterns.js +0 -571
- package/plugins/deslop/lib/enhance/auto-suppression.js +0 -622
- package/plugins/deslop/lib/enhance/benchmark.js +0 -417
- package/plugins/deslop/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/deslop/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/deslop/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/deslop/lib/enhance/docs-patterns.js +0 -671
- package/plugins/deslop/lib/enhance/fixer.js +0 -721
- package/plugins/deslop/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/deslop/lib/enhance/hook-patterns.js +0 -40
- package/plugins/deslop/lib/enhance/index.js +0 -127
- package/plugins/deslop/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/deslop/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/deslop/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/deslop/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/deslop/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/deslop/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/deslop/lib/enhance/reporter.js +0 -1348
- package/plugins/deslop/lib/enhance/security-patterns.js +0 -284
- package/plugins/deslop/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/deslop/lib/enhance/skill-patterns.js +0 -147
- package/plugins/deslop/lib/enhance/suppression.js +0 -352
- package/plugins/deslop/lib/enhance/tool-patterns.js +0 -373
- package/plugins/deslop/lib/index.js +0 -270
- package/plugins/deslop/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/deslop/lib/patterns/pipeline.js +0 -948
- package/plugins/deslop/lib/patterns/review-patterns.js +0 -558
- package/plugins/deslop/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/deslop/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/deslop/lib/perf/analyzer/index.js +0 -22
- package/plugins/deslop/lib/perf/argument-parser.js +0 -105
- package/plugins/deslop/lib/perf/baseline-comparator.js +0 -50
- package/plugins/deslop/lib/perf/baseline-store.js +0 -127
- package/plugins/deslop/lib/perf/benchmark-runner.js +0 -404
- package/plugins/deslop/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/deslop/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/deslop/lib/perf/checkpoint.js +0 -123
- package/plugins/deslop/lib/perf/code-paths.js +0 -86
- package/plugins/deslop/lib/perf/consolidation.js +0 -37
- package/plugins/deslop/lib/perf/constraint-runner.js +0 -71
- package/plugins/deslop/lib/perf/experiment-runner.js +0 -32
- package/plugins/deslop/lib/perf/index.js +0 -41
- package/plugins/deslop/lib/perf/investigation-state.js +0 -874
- package/plugins/deslop/lib/perf/optimization-runner.js +0 -79
- package/plugins/deslop/lib/perf/profilers/go.js +0 -22
- package/plugins/deslop/lib/perf/profilers/index.js +0 -46
- package/plugins/deslop/lib/perf/profilers/java.js +0 -23
- package/plugins/deslop/lib/perf/profilers/node.js +0 -27
- package/plugins/deslop/lib/perf/profilers/python.js +0 -23
- package/plugins/deslop/lib/perf/profilers/rust.js +0 -23
- package/plugins/deslop/lib/perf/profiling-runner.js +0 -75
- package/plugins/deslop/lib/perf/schemas.js +0 -140
- package/plugins/deslop/lib/platform/detect-platform.js +0 -413
- package/plugins/deslop/lib/platform/detection-configs.js +0 -93
- package/plugins/deslop/lib/platform/state-dir.js +0 -132
- package/plugins/deslop/lib/platform/verify-tools.js +0 -182
- package/plugins/deslop/lib/repo-map/cache.js +0 -152
- package/plugins/deslop/lib/repo-map/concurrency.js +0 -29
- package/plugins/deslop/lib/repo-map/index.js +0 -222
- package/plugins/deslop/lib/repo-map/installer.js +0 -212
- package/plugins/deslop/lib/repo-map/queries/go.js +0 -27
- package/plugins/deslop/lib/repo-map/queries/index.js +0 -100
- package/plugins/deslop/lib/repo-map/queries/java.js +0 -38
- package/plugins/deslop/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/deslop/lib/repo-map/queries/python.js +0 -24
- package/plugins/deslop/lib/repo-map/queries/rust.js +0 -73
- package/plugins/deslop/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/deslop/lib/repo-map/runner.js +0 -1364
- package/plugins/deslop/lib/repo-map/updater.js +0 -562
- package/plugins/deslop/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/deslop/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/deslop/lib/schemas/validator.js +0 -247
- package/plugins/deslop/lib/sources/custom-handler.js +0 -199
- package/plugins/deslop/lib/sources/policy-questions.js +0 -246
- package/plugins/deslop/lib/sources/source-cache.js +0 -165
- package/plugins/deslop/lib/state/workflow-state.js +0 -576
- package/plugins/deslop/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/deslop/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/deslop/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/deslop/lib/types/index.d.ts +0 -84
- package/plugins/deslop/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/deslop/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/deslop/lib/utils/atomic-write.js +0 -94
- package/plugins/deslop/lib/utils/cache-manager.js +0 -159
- package/plugins/deslop/lib/utils/command-parser.js +0 -0
- package/plugins/deslop/lib/utils/context-optimizer.js +0 -300
- package/plugins/deslop/lib/utils/deprecation.js +0 -37
- package/plugins/deslop/lib/utils/shell-escape.js +0 -88
- package/plugins/deslop/lib/utils/state-helpers.js +0 -61
- package/plugins/deslop/references/slop-categories.md +0 -122
- package/plugins/deslop/scripts/detect.js +0 -134
- package/plugins/deslop/skills/deslop/SKILL.md +0 -204
- package/plugins/drift-detect/.claude-plugin/plugin.json +0 -23
- package/plugins/drift-detect/agents/plan-synthesizer.md +0 -225
- package/plugins/drift-detect/commands/drift-detect.md +0 -269
- package/plugins/drift-detect/lib/adapter-transforms.js +0 -298
- package/plugins/drift-detect/lib/collectors/codebase.js +0 -392
- package/plugins/drift-detect/lib/collectors/docs-patterns.js +0 -713
- package/plugins/drift-detect/lib/collectors/documentation.js +0 -219
- package/plugins/drift-detect/lib/collectors/github.js +0 -330
- package/plugins/drift-detect/lib/collectors/index.js +0 -126
- package/plugins/drift-detect/lib/config/index.js +0 -14
- package/plugins/drift-detect/lib/cross-platform/index.js +0 -539
- package/plugins/drift-detect/lib/discovery/index.js +0 -352
- package/plugins/drift-detect/lib/drift-detect/collectors.js +0 -37
- package/plugins/drift-detect/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/drift-detect/lib/enhance/agent-patterns.js +0 -571
- package/plugins/drift-detect/lib/enhance/auto-suppression.js +0 -622
- package/plugins/drift-detect/lib/enhance/benchmark.js +0 -417
- package/plugins/drift-detect/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/drift-detect/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/drift-detect/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/drift-detect/lib/enhance/docs-patterns.js +0 -671
- package/plugins/drift-detect/lib/enhance/fixer.js +0 -721
- package/plugins/drift-detect/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/drift-detect/lib/enhance/hook-patterns.js +0 -40
- package/plugins/drift-detect/lib/enhance/index.js +0 -127
- package/plugins/drift-detect/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/drift-detect/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/drift-detect/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/drift-detect/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/drift-detect/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/drift-detect/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/drift-detect/lib/enhance/reporter.js +0 -1348
- package/plugins/drift-detect/lib/enhance/security-patterns.js +0 -284
- package/plugins/drift-detect/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/drift-detect/lib/enhance/skill-patterns.js +0 -147
- package/plugins/drift-detect/lib/enhance/suppression.js +0 -352
- package/plugins/drift-detect/lib/enhance/tool-patterns.js +0 -373
- package/plugins/drift-detect/lib/index.js +0 -270
- package/plugins/drift-detect/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/drift-detect/lib/patterns/pipeline.js +0 -948
- package/plugins/drift-detect/lib/patterns/review-patterns.js +0 -558
- package/plugins/drift-detect/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/drift-detect/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/drift-detect/lib/perf/analyzer/index.js +0 -22
- package/plugins/drift-detect/lib/perf/argument-parser.js +0 -105
- package/plugins/drift-detect/lib/perf/baseline-comparator.js +0 -50
- package/plugins/drift-detect/lib/perf/baseline-store.js +0 -127
- package/plugins/drift-detect/lib/perf/benchmark-runner.js +0 -404
- package/plugins/drift-detect/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/drift-detect/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/drift-detect/lib/perf/checkpoint.js +0 -123
- package/plugins/drift-detect/lib/perf/code-paths.js +0 -86
- package/plugins/drift-detect/lib/perf/consolidation.js +0 -37
- package/plugins/drift-detect/lib/perf/constraint-runner.js +0 -71
- package/plugins/drift-detect/lib/perf/experiment-runner.js +0 -32
- package/plugins/drift-detect/lib/perf/index.js +0 -41
- package/plugins/drift-detect/lib/perf/investigation-state.js +0 -874
- package/plugins/drift-detect/lib/perf/optimization-runner.js +0 -79
- package/plugins/drift-detect/lib/perf/profilers/go.js +0 -22
- package/plugins/drift-detect/lib/perf/profilers/index.js +0 -46
- package/plugins/drift-detect/lib/perf/profilers/java.js +0 -23
- package/plugins/drift-detect/lib/perf/profilers/node.js +0 -27
- package/plugins/drift-detect/lib/perf/profilers/python.js +0 -23
- package/plugins/drift-detect/lib/perf/profilers/rust.js +0 -23
- package/plugins/drift-detect/lib/perf/profiling-runner.js +0 -75
- package/plugins/drift-detect/lib/perf/schemas.js +0 -140
- package/plugins/drift-detect/lib/platform/detect-platform.js +0 -413
- package/plugins/drift-detect/lib/platform/detection-configs.js +0 -93
- package/plugins/drift-detect/lib/platform/state-dir.js +0 -132
- package/plugins/drift-detect/lib/platform/verify-tools.js +0 -182
- package/plugins/drift-detect/lib/repo-map/cache.js +0 -152
- package/plugins/drift-detect/lib/repo-map/concurrency.js +0 -29
- package/plugins/drift-detect/lib/repo-map/index.js +0 -222
- package/plugins/drift-detect/lib/repo-map/installer.js +0 -212
- package/plugins/drift-detect/lib/repo-map/queries/go.js +0 -27
- package/plugins/drift-detect/lib/repo-map/queries/index.js +0 -100
- package/plugins/drift-detect/lib/repo-map/queries/java.js +0 -38
- package/plugins/drift-detect/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/drift-detect/lib/repo-map/queries/python.js +0 -24
- package/plugins/drift-detect/lib/repo-map/queries/rust.js +0 -73
- package/plugins/drift-detect/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/drift-detect/lib/repo-map/runner.js +0 -1364
- package/plugins/drift-detect/lib/repo-map/updater.js +0 -562
- package/plugins/drift-detect/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/drift-detect/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/drift-detect/lib/schemas/validator.js +0 -247
- package/plugins/drift-detect/lib/sources/custom-handler.js +0 -199
- package/plugins/drift-detect/lib/sources/policy-questions.js +0 -246
- package/plugins/drift-detect/lib/sources/source-cache.js +0 -165
- package/plugins/drift-detect/lib/state/workflow-state.js +0 -576
- package/plugins/drift-detect/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/drift-detect/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/drift-detect/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/drift-detect/lib/types/index.d.ts +0 -84
- package/plugins/drift-detect/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/drift-detect/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/drift-detect/lib/utils/atomic-write.js +0 -94
- package/plugins/drift-detect/lib/utils/cache-manager.js +0 -159
- package/plugins/drift-detect/lib/utils/command-parser.js +0 -0
- package/plugins/drift-detect/lib/utils/context-optimizer.js +0 -300
- package/plugins/drift-detect/lib/utils/deprecation.js +0 -37
- package/plugins/drift-detect/lib/utils/shell-escape.js +0 -88
- package/plugins/drift-detect/lib/utils/state-helpers.js +0 -61
- package/plugins/drift-detect/skills/drift-analysis/SKILL.md +0 -324
- package/plugins/enhance/.claude-plugin/plugin.json +0 -20
- package/plugins/enhance/agents/agent-enhancer.md +0 -64
- package/plugins/enhance/agents/claudemd-enhancer.md +0 -65
- package/plugins/enhance/agents/cross-file-enhancer.md +0 -54
- package/plugins/enhance/agents/docs-enhancer.md +0 -64
- package/plugins/enhance/agents/hooks-enhancer.md +0 -64
- package/plugins/enhance/agents/plugin-enhancer.md +0 -63
- package/plugins/enhance/agents/prompt-enhancer.md +0 -58
- package/plugins/enhance/agents/skills-enhancer.md +0 -64
- package/plugins/enhance/commands/enhance.md +0 -178
- package/plugins/enhance/lib/adapter-transforms.js +0 -298
- package/plugins/enhance/lib/collectors/codebase.js +0 -392
- package/plugins/enhance/lib/collectors/docs-patterns.js +0 -713
- package/plugins/enhance/lib/collectors/documentation.js +0 -219
- package/plugins/enhance/lib/collectors/github.js +0 -330
- package/plugins/enhance/lib/collectors/index.js +0 -126
- package/plugins/enhance/lib/config/index.js +0 -14
- package/plugins/enhance/lib/cross-platform/index.js +0 -539
- package/plugins/enhance/lib/discovery/index.js +0 -352
- package/plugins/enhance/lib/drift-detect/collectors.js +0 -37
- package/plugins/enhance/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/enhance/lib/enhance/agent-patterns.js +0 -571
- package/plugins/enhance/lib/enhance/auto-suppression.js +0 -622
- package/plugins/enhance/lib/enhance/benchmark.js +0 -417
- package/plugins/enhance/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/enhance/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/enhance/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/enhance/lib/enhance/docs-patterns.js +0 -671
- package/plugins/enhance/lib/enhance/fixer.js +0 -721
- package/plugins/enhance/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/enhance/lib/enhance/hook-patterns.js +0 -40
- package/plugins/enhance/lib/enhance/index.js +0 -127
- package/plugins/enhance/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/enhance/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/enhance/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/enhance/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/enhance/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/enhance/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/enhance/lib/enhance/reporter.js +0 -1348
- package/plugins/enhance/lib/enhance/security-patterns.js +0 -284
- package/plugins/enhance/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/enhance/lib/enhance/skill-patterns.js +0 -147
- package/plugins/enhance/lib/enhance/suppression.js +0 -352
- package/plugins/enhance/lib/enhance/tool-patterns.js +0 -373
- package/plugins/enhance/lib/index.js +0 -270
- package/plugins/enhance/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/enhance/lib/patterns/pipeline.js +0 -948
- package/plugins/enhance/lib/patterns/review-patterns.js +0 -558
- package/plugins/enhance/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/enhance/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/enhance/lib/perf/analyzer/index.js +0 -22
- package/plugins/enhance/lib/perf/argument-parser.js +0 -105
- package/plugins/enhance/lib/perf/baseline-comparator.js +0 -50
- package/plugins/enhance/lib/perf/baseline-store.js +0 -127
- package/plugins/enhance/lib/perf/benchmark-runner.js +0 -404
- package/plugins/enhance/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/enhance/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/enhance/lib/perf/checkpoint.js +0 -123
- package/plugins/enhance/lib/perf/code-paths.js +0 -86
- package/plugins/enhance/lib/perf/consolidation.js +0 -37
- package/plugins/enhance/lib/perf/constraint-runner.js +0 -71
- package/plugins/enhance/lib/perf/experiment-runner.js +0 -32
- package/plugins/enhance/lib/perf/index.js +0 -41
- package/plugins/enhance/lib/perf/investigation-state.js +0 -874
- package/plugins/enhance/lib/perf/optimization-runner.js +0 -79
- package/plugins/enhance/lib/perf/profilers/go.js +0 -22
- package/plugins/enhance/lib/perf/profilers/index.js +0 -46
- package/plugins/enhance/lib/perf/profilers/java.js +0 -23
- package/plugins/enhance/lib/perf/profilers/node.js +0 -27
- package/plugins/enhance/lib/perf/profilers/python.js +0 -23
- package/plugins/enhance/lib/perf/profilers/rust.js +0 -23
- package/plugins/enhance/lib/perf/profiling-runner.js +0 -75
- package/plugins/enhance/lib/perf/schemas.js +0 -140
- package/plugins/enhance/lib/platform/detect-platform.js +0 -413
- package/plugins/enhance/lib/platform/detection-configs.js +0 -93
- package/plugins/enhance/lib/platform/state-dir.js +0 -132
- package/plugins/enhance/lib/platform/verify-tools.js +0 -182
- package/plugins/enhance/lib/repo-map/cache.js +0 -152
- package/plugins/enhance/lib/repo-map/concurrency.js +0 -29
- package/plugins/enhance/lib/repo-map/index.js +0 -222
- package/plugins/enhance/lib/repo-map/installer.js +0 -212
- package/plugins/enhance/lib/repo-map/queries/go.js +0 -27
- package/plugins/enhance/lib/repo-map/queries/index.js +0 -100
- package/plugins/enhance/lib/repo-map/queries/java.js +0 -38
- package/plugins/enhance/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/enhance/lib/repo-map/queries/python.js +0 -24
- package/plugins/enhance/lib/repo-map/queries/rust.js +0 -73
- package/plugins/enhance/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/enhance/lib/repo-map/runner.js +0 -1364
- package/plugins/enhance/lib/repo-map/updater.js +0 -562
- package/plugins/enhance/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/enhance/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/enhance/lib/schemas/validator.js +0 -247
- package/plugins/enhance/lib/sources/custom-handler.js +0 -199
- package/plugins/enhance/lib/sources/policy-questions.js +0 -246
- package/plugins/enhance/lib/sources/source-cache.js +0 -165
- package/plugins/enhance/lib/state/workflow-state.js +0 -576
- package/plugins/enhance/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/enhance/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/enhance/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/enhance/lib/types/index.d.ts +0 -84
- package/plugins/enhance/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/enhance/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/enhance/lib/utils/atomic-write.js +0 -94
- package/plugins/enhance/lib/utils/cache-manager.js +0 -159
- package/plugins/enhance/lib/utils/command-parser.js +0 -0
- package/plugins/enhance/lib/utils/context-optimizer.js +0 -300
- package/plugins/enhance/lib/utils/deprecation.js +0 -37
- package/plugins/enhance/lib/utils/shell-escape.js +0 -88
- package/plugins/enhance/lib/utils/state-helpers.js +0 -61
- package/plugins/enhance/skills/enhance-agent-prompts/SKILL.md +0 -277
- package/plugins/enhance/skills/enhance-claude-memory/SKILL.md +0 -387
- package/plugins/enhance/skills/enhance-cross-file/SKILL.md +0 -110
- package/plugins/enhance/skills/enhance-docs/SKILL.md +0 -298
- package/plugins/enhance/skills/enhance-hooks/SKILL.md +0 -554
- package/plugins/enhance/skills/enhance-orchestrator/SKILL.md +0 -255
- package/plugins/enhance/skills/enhance-plugins/SKILL.md +0 -319
- package/plugins/enhance/skills/enhance-prompts/SKILL.md +0 -340
- package/plugins/enhance/skills/enhance-skills/SKILL.md +0 -436
- package/plugins/learn/.claude-plugin/plugin.json +0 -21
- package/plugins/learn/agents/learn-agent.md +0 -331
- package/plugins/learn/commands/learn.md +0 -190
- package/plugins/learn/lib/adapter-transforms.js +0 -298
- package/plugins/learn/lib/collectors/codebase.js +0 -392
- package/plugins/learn/lib/collectors/docs-patterns.js +0 -713
- package/plugins/learn/lib/collectors/documentation.js +0 -219
- package/plugins/learn/lib/collectors/github.js +0 -330
- package/plugins/learn/lib/collectors/index.js +0 -126
- package/plugins/learn/lib/config/index.js +0 -14
- package/plugins/learn/lib/cross-platform/index.js +0 -539
- package/plugins/learn/lib/discovery/index.js +0 -352
- package/plugins/learn/lib/drift-detect/collectors.js +0 -37
- package/plugins/learn/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/learn/lib/enhance/agent-patterns.js +0 -571
- package/plugins/learn/lib/enhance/auto-suppression.js +0 -622
- package/plugins/learn/lib/enhance/benchmark.js +0 -417
- package/plugins/learn/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/learn/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/learn/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/learn/lib/enhance/docs-patterns.js +0 -671
- package/plugins/learn/lib/enhance/fixer.js +0 -721
- package/plugins/learn/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/learn/lib/enhance/hook-patterns.js +0 -40
- package/plugins/learn/lib/enhance/index.js +0 -127
- package/plugins/learn/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/learn/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/learn/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/learn/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/learn/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/learn/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/learn/lib/enhance/reporter.js +0 -1348
- package/plugins/learn/lib/enhance/security-patterns.js +0 -284
- package/plugins/learn/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/learn/lib/enhance/skill-patterns.js +0 -147
- package/plugins/learn/lib/enhance/suppression.js +0 -352
- package/plugins/learn/lib/enhance/tool-patterns.js +0 -373
- package/plugins/learn/lib/index.js +0 -270
- package/plugins/learn/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/learn/lib/patterns/pipeline.js +0 -948
- package/plugins/learn/lib/patterns/review-patterns.js +0 -558
- package/plugins/learn/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/learn/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/learn/lib/perf/analyzer/index.js +0 -22
- package/plugins/learn/lib/perf/argument-parser.js +0 -105
- package/plugins/learn/lib/perf/baseline-comparator.js +0 -50
- package/plugins/learn/lib/perf/baseline-store.js +0 -127
- package/plugins/learn/lib/perf/benchmark-runner.js +0 -404
- package/plugins/learn/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/learn/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/learn/lib/perf/checkpoint.js +0 -123
- package/plugins/learn/lib/perf/code-paths.js +0 -86
- package/plugins/learn/lib/perf/consolidation.js +0 -37
- package/plugins/learn/lib/perf/constraint-runner.js +0 -71
- package/plugins/learn/lib/perf/experiment-runner.js +0 -32
- package/plugins/learn/lib/perf/index.js +0 -41
- package/plugins/learn/lib/perf/investigation-state.js +0 -874
- package/plugins/learn/lib/perf/optimization-runner.js +0 -79
- package/plugins/learn/lib/perf/profilers/go.js +0 -22
- package/plugins/learn/lib/perf/profilers/index.js +0 -46
- package/plugins/learn/lib/perf/profilers/java.js +0 -23
- package/plugins/learn/lib/perf/profilers/node.js +0 -27
- package/plugins/learn/lib/perf/profilers/python.js +0 -23
- package/plugins/learn/lib/perf/profilers/rust.js +0 -23
- package/plugins/learn/lib/perf/profiling-runner.js +0 -75
- package/plugins/learn/lib/perf/schemas.js +0 -140
- package/plugins/learn/lib/platform/detect-platform.js +0 -413
- package/plugins/learn/lib/platform/detection-configs.js +0 -93
- package/plugins/learn/lib/platform/state-dir.js +0 -132
- package/plugins/learn/lib/platform/verify-tools.js +0 -182
- package/plugins/learn/lib/repo-map/cache.js +0 -152
- package/plugins/learn/lib/repo-map/concurrency.js +0 -29
- package/plugins/learn/lib/repo-map/index.js +0 -222
- package/plugins/learn/lib/repo-map/installer.js +0 -212
- package/plugins/learn/lib/repo-map/queries/go.js +0 -27
- package/plugins/learn/lib/repo-map/queries/index.js +0 -100
- package/plugins/learn/lib/repo-map/queries/java.js +0 -38
- package/plugins/learn/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/learn/lib/repo-map/queries/python.js +0 -24
- package/plugins/learn/lib/repo-map/queries/rust.js +0 -73
- package/plugins/learn/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/learn/lib/repo-map/runner.js +0 -1364
- package/plugins/learn/lib/repo-map/updater.js +0 -562
- package/plugins/learn/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/learn/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/learn/lib/schemas/validator.js +0 -247
- package/plugins/learn/lib/sources/custom-handler.js +0 -199
- package/plugins/learn/lib/sources/policy-questions.js +0 -246
- package/plugins/learn/lib/sources/source-cache.js +0 -165
- package/plugins/learn/lib/state/workflow-state.js +0 -576
- package/plugins/learn/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/learn/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/learn/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/learn/lib/types/index.d.ts +0 -84
- package/plugins/learn/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/learn/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/learn/lib/utils/atomic-write.js +0 -94
- package/plugins/learn/lib/utils/cache-manager.js +0 -159
- package/plugins/learn/lib/utils/command-parser.js +0 -0
- package/plugins/learn/lib/utils/context-optimizer.js +0 -300
- package/plugins/learn/lib/utils/deprecation.js +0 -37
- package/plugins/learn/lib/utils/shell-escape.js +0 -88
- package/plugins/learn/lib/utils/state-helpers.js +0 -61
- package/plugins/learn/skills/learn/SKILL.md +0 -349
- package/plugins/next-task/.claude-plugin/plugin.json +0 -24
- package/plugins/next-task/agents/ci-fixer.md +0 -259
- package/plugins/next-task/agents/ci-monitor.md +0 -342
- package/plugins/next-task/agents/delivery-validator.md +0 -115
- package/plugins/next-task/agents/exploration-agent.md +0 -316
- package/plugins/next-task/agents/implementation-agent.md +0 -465
- package/plugins/next-task/agents/planning-agent.md +0 -377
- package/plugins/next-task/agents/simple-fixer.md +0 -139
- package/plugins/next-task/agents/task-discoverer.md +0 -89
- package/plugins/next-task/agents/test-coverage-checker.md +0 -451
- package/plugins/next-task/agents/worktree-manager.md +0 -257
- package/plugins/next-task/commands/delivery-approval.md +0 -341
- package/plugins/next-task/commands/next-task.md +0 -547
- package/plugins/next-task/hooks/hooks.json +0 -14
- package/plugins/next-task/lib/adapter-transforms.js +0 -298
- package/plugins/next-task/lib/collectors/codebase.js +0 -392
- package/plugins/next-task/lib/collectors/docs-patterns.js +0 -713
- package/plugins/next-task/lib/collectors/documentation.js +0 -219
- package/plugins/next-task/lib/collectors/github.js +0 -330
- package/plugins/next-task/lib/collectors/index.js +0 -126
- package/plugins/next-task/lib/config/index.js +0 -14
- package/plugins/next-task/lib/cross-platform/index.js +0 -539
- package/plugins/next-task/lib/discovery/index.js +0 -352
- package/plugins/next-task/lib/drift-detect/collectors.js +0 -37
- package/plugins/next-task/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/next-task/lib/enhance/agent-patterns.js +0 -571
- package/plugins/next-task/lib/enhance/auto-suppression.js +0 -622
- package/plugins/next-task/lib/enhance/benchmark.js +0 -417
- package/plugins/next-task/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/next-task/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/next-task/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/next-task/lib/enhance/docs-patterns.js +0 -671
- package/plugins/next-task/lib/enhance/fixer.js +0 -721
- package/plugins/next-task/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/next-task/lib/enhance/hook-patterns.js +0 -40
- package/plugins/next-task/lib/enhance/index.js +0 -127
- package/plugins/next-task/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/next-task/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/next-task/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/next-task/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/next-task/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/next-task/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/next-task/lib/enhance/reporter.js +0 -1348
- package/plugins/next-task/lib/enhance/security-patterns.js +0 -284
- package/plugins/next-task/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/next-task/lib/enhance/skill-patterns.js +0 -147
- package/plugins/next-task/lib/enhance/suppression.js +0 -352
- package/plugins/next-task/lib/enhance/tool-patterns.js +0 -373
- package/plugins/next-task/lib/index.js +0 -270
- package/plugins/next-task/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/next-task/lib/patterns/pipeline.js +0 -948
- package/plugins/next-task/lib/patterns/review-patterns.js +0 -558
- package/plugins/next-task/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/next-task/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/next-task/lib/perf/analyzer/index.js +0 -22
- package/plugins/next-task/lib/perf/argument-parser.js +0 -105
- package/plugins/next-task/lib/perf/baseline-comparator.js +0 -50
- package/plugins/next-task/lib/perf/baseline-store.js +0 -127
- package/plugins/next-task/lib/perf/benchmark-runner.js +0 -404
- package/plugins/next-task/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/next-task/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/next-task/lib/perf/checkpoint.js +0 -123
- package/plugins/next-task/lib/perf/code-paths.js +0 -86
- package/plugins/next-task/lib/perf/consolidation.js +0 -37
- package/plugins/next-task/lib/perf/constraint-runner.js +0 -71
- package/plugins/next-task/lib/perf/experiment-runner.js +0 -32
- package/plugins/next-task/lib/perf/index.js +0 -41
- package/plugins/next-task/lib/perf/investigation-state.js +0 -874
- package/plugins/next-task/lib/perf/optimization-runner.js +0 -79
- package/plugins/next-task/lib/perf/profilers/go.js +0 -22
- package/plugins/next-task/lib/perf/profilers/index.js +0 -46
- package/plugins/next-task/lib/perf/profilers/java.js +0 -23
- package/plugins/next-task/lib/perf/profilers/node.js +0 -27
- package/plugins/next-task/lib/perf/profilers/python.js +0 -23
- package/plugins/next-task/lib/perf/profilers/rust.js +0 -23
- package/plugins/next-task/lib/perf/profiling-runner.js +0 -75
- package/plugins/next-task/lib/perf/schemas.js +0 -140
- package/plugins/next-task/lib/platform/detect-platform.js +0 -413
- package/plugins/next-task/lib/platform/detection-configs.js +0 -93
- package/plugins/next-task/lib/platform/state-dir.js +0 -132
- package/plugins/next-task/lib/platform/verify-tools.js +0 -182
- package/plugins/next-task/lib/repo-map/cache.js +0 -152
- package/plugins/next-task/lib/repo-map/concurrency.js +0 -29
- package/plugins/next-task/lib/repo-map/index.js +0 -222
- package/plugins/next-task/lib/repo-map/installer.js +0 -212
- package/plugins/next-task/lib/repo-map/queries/go.js +0 -27
- package/plugins/next-task/lib/repo-map/queries/index.js +0 -100
- package/plugins/next-task/lib/repo-map/queries/java.js +0 -38
- package/plugins/next-task/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/next-task/lib/repo-map/queries/python.js +0 -24
- package/plugins/next-task/lib/repo-map/queries/rust.js +0 -73
- package/plugins/next-task/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/next-task/lib/repo-map/runner.js +0 -1364
- package/plugins/next-task/lib/repo-map/updater.js +0 -562
- package/plugins/next-task/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/next-task/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/next-task/lib/schemas/validator.js +0 -247
- package/plugins/next-task/lib/sources/custom-handler.js +0 -199
- package/plugins/next-task/lib/sources/policy-questions.js +0 -246
- package/plugins/next-task/lib/sources/source-cache.js +0 -165
- package/plugins/next-task/lib/state/workflow-state.js +0 -576
- package/plugins/next-task/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/next-task/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/next-task/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/next-task/lib/types/index.d.ts +0 -84
- package/plugins/next-task/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/next-task/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/next-task/lib/utils/atomic-write.js +0 -94
- package/plugins/next-task/lib/utils/cache-manager.js +0 -159
- package/plugins/next-task/lib/utils/command-parser.js +0 -0
- package/plugins/next-task/lib/utils/context-optimizer.js +0 -300
- package/plugins/next-task/lib/utils/deprecation.js +0 -37
- package/plugins/next-task/lib/utils/shell-escape.js +0 -88
- package/plugins/next-task/lib/utils/state-helpers.js +0 -61
- package/plugins/next-task/skills/discover-tasks/SKILL.md +0 -191
- package/plugins/next-task/skills/orchestrate-review/SKILL.md +0 -239
- package/plugins/next-task/skills/validate-delivery/SKILL.md +0 -186
- package/plugins/perf/.claude-plugin/plugin.json +0 -20
- package/plugins/perf/agents/perf-analyzer.md +0 -43
- package/plugins/perf/agents/perf-code-paths.md +0 -16
- package/plugins/perf/agents/perf-investigation-logger.md +0 -47
- package/plugins/perf/agents/perf-orchestrator.md +0 -344
- package/plugins/perf/agents/perf-theory-gatherer.md +0 -25
- package/plugins/perf/agents/perf-theory-tester.md +0 -58
- package/plugins/perf/commands/perf.md +0 -470
- package/plugins/perf/hooks/checkpoint.md +0 -35
- package/plugins/perf/hooks/constraint-tester.md +0 -40
- package/plugins/perf/lib/adapter-transforms.js +0 -298
- package/plugins/perf/lib/collectors/codebase.js +0 -392
- package/plugins/perf/lib/collectors/docs-patterns.js +0 -713
- package/plugins/perf/lib/collectors/documentation.js +0 -219
- package/plugins/perf/lib/collectors/github.js +0 -330
- package/plugins/perf/lib/collectors/index.js +0 -126
- package/plugins/perf/lib/config/index.js +0 -14
- package/plugins/perf/lib/cross-platform/index.js +0 -539
- package/plugins/perf/lib/discovery/index.js +0 -352
- package/plugins/perf/lib/drift-detect/collectors.js +0 -37
- package/plugins/perf/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/perf/lib/enhance/agent-patterns.js +0 -571
- package/plugins/perf/lib/enhance/auto-suppression.js +0 -622
- package/plugins/perf/lib/enhance/benchmark.js +0 -417
- package/plugins/perf/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/perf/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/perf/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/perf/lib/enhance/docs-patterns.js +0 -671
- package/plugins/perf/lib/enhance/fixer.js +0 -721
- package/plugins/perf/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/perf/lib/enhance/hook-patterns.js +0 -40
- package/plugins/perf/lib/enhance/index.js +0 -127
- package/plugins/perf/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/perf/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/perf/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/perf/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/perf/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/perf/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/perf/lib/enhance/reporter.js +0 -1348
- package/plugins/perf/lib/enhance/security-patterns.js +0 -284
- package/plugins/perf/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/perf/lib/enhance/skill-patterns.js +0 -147
- package/plugins/perf/lib/enhance/suppression.js +0 -352
- package/plugins/perf/lib/enhance/tool-patterns.js +0 -373
- package/plugins/perf/lib/index.js +0 -270
- package/plugins/perf/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/perf/lib/patterns/pipeline.js +0 -948
- package/plugins/perf/lib/patterns/review-patterns.js +0 -558
- package/plugins/perf/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/perf/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/perf/lib/perf/analyzer/index.js +0 -22
- package/plugins/perf/lib/perf/argument-parser.js +0 -105
- package/plugins/perf/lib/perf/baseline-comparator.js +0 -50
- package/plugins/perf/lib/perf/baseline-store.js +0 -127
- package/plugins/perf/lib/perf/benchmark-runner.js +0 -404
- package/plugins/perf/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/perf/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/perf/lib/perf/checkpoint.js +0 -123
- package/plugins/perf/lib/perf/code-paths.js +0 -86
- package/plugins/perf/lib/perf/consolidation.js +0 -37
- package/plugins/perf/lib/perf/constraint-runner.js +0 -71
- package/plugins/perf/lib/perf/experiment-runner.js +0 -32
- package/plugins/perf/lib/perf/index.js +0 -41
- package/plugins/perf/lib/perf/investigation-state.js +0 -874
- package/plugins/perf/lib/perf/optimization-runner.js +0 -79
- package/plugins/perf/lib/perf/profilers/go.js +0 -22
- package/plugins/perf/lib/perf/profilers/index.js +0 -46
- package/plugins/perf/lib/perf/profilers/java.js +0 -23
- package/plugins/perf/lib/perf/profilers/node.js +0 -27
- package/plugins/perf/lib/perf/profilers/python.js +0 -23
- package/plugins/perf/lib/perf/profilers/rust.js +0 -23
- package/plugins/perf/lib/perf/profiling-runner.js +0 -75
- package/plugins/perf/lib/perf/schemas.js +0 -140
- package/plugins/perf/lib/platform/detect-platform.js +0 -413
- package/plugins/perf/lib/platform/detection-configs.js +0 -93
- package/plugins/perf/lib/platform/state-dir.js +0 -132
- package/plugins/perf/lib/platform/verify-tools.js +0 -182
- package/plugins/perf/lib/repo-map/cache.js +0 -152
- package/plugins/perf/lib/repo-map/concurrency.js +0 -29
- package/plugins/perf/lib/repo-map/index.js +0 -222
- package/plugins/perf/lib/repo-map/installer.js +0 -212
- package/plugins/perf/lib/repo-map/queries/go.js +0 -27
- package/plugins/perf/lib/repo-map/queries/index.js +0 -100
- package/plugins/perf/lib/repo-map/queries/java.js +0 -38
- package/plugins/perf/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/perf/lib/repo-map/queries/python.js +0 -24
- package/plugins/perf/lib/repo-map/queries/rust.js +0 -73
- package/plugins/perf/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/perf/lib/repo-map/runner.js +0 -1364
- package/plugins/perf/lib/repo-map/updater.js +0 -562
- package/plugins/perf/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/perf/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/perf/lib/schemas/validator.js +0 -247
- package/plugins/perf/lib/sources/custom-handler.js +0 -199
- package/plugins/perf/lib/sources/policy-questions.js +0 -246
- package/plugins/perf/lib/sources/source-cache.js +0 -165
- package/plugins/perf/lib/state/workflow-state.js +0 -576
- package/plugins/perf/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/perf/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/perf/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/perf/lib/types/index.d.ts +0 -84
- package/plugins/perf/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/perf/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/perf/lib/utils/atomic-write.js +0 -94
- package/plugins/perf/lib/utils/cache-manager.js +0 -159
- package/plugins/perf/lib/utils/command-parser.js +0 -0
- package/plugins/perf/lib/utils/context-optimizer.js +0 -300
- package/plugins/perf/lib/utils/deprecation.js +0 -37
- package/plugins/perf/lib/utils/shell-escape.js +0 -88
- package/plugins/perf/lib/utils/state-helpers.js +0 -61
- package/plugins/perf/skills/perf-analyzer/SKILL.md +0 -37
- package/plugins/perf/skills/perf-baseline-manager/SKILL.md +0 -30
- package/plugins/perf/skills/perf-benchmarker/SKILL.md +0 -52
- package/plugins/perf/skills/perf-code-paths/SKILL.md +0 -32
- package/plugins/perf/skills/perf-investigation-logger/SKILL.md +0 -41
- package/plugins/perf/skills/perf-profiler/SKILL.md +0 -42
- package/plugins/perf/skills/perf-theory-gatherer/SKILL.md +0 -35
- package/plugins/perf/skills/perf-theory-tester/SKILL.md +0 -36
- package/plugins/repo-map/.claude-plugin/plugin.json +0 -22
- package/plugins/repo-map/agents/map-validator.md +0 -60
- package/plugins/repo-map/commands/repo-map.md +0 -133
- package/plugins/repo-map/lib/adapter-transforms.js +0 -298
- package/plugins/repo-map/lib/collectors/codebase.js +0 -392
- package/plugins/repo-map/lib/collectors/docs-patterns.js +0 -713
- package/plugins/repo-map/lib/collectors/documentation.js +0 -219
- package/plugins/repo-map/lib/collectors/github.js +0 -330
- package/plugins/repo-map/lib/collectors/index.js +0 -126
- package/plugins/repo-map/lib/config/index.js +0 -14
- package/plugins/repo-map/lib/cross-platform/index.js +0 -539
- package/plugins/repo-map/lib/discovery/index.js +0 -352
- package/plugins/repo-map/lib/drift-detect/collectors.js +0 -37
- package/plugins/repo-map/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/repo-map/lib/enhance/agent-patterns.js +0 -571
- package/plugins/repo-map/lib/enhance/auto-suppression.js +0 -622
- package/plugins/repo-map/lib/enhance/benchmark.js +0 -417
- package/plugins/repo-map/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/repo-map/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/repo-map/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/repo-map/lib/enhance/docs-patterns.js +0 -671
- package/plugins/repo-map/lib/enhance/fixer.js +0 -721
- package/plugins/repo-map/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/repo-map/lib/enhance/hook-patterns.js +0 -40
- package/plugins/repo-map/lib/enhance/index.js +0 -127
- package/plugins/repo-map/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/repo-map/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/repo-map/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/repo-map/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/repo-map/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/repo-map/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/repo-map/lib/enhance/reporter.js +0 -1348
- package/plugins/repo-map/lib/enhance/security-patterns.js +0 -284
- package/plugins/repo-map/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/repo-map/lib/enhance/skill-patterns.js +0 -147
- package/plugins/repo-map/lib/enhance/suppression.js +0 -352
- package/plugins/repo-map/lib/enhance/tool-patterns.js +0 -373
- package/plugins/repo-map/lib/index.js +0 -270
- package/plugins/repo-map/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/repo-map/lib/patterns/pipeline.js +0 -948
- package/plugins/repo-map/lib/patterns/review-patterns.js +0 -558
- package/plugins/repo-map/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/repo-map/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/repo-map/lib/perf/analyzer/index.js +0 -22
- package/plugins/repo-map/lib/perf/argument-parser.js +0 -105
- package/plugins/repo-map/lib/perf/baseline-comparator.js +0 -50
- package/plugins/repo-map/lib/perf/baseline-store.js +0 -127
- package/plugins/repo-map/lib/perf/benchmark-runner.js +0 -404
- package/plugins/repo-map/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/repo-map/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/repo-map/lib/perf/checkpoint.js +0 -123
- package/plugins/repo-map/lib/perf/code-paths.js +0 -86
- package/plugins/repo-map/lib/perf/consolidation.js +0 -37
- package/plugins/repo-map/lib/perf/constraint-runner.js +0 -71
- package/plugins/repo-map/lib/perf/experiment-runner.js +0 -32
- package/plugins/repo-map/lib/perf/index.js +0 -41
- package/plugins/repo-map/lib/perf/investigation-state.js +0 -874
- package/plugins/repo-map/lib/perf/optimization-runner.js +0 -79
- package/plugins/repo-map/lib/perf/profilers/go.js +0 -22
- package/plugins/repo-map/lib/perf/profilers/index.js +0 -46
- package/plugins/repo-map/lib/perf/profilers/java.js +0 -23
- package/plugins/repo-map/lib/perf/profilers/node.js +0 -27
- package/plugins/repo-map/lib/perf/profilers/python.js +0 -23
- package/plugins/repo-map/lib/perf/profilers/rust.js +0 -23
- package/plugins/repo-map/lib/perf/profiling-runner.js +0 -75
- package/plugins/repo-map/lib/perf/schemas.js +0 -140
- package/plugins/repo-map/lib/platform/detect-platform.js +0 -413
- package/plugins/repo-map/lib/platform/detection-configs.js +0 -93
- package/plugins/repo-map/lib/platform/state-dir.js +0 -132
- package/plugins/repo-map/lib/platform/verify-tools.js +0 -182
- package/plugins/repo-map/lib/repo-map/cache.js +0 -152
- package/plugins/repo-map/lib/repo-map/concurrency.js +0 -29
- package/plugins/repo-map/lib/repo-map/index.js +0 -222
- package/plugins/repo-map/lib/repo-map/installer.js +0 -212
- package/plugins/repo-map/lib/repo-map/queries/go.js +0 -27
- package/plugins/repo-map/lib/repo-map/queries/index.js +0 -100
- package/plugins/repo-map/lib/repo-map/queries/java.js +0 -38
- package/plugins/repo-map/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/repo-map/lib/repo-map/queries/python.js +0 -24
- package/plugins/repo-map/lib/repo-map/queries/rust.js +0 -73
- package/plugins/repo-map/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/repo-map/lib/repo-map/runner.js +0 -1364
- package/plugins/repo-map/lib/repo-map/updater.js +0 -562
- package/plugins/repo-map/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/repo-map/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/repo-map/lib/schemas/validator.js +0 -247
- package/plugins/repo-map/lib/sources/custom-handler.js +0 -199
- package/plugins/repo-map/lib/sources/policy-questions.js +0 -246
- package/plugins/repo-map/lib/sources/source-cache.js +0 -165
- package/plugins/repo-map/lib/state/workflow-state.js +0 -576
- package/plugins/repo-map/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/repo-map/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/repo-map/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/repo-map/lib/types/index.d.ts +0 -84
- package/plugins/repo-map/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/repo-map/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/repo-map/lib/utils/atomic-write.js +0 -94
- package/plugins/repo-map/lib/utils/cache-manager.js +0 -159
- package/plugins/repo-map/lib/utils/command-parser.js +0 -0
- package/plugins/repo-map/lib/utils/context-optimizer.js +0 -300
- package/plugins/repo-map/lib/utils/deprecation.js +0 -37
- package/plugins/repo-map/lib/utils/shell-escape.js +0 -88
- package/plugins/repo-map/lib/utils/state-helpers.js +0 -61
- package/plugins/repo-map/skills/repo-mapping/SKILL.md +0 -83
- package/plugins/ship/.claude-plugin/plugin.json +0 -21
- package/plugins/ship/commands/ship-ci-review-loop.md +0 -472
- package/plugins/ship/commands/ship-deployment.md +0 -335
- package/plugins/ship/commands/ship-error-handling.md +0 -258
- package/plugins/ship/commands/ship.md +0 -492
- package/plugins/ship/lib/adapter-transforms.js +0 -298
- package/plugins/ship/lib/collectors/codebase.js +0 -392
- package/plugins/ship/lib/collectors/docs-patterns.js +0 -713
- package/plugins/ship/lib/collectors/documentation.js +0 -219
- package/plugins/ship/lib/collectors/github.js +0 -330
- package/plugins/ship/lib/collectors/index.js +0 -126
- package/plugins/ship/lib/config/index.js +0 -14
- package/plugins/ship/lib/cross-platform/index.js +0 -539
- package/plugins/ship/lib/discovery/index.js +0 -352
- package/plugins/ship/lib/drift-detect/collectors.js +0 -37
- package/plugins/ship/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/ship/lib/enhance/agent-patterns.js +0 -571
- package/plugins/ship/lib/enhance/auto-suppression.js +0 -622
- package/plugins/ship/lib/enhance/benchmark.js +0 -417
- package/plugins/ship/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/ship/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/ship/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/ship/lib/enhance/docs-patterns.js +0 -671
- package/plugins/ship/lib/enhance/fixer.js +0 -721
- package/plugins/ship/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/ship/lib/enhance/hook-patterns.js +0 -40
- package/plugins/ship/lib/enhance/index.js +0 -127
- package/plugins/ship/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/ship/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/ship/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/ship/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/ship/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/ship/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/ship/lib/enhance/reporter.js +0 -1348
- package/plugins/ship/lib/enhance/security-patterns.js +0 -284
- package/plugins/ship/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/ship/lib/enhance/skill-patterns.js +0 -147
- package/plugins/ship/lib/enhance/suppression.js +0 -352
- package/plugins/ship/lib/enhance/tool-patterns.js +0 -373
- package/plugins/ship/lib/index.js +0 -270
- package/plugins/ship/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/ship/lib/patterns/pipeline.js +0 -948
- package/plugins/ship/lib/patterns/review-patterns.js +0 -558
- package/plugins/ship/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/ship/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/ship/lib/perf/analyzer/index.js +0 -22
- package/plugins/ship/lib/perf/argument-parser.js +0 -105
- package/plugins/ship/lib/perf/baseline-comparator.js +0 -50
- package/plugins/ship/lib/perf/baseline-store.js +0 -127
- package/plugins/ship/lib/perf/benchmark-runner.js +0 -404
- package/plugins/ship/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/ship/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/ship/lib/perf/checkpoint.js +0 -123
- package/plugins/ship/lib/perf/code-paths.js +0 -86
- package/plugins/ship/lib/perf/consolidation.js +0 -37
- package/plugins/ship/lib/perf/constraint-runner.js +0 -71
- package/plugins/ship/lib/perf/experiment-runner.js +0 -32
- package/plugins/ship/lib/perf/index.js +0 -41
- package/plugins/ship/lib/perf/investigation-state.js +0 -874
- package/plugins/ship/lib/perf/optimization-runner.js +0 -79
- package/plugins/ship/lib/perf/profilers/go.js +0 -22
- package/plugins/ship/lib/perf/profilers/index.js +0 -46
- package/plugins/ship/lib/perf/profilers/java.js +0 -23
- package/plugins/ship/lib/perf/profilers/node.js +0 -27
- package/plugins/ship/lib/perf/profilers/python.js +0 -23
- package/plugins/ship/lib/perf/profilers/rust.js +0 -23
- package/plugins/ship/lib/perf/profiling-runner.js +0 -75
- package/plugins/ship/lib/perf/schemas.js +0 -140
- package/plugins/ship/lib/platform/detect-platform.js +0 -413
- package/plugins/ship/lib/platform/detection-configs.js +0 -93
- package/plugins/ship/lib/platform/state-dir.js +0 -132
- package/plugins/ship/lib/platform/verify-tools.js +0 -182
- package/plugins/ship/lib/repo-map/cache.js +0 -152
- package/plugins/ship/lib/repo-map/concurrency.js +0 -29
- package/plugins/ship/lib/repo-map/index.js +0 -222
- package/plugins/ship/lib/repo-map/installer.js +0 -212
- package/plugins/ship/lib/repo-map/queries/go.js +0 -27
- package/plugins/ship/lib/repo-map/queries/index.js +0 -100
- package/plugins/ship/lib/repo-map/queries/java.js +0 -38
- package/plugins/ship/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/ship/lib/repo-map/queries/python.js +0 -24
- package/plugins/ship/lib/repo-map/queries/rust.js +0 -73
- package/plugins/ship/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/ship/lib/repo-map/runner.js +0 -1364
- package/plugins/ship/lib/repo-map/updater.js +0 -562
- package/plugins/ship/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/ship/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/ship/lib/schemas/validator.js +0 -247
- package/plugins/ship/lib/sources/custom-handler.js +0 -199
- package/plugins/ship/lib/sources/policy-questions.js +0 -246
- package/plugins/ship/lib/sources/source-cache.js +0 -165
- package/plugins/ship/lib/state/workflow-state.js +0 -576
- package/plugins/ship/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/ship/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/ship/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/ship/lib/types/index.d.ts +0 -84
- package/plugins/ship/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/ship/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/ship/lib/utils/atomic-write.js +0 -94
- package/plugins/ship/lib/utils/cache-manager.js +0 -159
- package/plugins/ship/lib/utils/command-parser.js +0 -0
- package/plugins/ship/lib/utils/context-optimizer.js +0 -300
- package/plugins/ship/lib/utils/deprecation.js +0 -37
- package/plugins/ship/lib/utils/shell-escape.js +0 -88
- package/plugins/ship/lib/utils/state-helpers.js +0 -61
- package/plugins/sync-docs/.claude-plugin/plugin.json +0 -20
- package/plugins/sync-docs/agents/sync-docs-agent.md +0 -154
- package/plugins/sync-docs/commands/sync-docs.md +0 -186
- package/plugins/sync-docs/lib/adapter-transforms.js +0 -298
- package/plugins/sync-docs/lib/collectors/codebase.js +0 -392
- package/plugins/sync-docs/lib/collectors/docs-patterns.js +0 -713
- package/plugins/sync-docs/lib/collectors/documentation.js +0 -219
- package/plugins/sync-docs/lib/collectors/github.js +0 -330
- package/plugins/sync-docs/lib/collectors/index.js +0 -126
- package/plugins/sync-docs/lib/config/index.js +0 -14
- package/plugins/sync-docs/lib/cross-platform/index.js +0 -539
- package/plugins/sync-docs/lib/discovery/index.js +0 -352
- package/plugins/sync-docs/lib/drift-detect/collectors.js +0 -37
- package/plugins/sync-docs/lib/enhance/agent-analyzer.js +0 -421
- package/plugins/sync-docs/lib/enhance/agent-patterns.js +0 -571
- package/plugins/sync-docs/lib/enhance/auto-suppression.js +0 -622
- package/plugins/sync-docs/lib/enhance/benchmark.js +0 -417
- package/plugins/sync-docs/lib/enhance/cross-file-analyzer.js +0 -930
- package/plugins/sync-docs/lib/enhance/cross-file-patterns.js +0 -370
- package/plugins/sync-docs/lib/enhance/docs-analyzer.js +0 -325
- package/plugins/sync-docs/lib/enhance/docs-patterns.js +0 -671
- package/plugins/sync-docs/lib/enhance/fixer.js +0 -721
- package/plugins/sync-docs/lib/enhance/hook-analyzer.js +0 -135
- package/plugins/sync-docs/lib/enhance/hook-patterns.js +0 -40
- package/plugins/sync-docs/lib/enhance/index.js +0 -127
- package/plugins/sync-docs/lib/enhance/plugin-analyzer.js +0 -402
- package/plugins/sync-docs/lib/enhance/plugin-patterns.js +0 -326
- package/plugins/sync-docs/lib/enhance/projectmemory-analyzer.js +0 -551
- package/plugins/sync-docs/lib/enhance/projectmemory-patterns.js +0 -617
- package/plugins/sync-docs/lib/enhance/prompt-analyzer.js +0 -457
- package/plugins/sync-docs/lib/enhance/prompt-patterns.js +0 -1484
- package/plugins/sync-docs/lib/enhance/reporter.js +0 -1348
- package/plugins/sync-docs/lib/enhance/security-patterns.js +0 -284
- package/plugins/sync-docs/lib/enhance/skill-analyzer.js +0 -182
- package/plugins/sync-docs/lib/enhance/skill-patterns.js +0 -147
- package/plugins/sync-docs/lib/enhance/suppression.js +0 -352
- package/plugins/sync-docs/lib/enhance/tool-patterns.js +0 -373
- package/plugins/sync-docs/lib/index.js +0 -270
- package/plugins/sync-docs/lib/patterns/cli-enhancers.js +0 -611
- package/plugins/sync-docs/lib/patterns/pipeline.js +0 -948
- package/plugins/sync-docs/lib/patterns/review-patterns.js +0 -558
- package/plugins/sync-docs/lib/patterns/slop-analyzers.js +0 -2305
- package/plugins/sync-docs/lib/patterns/slop-patterns.js +0 -1187
- package/plugins/sync-docs/lib/perf/analyzer/index.js +0 -22
- package/plugins/sync-docs/lib/perf/argument-parser.js +0 -105
- package/plugins/sync-docs/lib/perf/baseline-comparator.js +0 -50
- package/plugins/sync-docs/lib/perf/baseline-store.js +0 -127
- package/plugins/sync-docs/lib/perf/benchmark-runner.js +0 -404
- package/plugins/sync-docs/lib/perf/breaking-point-finder.js +0 -52
- package/plugins/sync-docs/lib/perf/breaking-point-runner.js +0 -60
- package/plugins/sync-docs/lib/perf/checkpoint.js +0 -123
- package/plugins/sync-docs/lib/perf/code-paths.js +0 -86
- package/plugins/sync-docs/lib/perf/consolidation.js +0 -37
- package/plugins/sync-docs/lib/perf/constraint-runner.js +0 -71
- package/plugins/sync-docs/lib/perf/experiment-runner.js +0 -32
- package/plugins/sync-docs/lib/perf/index.js +0 -41
- package/plugins/sync-docs/lib/perf/investigation-state.js +0 -874
- package/plugins/sync-docs/lib/perf/optimization-runner.js +0 -79
- package/plugins/sync-docs/lib/perf/profilers/go.js +0 -22
- package/plugins/sync-docs/lib/perf/profilers/index.js +0 -46
- package/plugins/sync-docs/lib/perf/profilers/java.js +0 -23
- package/plugins/sync-docs/lib/perf/profilers/node.js +0 -27
- package/plugins/sync-docs/lib/perf/profilers/python.js +0 -23
- package/plugins/sync-docs/lib/perf/profilers/rust.js +0 -23
- package/plugins/sync-docs/lib/perf/profiling-runner.js +0 -75
- package/plugins/sync-docs/lib/perf/schemas.js +0 -140
- package/plugins/sync-docs/lib/platform/detect-platform.js +0 -413
- package/plugins/sync-docs/lib/platform/detection-configs.js +0 -93
- package/plugins/sync-docs/lib/platform/state-dir.js +0 -132
- package/plugins/sync-docs/lib/platform/verify-tools.js +0 -182
- package/plugins/sync-docs/lib/repo-map/cache.js +0 -152
- package/plugins/sync-docs/lib/repo-map/concurrency.js +0 -29
- package/plugins/sync-docs/lib/repo-map/index.js +0 -222
- package/plugins/sync-docs/lib/repo-map/installer.js +0 -212
- package/plugins/sync-docs/lib/repo-map/queries/go.js +0 -27
- package/plugins/sync-docs/lib/repo-map/queries/index.js +0 -100
- package/plugins/sync-docs/lib/repo-map/queries/java.js +0 -38
- package/plugins/sync-docs/lib/repo-map/queries/javascript.js +0 -55
- package/plugins/sync-docs/lib/repo-map/queries/python.js +0 -24
- package/plugins/sync-docs/lib/repo-map/queries/rust.js +0 -73
- package/plugins/sync-docs/lib/repo-map/queries/typescript.js +0 -38
- package/plugins/sync-docs/lib/repo-map/runner.js +0 -1364
- package/plugins/sync-docs/lib/repo-map/updater.js +0 -562
- package/plugins/sync-docs/lib/repo-map/usage-analyzer.js +0 -407
- package/plugins/sync-docs/lib/schemas/plugin-manifest.schema.json +0 -57
- package/plugins/sync-docs/lib/schemas/validator.js +0 -247
- package/plugins/sync-docs/lib/sources/custom-handler.js +0 -199
- package/plugins/sync-docs/lib/sources/policy-questions.js +0 -246
- package/plugins/sync-docs/lib/sources/source-cache.js +0 -165
- package/plugins/sync-docs/lib/state/workflow-state.js +0 -576
- package/plugins/sync-docs/lib/types/agent-frontmatter.d.ts +0 -134
- package/plugins/sync-docs/lib/types/command-frontmatter.d.ts +0 -107
- package/plugins/sync-docs/lib/types/hook-frontmatter.d.ts +0 -115
- package/plugins/sync-docs/lib/types/index.d.ts +0 -84
- package/plugins/sync-docs/lib/types/plugin-manifest.d.ts +0 -102
- package/plugins/sync-docs/lib/types/skill-frontmatter.d.ts +0 -89
- package/plugins/sync-docs/lib/utils/atomic-write.js +0 -94
- package/plugins/sync-docs/lib/utils/cache-manager.js +0 -159
- package/plugins/sync-docs/lib/utils/command-parser.js +0 -0
- package/plugins/sync-docs/lib/utils/context-optimizer.js +0 -300
- package/plugins/sync-docs/lib/utils/deprecation.js +0 -37
- package/plugins/sync-docs/lib/utils/shell-escape.js +0 -88
- package/plugins/sync-docs/lib/utils/state-helpers.js +0 -61
- package/plugins/sync-docs/skills/sync-docs/SKILL.md +0 -351
package/bin/cli.js
CHANGED
|
@@ -8,10 +8,12 @@
|
|
|
8
8
|
* Remove: npm uninstall -g agentsys && agentsys --remove
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
-
const { execSync } = require('child_process');
|
|
11
|
+
const { execSync, execFileSync } = require('child_process');
|
|
12
12
|
const fs = require('fs');
|
|
13
13
|
const path = require('path');
|
|
14
14
|
const readline = require('readline');
|
|
15
|
+
const https = require('https');
|
|
16
|
+
const { createGunzip } = require('zlib');
|
|
15
17
|
|
|
16
18
|
const VERSION = require('../package.json').version;
|
|
17
19
|
// Use the installed npm package directory as source (no git clone needed)
|
|
@@ -20,7 +22,7 @@ const discovery = require('../lib/discovery');
|
|
|
20
22
|
const transforms = require('../lib/adapter-transforms');
|
|
21
23
|
|
|
22
24
|
// Valid tool names
|
|
23
|
-
const VALID_TOOLS = ['claude', 'opencode', 'codex'];
|
|
25
|
+
const VALID_TOOLS = ['claude', 'opencode', 'codex', 'cursor'];
|
|
24
26
|
|
|
25
27
|
function getInstallDir() {
|
|
26
28
|
const home = process.env.HOME || process.env.USERPROFILE;
|
|
@@ -54,7 +56,7 @@ function getConfigPath(platform) {
|
|
|
54
56
|
|
|
55
57
|
function commandExists(cmd) {
|
|
56
58
|
try {
|
|
57
|
-
|
|
59
|
+
execFileSync(process.platform === 'win32' ? 'where.exe' : 'which', [cmd], { stdio: 'pipe' });
|
|
58
60
|
return true;
|
|
59
61
|
} catch {
|
|
60
62
|
return false;
|
|
@@ -84,6 +86,9 @@ function parseArgs(args) {
|
|
|
84
86
|
stripModels: true, // Default: strip models
|
|
85
87
|
tool: null, // Single tool
|
|
86
88
|
tools: [], // Multiple tools
|
|
89
|
+
only: [], // --only flag: selective plugin install
|
|
90
|
+
subcommand: null, // 'update', 'list', 'install', 'remove', 'search'
|
|
91
|
+
subcommandArg: null, // argument for subcommand (e.g. plugin name)
|
|
87
92
|
};
|
|
88
93
|
|
|
89
94
|
for (let i = 0; i < args.length; i++) {
|
|
@@ -102,6 +107,10 @@ function parseArgs(args) {
|
|
|
102
107
|
} else if (arg === '--strip-models') {
|
|
103
108
|
// Legacy flag, now default behavior
|
|
104
109
|
result.stripModels = true;
|
|
110
|
+
} else if (arg === '--only' && args[i + 1]) {
|
|
111
|
+
const pluginList = args[i + 1].split(',').map(p => p.trim()).filter(Boolean);
|
|
112
|
+
result.only.push(...pluginList);
|
|
113
|
+
i++;
|
|
105
114
|
} else if (arg === '--tool' && args[i + 1]) {
|
|
106
115
|
const tool = args[i + 1].toLowerCase();
|
|
107
116
|
if (VALID_TOOLS.includes(tool)) {
|
|
@@ -121,6 +130,20 @@ function parseArgs(args) {
|
|
|
121
130
|
result.tools.push(tool);
|
|
122
131
|
}
|
|
123
132
|
i++;
|
|
133
|
+
} else if (['update', 'list', 'install', 'remove', 'search'].includes(arg)) {
|
|
134
|
+
result.subcommand = arg;
|
|
135
|
+
// Check for subcommand --help
|
|
136
|
+
if (args[i + 1] && (args[i + 1] === '--help' || args[i + 1] === '-h')) {
|
|
137
|
+
result.subcommandArg = '--help';
|
|
138
|
+
i++;
|
|
139
|
+
// For 'list': accept --all, --agents, --skills, --commands, --hooks, --plugins
|
|
140
|
+
} else if (arg === 'list' && args[i + 1] && ['--all', '--agents', '--skills', '--commands', '--hooks', '--plugins'].includes(args[i + 1])) {
|
|
141
|
+
result.subcommandArg = args[i + 1];
|
|
142
|
+
i++;
|
|
143
|
+
} else if (args[i + 1] && !args[i + 1].startsWith('-')) {
|
|
144
|
+
result.subcommandArg = args[i + 1];
|
|
145
|
+
i++;
|
|
146
|
+
}
|
|
124
147
|
}
|
|
125
148
|
}
|
|
126
149
|
|
|
@@ -191,6 +214,1007 @@ function installDependencies(installDir) {
|
|
|
191
214
|
execSync('npm install --production', { cwd: installDir, stdio: 'inherit' });
|
|
192
215
|
}
|
|
193
216
|
|
|
217
|
+
// --- External Plugin Fetching ---
|
|
218
|
+
|
|
219
|
+
function getPluginCacheDir() {
|
|
220
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
221
|
+
return path.join(home, '.agentsys', 'plugins');
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
function loadMarketplace() {
|
|
225
|
+
const marketplacePath = path.join(PACKAGE_DIR, '.claude-plugin', 'marketplace.json');
|
|
226
|
+
if (!fs.existsSync(marketplacePath)) {
|
|
227
|
+
console.error('[ERROR] marketplace.json not found at ' + marketplacePath);
|
|
228
|
+
process.exit(1);
|
|
229
|
+
}
|
|
230
|
+
return JSON.parse(fs.readFileSync(marketplacePath, 'utf8'));
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
/**
|
|
234
|
+
* Normalize marketplace plugin source entries.
|
|
235
|
+
*
|
|
236
|
+
* Supported formats:
|
|
237
|
+
* - string URL/path (legacy)
|
|
238
|
+
* - object: { source: "url", url: "..." } (current)
|
|
239
|
+
* - object: { source: "path", path: "..." } (local/bundled)
|
|
240
|
+
*
|
|
241
|
+
* @param {string|Object} source
|
|
242
|
+
* @returns {{type: 'remote'|'local', value: string}|null}
|
|
243
|
+
*/
|
|
244
|
+
function resolvePluginSource(source) {
|
|
245
|
+
if (typeof source === 'string') {
|
|
246
|
+
const value = source.trim();
|
|
247
|
+
if (!value) return null;
|
|
248
|
+
if (value.startsWith('./') || value.startsWith('../')) {
|
|
249
|
+
return { type: 'local', value };
|
|
250
|
+
}
|
|
251
|
+
return { type: 'remote', value };
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
if (!source || typeof source !== 'object') return null;
|
|
255
|
+
|
|
256
|
+
const sourceType = typeof source.source === 'string' ? source.source.toLowerCase() : null;
|
|
257
|
+
|
|
258
|
+
if ((sourceType === 'path' || sourceType === 'local') && typeof source.path === 'string') {
|
|
259
|
+
return { type: 'local', value: source.path };
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
if (sourceType === 'url' && typeof source.url === 'string') {
|
|
263
|
+
return { type: 'remote', value: source.url };
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
// Backward/forward-compatible fallbacks
|
|
267
|
+
if (typeof source.path === 'string') {
|
|
268
|
+
return { type: 'local', value: source.path };
|
|
269
|
+
}
|
|
270
|
+
if (typeof source.url === 'string') {
|
|
271
|
+
return { type: 'remote', value: source.url };
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
return null;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
/**
|
|
278
|
+
* Backward-compatible helper returning only the source URL/path value.
|
|
279
|
+
*
|
|
280
|
+
* @param {string|Object} source
|
|
281
|
+
* @returns {string|null}
|
|
282
|
+
*/
|
|
283
|
+
function resolveSourceUrl(source) {
|
|
284
|
+
const normalized = resolvePluginSource(source);
|
|
285
|
+
return normalized ? normalized.value : null;
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
/**
|
|
289
|
+
* Resolve plugin dependencies transitively.
|
|
290
|
+
*
|
|
291
|
+
* Circular dependencies are expected and handled: the `visiting` Set tracks
|
|
292
|
+
* the current DFS path and short-circuits any back-edge (e.g. next-task ->
|
|
293
|
+
* ship -> next-task), adding the already-visited node to `resolved` and
|
|
294
|
+
* returning immediately so the traversal terminates without infinite recursion.
|
|
295
|
+
*
|
|
296
|
+
* @param {string[]} names - Plugin names to resolve
|
|
297
|
+
* @param {Object} marketplace - Parsed marketplace.json
|
|
298
|
+
* @returns {string[]} All required plugin names (deduplicated, topologically ordered)
|
|
299
|
+
*/
|
|
300
|
+
function resolvePluginDeps(names, marketplace) {
|
|
301
|
+
const pluginMap = {};
|
|
302
|
+
for (const p of marketplace.plugins) {
|
|
303
|
+
pluginMap[p.name] = p;
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
// Validate requested names exist
|
|
307
|
+
for (const name of names) {
|
|
308
|
+
if (!pluginMap[name]) {
|
|
309
|
+
console.error(`[ERROR] Unknown plugin: ${name}. Available: ${marketplace.plugins.map(p => p.name).join(', ')}`);
|
|
310
|
+
process.exit(1);
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
const resolved = new Set();
|
|
315
|
+
const visiting = new Set();
|
|
316
|
+
|
|
317
|
+
function visit(name) {
|
|
318
|
+
if (resolved.has(name)) return;
|
|
319
|
+
if (visiting.has(name)) {
|
|
320
|
+
// Circular dep - just add it and stop recursing
|
|
321
|
+
resolved.add(name);
|
|
322
|
+
return;
|
|
323
|
+
}
|
|
324
|
+
visiting.add(name);
|
|
325
|
+
|
|
326
|
+
visiting.delete(name);
|
|
327
|
+
resolved.add(name);
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
for (const name of names) {
|
|
331
|
+
visit(name);
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
return [...resolved];
|
|
335
|
+
}
|
|
336
|
+
|
|
337
|
+
/**
|
|
338
|
+
* Download a GitHub repo tarball and extract to cache directory.
|
|
339
|
+
*
|
|
340
|
+
* @param {string} name - Plugin name
|
|
341
|
+
* @param {string} source - GitHub source URL (e.g. "github:agent-sh/agentsys-plugin-next-task")
|
|
342
|
+
* @param {string} version - Expected version string
|
|
343
|
+
* @returns {Promise<string>} Path to extracted plugin directory
|
|
344
|
+
*/
|
|
345
|
+
async function fetchPlugin(name, source, version) {
|
|
346
|
+
const cacheDir = getPluginCacheDir();
|
|
347
|
+
const pluginDir = path.join(cacheDir, name);
|
|
348
|
+
const versionFile = path.join(pluginDir, '.version');
|
|
349
|
+
|
|
350
|
+
// Check cache
|
|
351
|
+
if (fs.existsSync(versionFile)) {
|
|
352
|
+
const cached = fs.readFileSync(versionFile, 'utf8').trim();
|
|
353
|
+
if (cached === version) {
|
|
354
|
+
return pluginDir;
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
const parsedSource = parseGitHubSource(source, version, name);
|
|
359
|
+
const owner = parsedSource.owner;
|
|
360
|
+
const repo = parsedSource.repo;
|
|
361
|
+
|
|
362
|
+
const refCandidates = parsedSource.explicitRef
|
|
363
|
+
? [parsedSource.ref]
|
|
364
|
+
: [parsedSource.ref, version, 'main', 'master'];
|
|
365
|
+
|
|
366
|
+
let lastError = null;
|
|
367
|
+
for (const ref of [...new Set(refCandidates.filter(Boolean))]) {
|
|
368
|
+
const tarballUrl = `https://api.github.com/repos/${owner}/${repo}/tarball/${ref}`;
|
|
369
|
+
|
|
370
|
+
try {
|
|
371
|
+
console.log(` Fetching ${name}@${version} from ${owner}/${repo} (${ref})...`);
|
|
372
|
+
|
|
373
|
+
// Clean and recreate
|
|
374
|
+
if (fs.existsSync(pluginDir)) {
|
|
375
|
+
fs.rmSync(pluginDir, { recursive: true, force: true });
|
|
376
|
+
}
|
|
377
|
+
fs.mkdirSync(pluginDir, { recursive: true });
|
|
378
|
+
|
|
379
|
+
// Download and extract tarball
|
|
380
|
+
await downloadAndExtractTarball(tarballUrl, pluginDir);
|
|
381
|
+
|
|
382
|
+
// Write version marker
|
|
383
|
+
fs.writeFileSync(versionFile, version);
|
|
384
|
+
return pluginDir;
|
|
385
|
+
} catch (err) {
|
|
386
|
+
lastError = err;
|
|
387
|
+
const isNotFound = /HTTP 404/.test(err.message);
|
|
388
|
+
if (isNotFound && !parsedSource.explicitRef) {
|
|
389
|
+
continue;
|
|
390
|
+
}
|
|
391
|
+
throw err;
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
|
|
395
|
+
throw new Error(
|
|
396
|
+
`Unable to fetch ${name} from ${owner}/${repo}. Tried refs: ${[...new Set(refCandidates.filter(Boolean))].join(', ')}. Last error: ${lastError ? lastError.message : 'unknown error'}`
|
|
397
|
+
);
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
/**
|
|
401
|
+
* Parse GitHub source URL formats and normalize repo name.
|
|
402
|
+
*
|
|
403
|
+
* @param {string} source
|
|
404
|
+
* @param {string} version
|
|
405
|
+
* @param {string} [name]
|
|
406
|
+
* @returns {{owner: string, repo: string, ref: string, explicitRef: boolean}}
|
|
407
|
+
*/
|
|
408
|
+
function parseGitHubSource(source, version, name = 'plugin') {
|
|
409
|
+
// Parse source formats:
|
|
410
|
+
// "https://github.com/owner/repo" or "https://github.com/owner/repo#ref"
|
|
411
|
+
// "github:owner/repo" or "github:owner/repo#ref"
|
|
412
|
+
const urlMatch = source.match(/github\.com\/([^/]+)\/([^/#]+)(?:#(.+))?/);
|
|
413
|
+
const shortMatch = !urlMatch && source.match(/^github:([^/]+)\/([^#]+)(?:#(.+))?$/);
|
|
414
|
+
const match = urlMatch || shortMatch;
|
|
415
|
+
if (!match) {
|
|
416
|
+
throw new Error(`Unsupported source format for ${name}: ${source}`);
|
|
417
|
+
}
|
|
418
|
+
|
|
419
|
+
const owner = match[1];
|
|
420
|
+
const repo = match[2].replace(/\.git$/, '');
|
|
421
|
+
const explicitRef = Boolean(match[3]);
|
|
422
|
+
const ref = match[3] || `v${version}`;
|
|
423
|
+
return { owner, repo, ref, explicitRef };
|
|
424
|
+
}
|
|
425
|
+
|
|
426
|
+
/**
|
|
427
|
+
* Download a tarball from URL and extract to dest directory.
|
|
428
|
+
* Strips the top-level directory from the tarball (GitHub tarballs have owner-repo-sha/).
|
|
429
|
+
*/
|
|
430
|
+
function downloadAndExtractTarball(url, dest) {
|
|
431
|
+
return new Promise((resolve, reject) => {
|
|
432
|
+
const ghToken = process.env.GITHUB_TOKEN || process.env.GH_TOKEN;
|
|
433
|
+
const request = (reqUrl, redirectCount = 0) => {
|
|
434
|
+
if (redirectCount > 5) {
|
|
435
|
+
reject(new Error(`Too many redirects fetching tarball from ${url}`));
|
|
436
|
+
return;
|
|
437
|
+
}
|
|
438
|
+
const headers = {
|
|
439
|
+
'User-Agent': `agentsys/${VERSION}`,
|
|
440
|
+
'Accept': 'application/vnd.github+json'
|
|
441
|
+
};
|
|
442
|
+
if (ghToken) headers['Authorization'] = `Bearer ${ghToken}`;
|
|
443
|
+
https.get(reqUrl, { headers }, (res) => {
|
|
444
|
+
// Follow redirects (GitHub API returns 302 to S3)
|
|
445
|
+
if (res.statusCode === 301 || res.statusCode === 302) {
|
|
446
|
+
res.resume();
|
|
447
|
+
request(res.headers.location, redirectCount + 1);
|
|
448
|
+
return;
|
|
449
|
+
}
|
|
450
|
+
|
|
451
|
+
if (res.statusCode !== 200) {
|
|
452
|
+
res.resume();
|
|
453
|
+
const hint = res.statusCode === 403 ? ' (rate limited — set GITHUB_TOKEN env var)' : '';
|
|
454
|
+
reject(new Error(`HTTP ${res.statusCode}${hint} fetching tarball from ${reqUrl}`));
|
|
455
|
+
return;
|
|
456
|
+
}
|
|
457
|
+
|
|
458
|
+
// Use tar command to extract (available on all supported platforms)
|
|
459
|
+
// On Windows/MSYS2, convert backslash paths to forward slashes for tar
|
|
460
|
+
const tarDest = process.platform === 'win32' ? dest.replace(/\\/g, '/') : dest;
|
|
461
|
+
const tar = require('child_process').spawn('tar', [
|
|
462
|
+
'xz', '--strip-components=1', '-C', tarDest
|
|
463
|
+
], { stdio: ['pipe', 'inherit', 'pipe'] });
|
|
464
|
+
|
|
465
|
+
let stderr = '';
|
|
466
|
+
tar.stderr.on('data', (d) => { stderr += d; });
|
|
467
|
+
|
|
468
|
+
res.pipe(tar.stdin);
|
|
469
|
+
|
|
470
|
+
tar.on('close', (code) => {
|
|
471
|
+
if (code !== 0) {
|
|
472
|
+
reject(new Error(`tar extraction failed (code ${code}): ${stderr}`));
|
|
473
|
+
} else {
|
|
474
|
+
resolve();
|
|
475
|
+
}
|
|
476
|
+
});
|
|
477
|
+
|
|
478
|
+
tar.on('error', reject);
|
|
479
|
+
}).on('error', reject);
|
|
480
|
+
};
|
|
481
|
+
|
|
482
|
+
request(url);
|
|
483
|
+
});
|
|
484
|
+
}
|
|
485
|
+
|
|
486
|
+
/**
|
|
487
|
+
* Discover plugins from the external cache directory (~/.agentsys/plugins/).
|
|
488
|
+
* Falls back to PACKAGE_DIR/plugins/ if cache doesn't exist (bundled install).
|
|
489
|
+
*
|
|
490
|
+
* @param {string[]} [onlyPlugins] - If provided, only return these plugins
|
|
491
|
+
* @returns {string} The root directory to use for plugin discovery
|
|
492
|
+
*/
|
|
493
|
+
function resolvePluginRoot(onlyPlugins) {
|
|
494
|
+
const cacheDir = getPluginCacheDir();
|
|
495
|
+
// If we have cached external plugins, use the cache dir
|
|
496
|
+
if (fs.existsSync(cacheDir)) {
|
|
497
|
+
const entries = fs.readdirSync(cacheDir).filter(e => {
|
|
498
|
+
const pluginJson = path.join(cacheDir, e, '.claude-plugin', 'plugin.json');
|
|
499
|
+
return fs.existsSync(pluginJson);
|
|
500
|
+
});
|
|
501
|
+
if (entries.length > 0) {
|
|
502
|
+
// Return a synthetic root where plugins/ is the cache dir
|
|
503
|
+
// We need to restructure: cache has ~/.agentsys/plugins/<name>/
|
|
504
|
+
// but discovery expects <root>/plugins/<name>/
|
|
505
|
+
// The cache dir IS the plugins dir, so root is its parent
|
|
506
|
+
return path.join(cacheDir, '..');
|
|
507
|
+
}
|
|
508
|
+
}
|
|
509
|
+
// Fallback to bundled
|
|
510
|
+
return PACKAGE_DIR;
|
|
511
|
+
}
|
|
512
|
+
|
|
513
|
+
/**
|
|
514
|
+
* Fetch all requested plugins (with dependency resolution) to the cache.
|
|
515
|
+
*
|
|
516
|
+
* @param {string[]} pluginNames - Plugins to fetch (empty = all)
|
|
517
|
+
* @param {Object} marketplace - Parsed marketplace.json
|
|
518
|
+
* @returns {Promise<string[]>} Names of fetched plugins
|
|
519
|
+
*/
|
|
520
|
+
async function fetchExternalPlugins(pluginNames, marketplace) {
|
|
521
|
+
const pluginMap = {};
|
|
522
|
+
for (const p of marketplace.plugins) {
|
|
523
|
+
pluginMap[p.name] = p;
|
|
524
|
+
}
|
|
525
|
+
|
|
526
|
+
// Determine which plugins to fetch
|
|
527
|
+
let toFetch;
|
|
528
|
+
if (pluginNames.length > 0) {
|
|
529
|
+
toFetch = resolvePluginDeps(pluginNames, marketplace);
|
|
530
|
+
} else {
|
|
531
|
+
toFetch = marketplace.plugins.map(p => p.name);
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
console.log(`\nFetching ${toFetch.length} plugin(s): ${toFetch.join(', ')}\n`);
|
|
535
|
+
|
|
536
|
+
const fetched = [];
|
|
537
|
+
const failed = [];
|
|
538
|
+
for (const name of toFetch) {
|
|
539
|
+
const plugin = pluginMap[name];
|
|
540
|
+
if (!plugin) continue;
|
|
541
|
+
|
|
542
|
+
const source = resolvePluginSource(plugin.source);
|
|
543
|
+
|
|
544
|
+
// Local/bundled plugin, no external fetch needed
|
|
545
|
+
if (!source || source.type === 'local') {
|
|
546
|
+
// Bundled plugin, no fetch needed
|
|
547
|
+
fetched.push(name);
|
|
548
|
+
continue;
|
|
549
|
+
}
|
|
550
|
+
|
|
551
|
+
try {
|
|
552
|
+
await fetchPlugin(name, source.value, plugin.version);
|
|
553
|
+
fetched.push(name);
|
|
554
|
+
} catch (err) {
|
|
555
|
+
failed.push(name);
|
|
556
|
+
console.error(` [ERROR] Failed to fetch ${name}: ${err.message}`);
|
|
557
|
+
}
|
|
558
|
+
}
|
|
559
|
+
|
|
560
|
+
if (failed.length > 0) {
|
|
561
|
+
const missingDeps = failed.filter(f => toFetch.includes(f) && !pluginNames.includes(f));
|
|
562
|
+
if (missingDeps.length > 0) {
|
|
563
|
+
console.error(`\n [WARN] Missing dependencies: ${missingDeps.join(', ')}`);
|
|
564
|
+
console.error(` Some plugins may not work correctly without their dependencies.`);
|
|
565
|
+
}
|
|
566
|
+
|
|
567
|
+
throw new Error(`Failed to fetch ${failed.length} plugin(s): ${failed.join(', ')}`);
|
|
568
|
+
}
|
|
569
|
+
|
|
570
|
+
return fetched;
|
|
571
|
+
}
|
|
572
|
+
|
|
573
|
+
/**
|
|
574
|
+
* List installed plugins and their components.
|
|
575
|
+
* @param {string} [filter] - 'all', 'plugins', 'agents', 'skills', 'commands', 'hooks', or null (default: plugins summary)
|
|
576
|
+
*/
|
|
577
|
+
function listInstalledPlugins(filter) {
|
|
578
|
+
const cacheDir = getPluginCacheDir();
|
|
579
|
+
const installed = loadInstalledJson();
|
|
580
|
+
const showAll = filter === 'all' || filter === '--all';
|
|
581
|
+
const showPlugins = !filter || filter === 'plugins' || filter === '--plugins' || showAll;
|
|
582
|
+
const showAgents = filter === 'agents' || filter === '--agents' || showAll;
|
|
583
|
+
const showSkills = filter === 'skills' || filter === '--skills' || showAll;
|
|
584
|
+
const showCommands = filter === 'commands' || filter === '--commands' || showAll;
|
|
585
|
+
const showHooks = filter === 'hooks' || filter === '--hooks' || showAll;
|
|
586
|
+
|
|
587
|
+
console.log(`\nagentsys v${VERSION}\n`);
|
|
588
|
+
|
|
589
|
+
// Gather all cached plugins
|
|
590
|
+
const plugins = [];
|
|
591
|
+
if (fs.existsSync(cacheDir)) {
|
|
592
|
+
const entries = fs.readdirSync(cacheDir).filter(e => {
|
|
593
|
+
return fs.statSync(path.join(cacheDir, e)).isDirectory();
|
|
594
|
+
}).sort();
|
|
595
|
+
for (const name of entries) {
|
|
596
|
+
const pluginDir = path.join(cacheDir, name);
|
|
597
|
+
const versionFile = path.join(pluginDir, '.version');
|
|
598
|
+
const ver = fs.existsSync(versionFile) ? fs.readFileSync(versionFile, 'utf8').trim() : 'unknown';
|
|
599
|
+
const components = loadComponents(pluginDir);
|
|
600
|
+
const entry = installed.plugins[name] || {};
|
|
601
|
+
const hooksFile = path.join(pluginDir, 'hooks', 'hooks.json');
|
|
602
|
+
const hasHooks = fs.existsSync(hooksFile);
|
|
603
|
+
plugins.push({ name, version: ver, components, entry, hasHooks, dir: pluginDir });
|
|
604
|
+
}
|
|
605
|
+
}
|
|
606
|
+
|
|
607
|
+
if (plugins.length === 0) {
|
|
608
|
+
console.log('No plugins installed. Run: agentsys install <plugin>\n');
|
|
609
|
+
return;
|
|
610
|
+
}
|
|
611
|
+
|
|
612
|
+
if (showPlugins && !showAll) {
|
|
613
|
+
// Default view: plugin summary
|
|
614
|
+
console.log('PLUGINS');
|
|
615
|
+
for (const p of plugins) {
|
|
616
|
+
const scope = p.entry.scope || 'full';
|
|
617
|
+
const scopeTag = scope === 'partial' ? '[partial]' : '[full]';
|
|
618
|
+
const platforms = p.entry.platforms ? p.entry.platforms.join(', ') : '';
|
|
619
|
+
const counts = [];
|
|
620
|
+
if (p.components.agents.length) counts.push(`${p.components.agents.length} agents`);
|
|
621
|
+
if (p.components.skills.length) counts.push(`${p.components.skills.length} skills`);
|
|
622
|
+
if (p.components.commands.length) counts.push(`${p.components.commands.length} cmds`);
|
|
623
|
+
if (p.hasHooks) counts.push('hooks');
|
|
624
|
+
console.log(` ${p.name.padEnd(18)} ${p.version.padEnd(10)} ${scopeTag.padEnd(10)} ${counts.join(', ')} ${platforms}`);
|
|
625
|
+
}
|
|
626
|
+
console.log();
|
|
627
|
+
console.log(` ${plugins.length} plugins. Use --all, --agents, --skills, --commands, --hooks for details.`);
|
|
628
|
+
console.log();
|
|
629
|
+
return;
|
|
630
|
+
}
|
|
631
|
+
|
|
632
|
+
if (showAll || showPlugins) {
|
|
633
|
+
console.log('PLUGINS');
|
|
634
|
+
for (const p of plugins) {
|
|
635
|
+
const scope = p.entry.scope || 'full';
|
|
636
|
+
const scopeTag = scope === 'partial' ? '[partial]' : '[full]';
|
|
637
|
+
console.log(` ${p.name}@${p.version} ${scopeTag}`);
|
|
638
|
+
}
|
|
639
|
+
console.log();
|
|
640
|
+
}
|
|
641
|
+
|
|
642
|
+
if (showAgents) {
|
|
643
|
+
console.log('AGENTS');
|
|
644
|
+
let total = 0;
|
|
645
|
+
for (const p of plugins) {
|
|
646
|
+
for (const a of p.components.agents) {
|
|
647
|
+
console.log(` ${p.name}:${a.name.padEnd(28)} ${(a.model || '').padEnd(8)} ${a.description || ''}`);
|
|
648
|
+
total++;
|
|
649
|
+
}
|
|
650
|
+
}
|
|
651
|
+
if (total === 0) console.log(' (none)');
|
|
652
|
+
console.log();
|
|
653
|
+
}
|
|
654
|
+
|
|
655
|
+
if (showSkills) {
|
|
656
|
+
console.log('SKILLS');
|
|
657
|
+
let total = 0;
|
|
658
|
+
for (const p of plugins) {
|
|
659
|
+
for (const s of p.components.skills) {
|
|
660
|
+
console.log(` ${p.name}:${s.name.padEnd(28)} ${s.description || ''}`);
|
|
661
|
+
total++;
|
|
662
|
+
}
|
|
663
|
+
}
|
|
664
|
+
if (total === 0) console.log(' (none)');
|
|
665
|
+
console.log();
|
|
666
|
+
}
|
|
667
|
+
|
|
668
|
+
if (showCommands) {
|
|
669
|
+
console.log('COMMANDS');
|
|
670
|
+
let total = 0;
|
|
671
|
+
for (const p of plugins) {
|
|
672
|
+
for (const c of p.components.commands) {
|
|
673
|
+
console.log(` /${c.name.padEnd(29)} ${c.description || ''}`);
|
|
674
|
+
total++;
|
|
675
|
+
}
|
|
676
|
+
}
|
|
677
|
+
if (total === 0) console.log(' (none)');
|
|
678
|
+
console.log();
|
|
679
|
+
}
|
|
680
|
+
|
|
681
|
+
if (showHooks) {
|
|
682
|
+
console.log('HOOKS');
|
|
683
|
+
let total = 0;
|
|
684
|
+
for (const p of plugins) {
|
|
685
|
+
if (p.hasHooks) {
|
|
686
|
+
try {
|
|
687
|
+
const hooks = JSON.parse(fs.readFileSync(path.join(p.dir, 'hooks', 'hooks.json'), 'utf8'));
|
|
688
|
+
const hookList = Array.isArray(hooks) ? hooks : (hooks.hooks || []);
|
|
689
|
+
for (const h of hookList) {
|
|
690
|
+
const event = h.event || h.matcher || 'unknown';
|
|
691
|
+
console.log(` ${p.name}:${String(event).padEnd(28)} ${h.description || ''}`);
|
|
692
|
+
total++;
|
|
693
|
+
}
|
|
694
|
+
} catch { /* skip malformed hooks */ }
|
|
695
|
+
}
|
|
696
|
+
}
|
|
697
|
+
if (total === 0) console.log(' (none)');
|
|
698
|
+
console.log();
|
|
699
|
+
}
|
|
700
|
+
}
|
|
701
|
+
|
|
702
|
+
/**
|
|
703
|
+
* Re-fetch all installed external plugins (update to latest versions).
|
|
704
|
+
*/
|
|
705
|
+
async function updatePlugins() {
|
|
706
|
+
console.log(`\nagentsys v${VERSION} - Updating plugins\n`);
|
|
707
|
+
|
|
708
|
+
const marketplace = loadMarketplace();
|
|
709
|
+
const cacheDir = getPluginCacheDir();
|
|
710
|
+
|
|
711
|
+
if (!fs.existsSync(cacheDir)) {
|
|
712
|
+
console.log('No cached plugins found. Run agentsys to install first.');
|
|
713
|
+
return;
|
|
714
|
+
}
|
|
715
|
+
|
|
716
|
+
// Get currently installed external plugins
|
|
717
|
+
const installed = fs.readdirSync(cacheDir).filter(e => {
|
|
718
|
+
return fs.statSync(path.join(cacheDir, e)).isDirectory();
|
|
719
|
+
});
|
|
720
|
+
|
|
721
|
+
if (installed.length === 0) {
|
|
722
|
+
console.log('No external plugins installed.');
|
|
723
|
+
return;
|
|
724
|
+
}
|
|
725
|
+
|
|
726
|
+
// Force re-fetch by removing version files
|
|
727
|
+
for (const name of installed) {
|
|
728
|
+
const versionFile = path.join(cacheDir, name, '.version');
|
|
729
|
+
if (fs.existsSync(versionFile)) {
|
|
730
|
+
fs.unlinkSync(versionFile);
|
|
731
|
+
}
|
|
732
|
+
}
|
|
733
|
+
|
|
734
|
+
await fetchExternalPlugins(installed, marketplace);
|
|
735
|
+
console.log('\n[OK] Plugins updated.');
|
|
736
|
+
}
|
|
737
|
+
|
|
738
|
+
// --- installed.json manifest ---
|
|
739
|
+
|
|
740
|
+
function getInstalledJsonPath() {
|
|
741
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
742
|
+
return path.join(home, '.agentsys', 'installed.json');
|
|
743
|
+
}
|
|
744
|
+
|
|
745
|
+
function loadInstalledJson() {
|
|
746
|
+
const p = getInstalledJsonPath();
|
|
747
|
+
if (fs.existsSync(p)) {
|
|
748
|
+
try {
|
|
749
|
+
return JSON.parse(fs.readFileSync(p, 'utf8'));
|
|
750
|
+
} catch {
|
|
751
|
+
return { plugins: {} };
|
|
752
|
+
}
|
|
753
|
+
}
|
|
754
|
+
return { plugins: {} };
|
|
755
|
+
}
|
|
756
|
+
|
|
757
|
+
function saveInstalledJson(data) {
|
|
758
|
+
const p = getInstalledJsonPath();
|
|
759
|
+
fs.mkdirSync(path.dirname(p), { recursive: true });
|
|
760
|
+
fs.writeFileSync(p, JSON.stringify(data, null, 2) + '\n');
|
|
761
|
+
}
|
|
762
|
+
|
|
763
|
+
function recordInstall(name, version, platforms, granular) {
|
|
764
|
+
const data = loadInstalledJson();
|
|
765
|
+
const entry = {
|
|
766
|
+
version,
|
|
767
|
+
installedAt: new Date().toISOString(),
|
|
768
|
+
platforms,
|
|
769
|
+
scope: 'full'
|
|
770
|
+
};
|
|
771
|
+
if (granular && granular.scope === 'partial') {
|
|
772
|
+
entry.scope = 'partial';
|
|
773
|
+
entry.agents = granular.agents || [];
|
|
774
|
+
entry.skills = granular.skills || [];
|
|
775
|
+
entry.commands = granular.commands || [];
|
|
776
|
+
}
|
|
777
|
+
data.plugins[name] = entry;
|
|
778
|
+
saveInstalledJson(data);
|
|
779
|
+
}
|
|
780
|
+
|
|
781
|
+
function recordRemove(name) {
|
|
782
|
+
const data = loadInstalledJson();
|
|
783
|
+
delete data.plugins[name];
|
|
784
|
+
saveInstalledJson(data);
|
|
785
|
+
}
|
|
786
|
+
|
|
787
|
+
// --- Core version compatibility check ---
|
|
788
|
+
|
|
789
|
+
/**
|
|
790
|
+
* Simple semver range check. Supports ">=X.Y.Z" format.
|
|
791
|
+
* Returns true if ver satisfies the range.
|
|
792
|
+
*/
|
|
793
|
+
function satisfiesRange(ver, range) {
|
|
794
|
+
if (!range) return true;
|
|
795
|
+
const parseVer = (s) => {
|
|
796
|
+
const m = s.match(/^(\d+)\.(\d+)\.(\d+)/);
|
|
797
|
+
return m ? [parseInt(m[1]), parseInt(m[2]), parseInt(m[3])] : null;
|
|
798
|
+
};
|
|
799
|
+
|
|
800
|
+
const greaterEq = range.match(/^>=(.+)$/);
|
|
801
|
+
if (greaterEq) {
|
|
802
|
+
const required = parseVer(greaterEq[1]);
|
|
803
|
+
const actual = parseVer(ver);
|
|
804
|
+
if (!required || !actual) return true;
|
|
805
|
+
for (let i = 0; i < 3; i++) {
|
|
806
|
+
if (actual[i] > required[i]) return true;
|
|
807
|
+
if (actual[i] < required[i]) return false;
|
|
808
|
+
}
|
|
809
|
+
return true; // equal
|
|
810
|
+
}
|
|
811
|
+
return true; // unknown range format, don't block
|
|
812
|
+
}
|
|
813
|
+
|
|
814
|
+
function checkCoreCompat(pluginEntry) {
|
|
815
|
+
// Core version compat check removed - field deprecated in schema
|
|
816
|
+
}
|
|
817
|
+
|
|
818
|
+
// --- Granular install helpers ---
|
|
819
|
+
|
|
820
|
+
/**
|
|
821
|
+
* Parse "plugin:component" install target format.
|
|
822
|
+
* @param {string} arg - e.g. "next-task:ci-fixer" or "next-task" or "next-task@1.0.0"
|
|
823
|
+
* @returns {{ plugin: string, component: string|null, version: string|null }}
|
|
824
|
+
*/
|
|
825
|
+
function parseInstallTarget(arg) {
|
|
826
|
+
if (!arg || typeof arg !== 'string') {
|
|
827
|
+
return { plugin: null, component: null, version: null };
|
|
828
|
+
}
|
|
829
|
+
|
|
830
|
+
let plugin = arg;
|
|
831
|
+
let component = null;
|
|
832
|
+
let version = null;
|
|
833
|
+
|
|
834
|
+
// Check for colon (component separator) before @ (version separator)
|
|
835
|
+
const colonIdx = plugin.indexOf(':');
|
|
836
|
+
if (colonIdx > 0) {
|
|
837
|
+
component = plugin.slice(colonIdx + 1) || null;
|
|
838
|
+
plugin = plugin.slice(0, colonIdx);
|
|
839
|
+
}
|
|
840
|
+
|
|
841
|
+
// Check for @version on the plugin part
|
|
842
|
+
const atIdx = plugin.indexOf('@');
|
|
843
|
+
if (atIdx > 0) {
|
|
844
|
+
version = plugin.slice(atIdx + 1) || null;
|
|
845
|
+
plugin = plugin.slice(0, atIdx);
|
|
846
|
+
}
|
|
847
|
+
|
|
848
|
+
return { plugin: plugin || null, component, version };
|
|
849
|
+
}
|
|
850
|
+
|
|
851
|
+
/**
|
|
852
|
+
* Load components.json from a cached plugin directory.
|
|
853
|
+
* @param {string} pluginDir - Path to the cached plugin directory
|
|
854
|
+
* @returns {{ agents: Array, skills: Array, commands: Array }}
|
|
855
|
+
*/
|
|
856
|
+
function loadComponents(pluginDir) {
|
|
857
|
+
const componentsPath = path.join(pluginDir, 'components.json');
|
|
858
|
+
if (fs.existsSync(componentsPath)) {
|
|
859
|
+
try {
|
|
860
|
+
const data = JSON.parse(fs.readFileSync(componentsPath, 'utf8'));
|
|
861
|
+
const normalize = (arr) => (arr || []).map(item =>
|
|
862
|
+
typeof item === 'string' ? { name: item } : item
|
|
863
|
+
);
|
|
864
|
+
return {
|
|
865
|
+
agents: normalize(data.agents),
|
|
866
|
+
skills: normalize(data.skills),
|
|
867
|
+
commands: normalize(data.commands)
|
|
868
|
+
};
|
|
869
|
+
} catch {
|
|
870
|
+
// Fall through to filesystem scan
|
|
871
|
+
}
|
|
872
|
+
}
|
|
873
|
+
|
|
874
|
+
// Fallback: scan filesystem
|
|
875
|
+
const components = { agents: [], skills: [], commands: [] };
|
|
876
|
+
|
|
877
|
+
const agentsDir = path.join(pluginDir, 'agents');
|
|
878
|
+
if (fs.existsSync(agentsDir)) {
|
|
879
|
+
const files = fs.readdirSync(agentsDir).filter(f => f.endsWith('.md'));
|
|
880
|
+
for (const f of files) {
|
|
881
|
+
components.agents.push({ name: f.replace(/\.md$/, ''), file: `agents/${f}` });
|
|
882
|
+
}
|
|
883
|
+
}
|
|
884
|
+
|
|
885
|
+
const skillsDir = path.join(pluginDir, 'skills');
|
|
886
|
+
if (fs.existsSync(skillsDir)) {
|
|
887
|
+
const dirs = fs.readdirSync(skillsDir, { withFileTypes: true }).filter(d => d.isDirectory());
|
|
888
|
+
for (const d of dirs) {
|
|
889
|
+
if (fs.existsSync(path.join(skillsDir, d.name, 'SKILL.md'))) {
|
|
890
|
+
components.skills.push({ name: d.name, dir: `skills/${d.name}` });
|
|
891
|
+
}
|
|
892
|
+
}
|
|
893
|
+
}
|
|
894
|
+
|
|
895
|
+
const commandsDir = path.join(pluginDir, 'commands');
|
|
896
|
+
if (fs.existsSync(commandsDir)) {
|
|
897
|
+
const files = fs.readdirSync(commandsDir).filter(f => f.endsWith('.md'));
|
|
898
|
+
for (const f of files) {
|
|
899
|
+
components.commands.push({ name: f.replace(/\.md$/, ''), file: `commands/${f}` });
|
|
900
|
+
}
|
|
901
|
+
}
|
|
902
|
+
|
|
903
|
+
return components;
|
|
904
|
+
}
|
|
905
|
+
|
|
906
|
+
/**
|
|
907
|
+
* Resolve which type a component belongs to.
|
|
908
|
+
* @param {{ agents: Array, skills: Array, commands: Array }} components
|
|
909
|
+
* @param {string} name - Component name to find
|
|
910
|
+
* @returns {{ type: string, name: string, file?: string, dir?: string }|null}
|
|
911
|
+
*/
|
|
912
|
+
function resolveComponent(components, name) {
|
|
913
|
+
if (!name || !components) return null;
|
|
914
|
+
|
|
915
|
+
for (const agent of components.agents) {
|
|
916
|
+
if (agent.name === name) return { type: 'agent', name: agent.name, file: agent.file };
|
|
917
|
+
}
|
|
918
|
+
for (const skill of components.skills) {
|
|
919
|
+
if (skill.name === name) return { type: 'skill', name: skill.name, dir: skill.dir };
|
|
920
|
+
}
|
|
921
|
+
for (const cmd of components.commands) {
|
|
922
|
+
if (cmd.name === name) return { type: 'command', name: cmd.name, file: cmd.file };
|
|
923
|
+
}
|
|
924
|
+
return null;
|
|
925
|
+
}
|
|
926
|
+
|
|
927
|
+
/**
|
|
928
|
+
* Build a filter object from a resolved component.
|
|
929
|
+
* @param {{ type: string, name: string }} resolved
|
|
930
|
+
* @returns {{ agents: string[], skills: string[], commands: string[] }}
|
|
931
|
+
*/
|
|
932
|
+
function buildFilterFromComponent(resolved) {
|
|
933
|
+
const filter = { agents: [], skills: [], commands: [] };
|
|
934
|
+
if (resolved.type === 'agent') filter.agents.push(resolved.name);
|
|
935
|
+
else if (resolved.type === 'skill') filter.skills.push(resolved.name);
|
|
936
|
+
else if (resolved.type === 'command') filter.commands.push(resolved.name);
|
|
937
|
+
return filter;
|
|
938
|
+
}
|
|
939
|
+
|
|
940
|
+
// --- Detect which platforms are installed ---
|
|
941
|
+
|
|
942
|
+
function detectInstalledPlatforms() {
|
|
943
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
944
|
+
const platforms = [];
|
|
945
|
+
if (fs.existsSync(path.join(home, '.claude'))) platforms.push('claude');
|
|
946
|
+
const opencodeDir = getOpenCodeConfigDir();
|
|
947
|
+
if (fs.existsSync(opencodeDir)) platforms.push('opencode');
|
|
948
|
+
if (fs.existsSync(path.join(home, '.codex'))) platforms.push('codex');
|
|
949
|
+
// Cursor rules are project-scoped; detect only if Cursor rules/commands/skills exist in CWD
|
|
950
|
+
const cursorDir = path.join(process.cwd(), '.cursor');
|
|
951
|
+
if (fs.existsSync(path.join(cursorDir, 'rules')) || fs.existsSync(path.join(cursorDir, 'commands')) || fs.existsSync(path.join(cursorDir, 'skills'))) platforms.push('cursor');
|
|
952
|
+
return platforms;
|
|
953
|
+
}
|
|
954
|
+
|
|
955
|
+
// --- install subcommand ---
|
|
956
|
+
|
|
957
|
+
async function installPlugin(nameWithVersion, args) {
|
|
958
|
+
// Parse plugin:component and name[@version]
|
|
959
|
+
const target = parseInstallTarget(nameWithVersion);
|
|
960
|
+
let name = target.plugin;
|
|
961
|
+
let requestedVersion = target.version;
|
|
962
|
+
const componentName = target.component;
|
|
963
|
+
|
|
964
|
+
// Legacy fallback: handle plain name@version (parseInstallTarget already handles this)
|
|
965
|
+
if (!name) {
|
|
966
|
+
console.error('[ERROR] Usage: agentsys install <plugin[:component][@version]>');
|
|
967
|
+
process.exit(1);
|
|
968
|
+
}
|
|
969
|
+
|
|
970
|
+
const marketplace = loadMarketplace();
|
|
971
|
+
const pluginMap = {};
|
|
972
|
+
for (const p of marketplace.plugins) {
|
|
973
|
+
pluginMap[p.name] = p;
|
|
974
|
+
}
|
|
975
|
+
|
|
976
|
+
if (!pluginMap[name]) {
|
|
977
|
+
console.error(`[ERROR] Unknown plugin: ${name}`);
|
|
978
|
+
console.error(`Available: ${marketplace.plugins.map(p => p.name).join(', ')}`);
|
|
979
|
+
process.exit(1);
|
|
980
|
+
}
|
|
981
|
+
|
|
982
|
+
const plugin = pluginMap[name];
|
|
983
|
+
checkCoreCompat(plugin);
|
|
984
|
+
|
|
985
|
+
// Resolve deps
|
|
986
|
+
const toFetch = resolvePluginDeps([name], marketplace);
|
|
987
|
+
console.log(`\nInstalling ${name} (+ deps: ${toFetch.filter(n => n !== name).join(', ') || 'none'})\n`);
|
|
988
|
+
|
|
989
|
+
// Fetch all
|
|
990
|
+
for (const depName of toFetch) {
|
|
991
|
+
const dep = pluginMap[depName];
|
|
992
|
+
if (!dep) continue;
|
|
993
|
+
|
|
994
|
+
const source = resolvePluginSource(dep.source);
|
|
995
|
+
if (!source || source.type === 'local') continue;
|
|
996
|
+
|
|
997
|
+
checkCoreCompat(dep);
|
|
998
|
+
const ver = depName === name && requestedVersion ? requestedVersion : dep.version;
|
|
999
|
+
try {
|
|
1000
|
+
await fetchPlugin(depName, source.value, ver);
|
|
1001
|
+
} catch (err) {
|
|
1002
|
+
console.error(` [ERROR] Failed to fetch ${depName}: ${err.message}`);
|
|
1003
|
+
}
|
|
1004
|
+
}
|
|
1005
|
+
|
|
1006
|
+
// Determine platforms
|
|
1007
|
+
let platforms;
|
|
1008
|
+
if (args.tool) {
|
|
1009
|
+
platforms = [args.tool];
|
|
1010
|
+
} else if (args.tools.length > 0) {
|
|
1011
|
+
platforms = args.tools;
|
|
1012
|
+
} else {
|
|
1013
|
+
platforms = detectInstalledPlatforms();
|
|
1014
|
+
if (platforms.length === 0) platforms = ['claude']; // default
|
|
1015
|
+
}
|
|
1016
|
+
|
|
1017
|
+
console.log(`Installing for platforms: ${platforms.join(', ')}`);
|
|
1018
|
+
|
|
1019
|
+
// Resolve component filter if a specific component was requested
|
|
1020
|
+
let filter = null;
|
|
1021
|
+
if (componentName) {
|
|
1022
|
+
const cacheDir = getPluginCacheDir();
|
|
1023
|
+
const pluginDir = path.join(cacheDir, name);
|
|
1024
|
+
if (!fs.existsSync(pluginDir)) {
|
|
1025
|
+
console.error(`[ERROR] Plugin ${name} not found in cache after fetch.`);
|
|
1026
|
+
process.exit(1);
|
|
1027
|
+
}
|
|
1028
|
+
const components = loadComponents(pluginDir);
|
|
1029
|
+
const resolved = resolveComponent(components, componentName);
|
|
1030
|
+
if (!resolved) {
|
|
1031
|
+
const allNames = [
|
|
1032
|
+
...components.agents.map(a => a.name),
|
|
1033
|
+
...components.skills.map(s => s.name),
|
|
1034
|
+
...components.commands.map(c => c.name)
|
|
1035
|
+
];
|
|
1036
|
+
console.error(`[ERROR] Component "${componentName}" not found in plugin ${name}.`);
|
|
1037
|
+
if (allNames.length > 0) {
|
|
1038
|
+
console.error(`Available components: ${allNames.join(', ')}`);
|
|
1039
|
+
}
|
|
1040
|
+
process.exit(1);
|
|
1041
|
+
}
|
|
1042
|
+
filter = buildFilterFromComponent(resolved);
|
|
1043
|
+
console.log(` Installing ${resolved.type}: ${resolved.name}`);
|
|
1044
|
+
}
|
|
1045
|
+
|
|
1046
|
+
// Use cache as install source
|
|
1047
|
+
const installDir = getInstallDir();
|
|
1048
|
+
const needsLocal = platforms.includes('opencode') || platforms.includes('codex') || platforms.includes('cursor');
|
|
1049
|
+
if (needsLocal && !fs.existsSync(path.join(installDir, 'lib'))) {
|
|
1050
|
+
// Need local install for transforms
|
|
1051
|
+
cleanOldInstallation(installDir);
|
|
1052
|
+
copyFromPackage(installDir);
|
|
1053
|
+
}
|
|
1054
|
+
|
|
1055
|
+
for (const platform of platforms) {
|
|
1056
|
+
if (platform === 'claude') {
|
|
1057
|
+
if (filter) {
|
|
1058
|
+
console.log(' [NOTE] Claude Code installs whole plugins (granular not supported). Installing full plugin.');
|
|
1059
|
+
}
|
|
1060
|
+
// Claude uses marketplace install
|
|
1061
|
+
if (commandExists('claude')) {
|
|
1062
|
+
try { execSync('claude plugin marketplace add agent-sh/agentsys', { stdio: 'pipe' }); } catch {}
|
|
1063
|
+
for (const depName of toFetch) {
|
|
1064
|
+
if (!/^[a-z0-9][a-z0-9-]*$/.test(depName)) continue;
|
|
1065
|
+
try {
|
|
1066
|
+
execSync(`claude plugin install ${depName}@agentsys`, { stdio: 'pipe' });
|
|
1067
|
+
} catch {
|
|
1068
|
+
try { execSync(`claude plugin update ${depName}@agentsys`, { stdio: 'pipe' }); } catch {}
|
|
1069
|
+
}
|
|
1070
|
+
}
|
|
1071
|
+
}
|
|
1072
|
+
}
|
|
1073
|
+
// OpenCode and Codex get handled through normal install flow with cached plugins
|
|
1074
|
+
}
|
|
1075
|
+
|
|
1076
|
+
if (platforms.includes('opencode') && installDir) {
|
|
1077
|
+
installForOpenCode(installDir, { stripModels: args.stripModels, filter });
|
|
1078
|
+
}
|
|
1079
|
+
if (platforms.includes('codex') && installDir) {
|
|
1080
|
+
installForCodex(installDir, { filter });
|
|
1081
|
+
}
|
|
1082
|
+
if (platforms.includes('cursor') && installDir) {
|
|
1083
|
+
installForCursor(installDir, { filter });
|
|
1084
|
+
}
|
|
1085
|
+
|
|
1086
|
+
// Record in installed.json
|
|
1087
|
+
for (const depName of toFetch) {
|
|
1088
|
+
const dep = pluginMap[depName];
|
|
1089
|
+
const ver = depName === name && requestedVersion ? requestedVersion : (dep ? dep.version : 'unknown');
|
|
1090
|
+
if (depName === name && filter) {
|
|
1091
|
+
recordInstall(depName, ver, platforms, {
|
|
1092
|
+
scope: 'partial',
|
|
1093
|
+
agents: filter.agents,
|
|
1094
|
+
skills: filter.skills,
|
|
1095
|
+
commands: filter.commands
|
|
1096
|
+
});
|
|
1097
|
+
} else {
|
|
1098
|
+
recordInstall(depName, ver, platforms);
|
|
1099
|
+
}
|
|
1100
|
+
}
|
|
1101
|
+
|
|
1102
|
+
console.log(`\n[OK] Installed ${name} successfully.`);
|
|
1103
|
+
}
|
|
1104
|
+
|
|
1105
|
+
// --- remove subcommand ---
|
|
1106
|
+
|
|
1107
|
+
function removePlugin(name) {
|
|
1108
|
+
const installed = loadInstalledJson();
|
|
1109
|
+
|
|
1110
|
+
if (!installed.plugins[name]) {
|
|
1111
|
+
console.error(`[ERROR] Plugin ${name} is not installed.`);
|
|
1112
|
+
process.exit(1);
|
|
1113
|
+
}
|
|
1114
|
+
|
|
1115
|
+
const platforms = installed.plugins[name].platforms || [];
|
|
1116
|
+
|
|
1117
|
+
// Remove from cache
|
|
1118
|
+
const cacheDir = getPluginCacheDir();
|
|
1119
|
+
const pluginCacheDir = path.join(cacheDir, name);
|
|
1120
|
+
if (fs.existsSync(pluginCacheDir)) {
|
|
1121
|
+
fs.rmSync(pluginCacheDir, { recursive: true, force: true });
|
|
1122
|
+
console.log(` Removed from cache: ${name}`);
|
|
1123
|
+
}
|
|
1124
|
+
|
|
1125
|
+
// Remove from platforms
|
|
1126
|
+
if (platforms.includes('claude') && commandExists('claude')) {
|
|
1127
|
+
try {
|
|
1128
|
+
execSync(`claude plugin uninstall ${name}@agentsys`, { stdio: 'pipe' });
|
|
1129
|
+
console.log(` Removed from Claude Code: ${name}`);
|
|
1130
|
+
} catch {}
|
|
1131
|
+
}
|
|
1132
|
+
|
|
1133
|
+
if (platforms.includes('opencode')) {
|
|
1134
|
+
const opencodeDir = getOpenCodeConfigDir();
|
|
1135
|
+
console.log(` [NOTE] OpenCode files may need manual cleanup in ${opencodeDir}`);
|
|
1136
|
+
}
|
|
1137
|
+
|
|
1138
|
+
if (platforms.includes('codex')) {
|
|
1139
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
1140
|
+
const skillsDir = path.join(home, '.codex', 'skills');
|
|
1141
|
+
console.log(` [NOTE] Codex skill files may need manual cleanup in ${skillsDir}`);
|
|
1142
|
+
}
|
|
1143
|
+
|
|
1144
|
+
// Update installed.json
|
|
1145
|
+
recordRemove(name);
|
|
1146
|
+
console.log(`\n[OK] Removed ${name}.`);
|
|
1147
|
+
}
|
|
1148
|
+
|
|
1149
|
+
// --- search subcommand ---
|
|
1150
|
+
|
|
1151
|
+
function searchPlugins(term) {
|
|
1152
|
+
const marketplace = loadMarketplace();
|
|
1153
|
+
|
|
1154
|
+
// Handle "plugin:" prefix to list components of a specific plugin
|
|
1155
|
+
if (term && term.endsWith(':')) {
|
|
1156
|
+
const pluginName = term.slice(0, -1);
|
|
1157
|
+
const cacheDir = getPluginCacheDir();
|
|
1158
|
+
const pluginDir = path.join(cacheDir, pluginName);
|
|
1159
|
+
if (!fs.existsSync(pluginDir)) {
|
|
1160
|
+
console.log(`Plugin "${pluginName}" is not cached. Install it first: agentsys install ${pluginName}`);
|
|
1161
|
+
return;
|
|
1162
|
+
}
|
|
1163
|
+
const components = loadComponents(pluginDir);
|
|
1164
|
+
console.log(`\nComponents of ${pluginName}:\n`);
|
|
1165
|
+
if (components.agents.length > 0) {
|
|
1166
|
+
console.log(' Agents:');
|
|
1167
|
+
for (const a of components.agents) {
|
|
1168
|
+
const desc = a.description ? ` - ${a.description}` : '';
|
|
1169
|
+
console.log(` ${a.name}${desc}`);
|
|
1170
|
+
}
|
|
1171
|
+
}
|
|
1172
|
+
if (components.skills.length > 0) {
|
|
1173
|
+
console.log(' Skills:');
|
|
1174
|
+
for (const s of components.skills) {
|
|
1175
|
+
const desc = s.description ? ` - ${s.description}` : '';
|
|
1176
|
+
console.log(` ${s.name}${desc}`);
|
|
1177
|
+
}
|
|
1178
|
+
}
|
|
1179
|
+
if (components.commands.length > 0) {
|
|
1180
|
+
console.log(' Commands:');
|
|
1181
|
+
for (const c of components.commands) {
|
|
1182
|
+
const desc = c.description ? ` - ${c.description}` : '';
|
|
1183
|
+
console.log(` ${c.name}${desc}`);
|
|
1184
|
+
}
|
|
1185
|
+
}
|
|
1186
|
+
const total = components.agents.length + components.skills.length + components.commands.length;
|
|
1187
|
+
console.log(`\n${total} component(s) found.`);
|
|
1188
|
+
return;
|
|
1189
|
+
}
|
|
1190
|
+
|
|
1191
|
+
let plugins = marketplace.plugins;
|
|
1192
|
+
|
|
1193
|
+
if (term) {
|
|
1194
|
+
const lower = term.toLowerCase();
|
|
1195
|
+
plugins = plugins.filter(p =>
|
|
1196
|
+
p.name.toLowerCase().includes(lower) ||
|
|
1197
|
+
(p.description && p.description.toLowerCase().includes(lower))
|
|
1198
|
+
);
|
|
1199
|
+
}
|
|
1200
|
+
|
|
1201
|
+
if (plugins.length === 0) {
|
|
1202
|
+
console.log(`No plugins found${term ? ` matching "${term}"` : ''}.`);
|
|
1203
|
+
return;
|
|
1204
|
+
}
|
|
1205
|
+
|
|
1206
|
+
// Print table
|
|
1207
|
+
const nameWidth = Math.max(14, ...plugins.map(p => p.name.length)) + 2;
|
|
1208
|
+
const verWidth = 10;
|
|
1209
|
+
console.log(`\n${'NAME'.padEnd(nameWidth)}${'VERSION'.padEnd(verWidth)}DESCRIPTION`);
|
|
1210
|
+
console.log(`${'─'.repeat(nameWidth)}${'─'.repeat(verWidth)}${'─'.repeat(40)}`);
|
|
1211
|
+
for (const p of plugins) {
|
|
1212
|
+
const desc = p.description ? (p.description.length > 60 ? p.description.slice(0, 57) + '...' : p.description) : '';
|
|
1213
|
+
console.log(`${p.name.padEnd(nameWidth)}${(p.version || '').padEnd(verWidth)}${desc}`);
|
|
1214
|
+
}
|
|
1215
|
+
console.log(`\n${plugins.length} plugin(s) found.`);
|
|
1216
|
+
}
|
|
1217
|
+
|
|
194
1218
|
function installForClaude() {
|
|
195
1219
|
console.log('\n[INSTALL] Installing for Claude Code...\n');
|
|
196
1220
|
|
|
@@ -198,7 +1222,7 @@ function installForClaude() {
|
|
|
198
1222
|
console.log('[WARN] Claude Code CLI not detected.');
|
|
199
1223
|
console.log(' Install it first: https://claude.ai/code\n');
|
|
200
1224
|
console.log(' Then run in Claude Code:');
|
|
201
|
-
console.log(' /plugin marketplace add
|
|
1225
|
+
console.log(' /plugin marketplace add agent-sh/agentsys');
|
|
202
1226
|
console.log(' /plugin install next-task@agentsys\n');
|
|
203
1227
|
return false;
|
|
204
1228
|
}
|
|
@@ -207,7 +1231,7 @@ function installForClaude() {
|
|
|
207
1231
|
// Add GitHub marketplace
|
|
208
1232
|
console.log('Adding marketplace...');
|
|
209
1233
|
try {
|
|
210
|
-
execSync('claude plugin marketplace add
|
|
1234
|
+
execSync('claude plugin marketplace add agent-sh/agentsys', { stdio: 'pipe' });
|
|
211
1235
|
} catch {
|
|
212
1236
|
// May already exist
|
|
213
1237
|
}
|
|
@@ -249,7 +1273,7 @@ function installForClaude() {
|
|
|
249
1273
|
return true;
|
|
250
1274
|
} catch (err) {
|
|
251
1275
|
console.log('[ERROR] Auto-install failed. Manual installation:');
|
|
252
|
-
console.log(' /plugin marketplace add
|
|
1276
|
+
console.log(' /plugin marketplace add agent-sh/agentsys');
|
|
253
1277
|
console.log(' /plugin install next-task@agentsys');
|
|
254
1278
|
return false;
|
|
255
1279
|
}
|
|
@@ -270,7 +1294,7 @@ function installForClaudeDevelopment() {
|
|
|
270
1294
|
// Remove marketplace plugins first
|
|
271
1295
|
console.log('Removing marketplace plugins...');
|
|
272
1296
|
try {
|
|
273
|
-
execSync('claude plugin marketplace remove
|
|
1297
|
+
execSync('claude plugin marketplace remove agent-sh/agentsys', { stdio: 'pipe' });
|
|
274
1298
|
console.log(' [OK] Removed marketplace');
|
|
275
1299
|
} catch {
|
|
276
1300
|
// May not exist
|
|
@@ -328,7 +1352,7 @@ function installForClaudeDevelopment() {
|
|
|
328
1352
|
|
|
329
1353
|
function installForOpenCode(installDir, options = {}) {
|
|
330
1354
|
console.log('\n[INSTALL] Installing for OpenCode...\n');
|
|
331
|
-
const { stripModels = true } = options;
|
|
1355
|
+
const { stripModels = true, filter = null } = options;
|
|
332
1356
|
|
|
333
1357
|
if (stripModels) {
|
|
334
1358
|
console.log(' [INFO] Model specifications stripped (default). Use --no-strip to include.');
|
|
@@ -389,6 +1413,11 @@ function installForOpenCode(installDir, options = {}) {
|
|
|
389
1413
|
|
|
390
1414
|
// Transform and copy command files
|
|
391
1415
|
for (const [target, plugin, source] of commandMappings) {
|
|
1416
|
+
// Apply filter: skip commands not in the filter list
|
|
1417
|
+
if (filter && filter.commands.length > 0) {
|
|
1418
|
+
const cmdName = target.replace(/\.md$/, '');
|
|
1419
|
+
if (!filter.commands.includes(cmdName)) continue;
|
|
1420
|
+
}
|
|
392
1421
|
const srcPath = path.join(installDir, 'plugins', plugin, 'commands', source);
|
|
393
1422
|
const destPath = path.join(commandsDir, target);
|
|
394
1423
|
if (fs.existsSync(srcPath)) {
|
|
@@ -420,6 +1449,11 @@ function installForOpenCode(installDir, options = {}) {
|
|
|
420
1449
|
if (fs.existsSync(srcAgentsDir)) {
|
|
421
1450
|
const agentFiles = fs.readdirSync(srcAgentsDir).filter(f => f.endsWith('.md'));
|
|
422
1451
|
for (const agentFile of agentFiles) {
|
|
1452
|
+
// Apply filter: skip agents not in the filter list
|
|
1453
|
+
if (filter && filter.agents.length > 0) {
|
|
1454
|
+
const agentName = agentFile.replace(/\.md$/, '');
|
|
1455
|
+
if (!filter.agents.includes(agentName)) continue;
|
|
1456
|
+
}
|
|
423
1457
|
const srcPath = path.join(srcAgentsDir, agentFile);
|
|
424
1458
|
const destPath = path.join(agentsDir, agentFile);
|
|
425
1459
|
let content = fs.readFileSync(srcPath, 'utf8');
|
|
@@ -457,6 +1491,10 @@ function installForOpenCode(installDir, options = {}) {
|
|
|
457
1491
|
.filter(d => d.isDirectory());
|
|
458
1492
|
for (const skillDir of skillDirs) {
|
|
459
1493
|
const skillName = skillDir.name;
|
|
1494
|
+
// Apply filter: skip skills not in the filter list
|
|
1495
|
+
if (filter && filter.skills.length > 0) {
|
|
1496
|
+
if (!filter.skills.includes(skillName)) continue;
|
|
1497
|
+
}
|
|
460
1498
|
const srcSkillPath = path.join(srcSkillsDir, skillName, 'SKILL.md');
|
|
461
1499
|
if (fs.existsSync(srcSkillPath)) {
|
|
462
1500
|
const destSkillDir = path.join(skillsDestDir, skillName);
|
|
@@ -480,8 +1518,9 @@ function installForOpenCode(installDir, options = {}) {
|
|
|
480
1518
|
return true;
|
|
481
1519
|
}
|
|
482
1520
|
|
|
483
|
-
function installForCodex(installDir) {
|
|
1521
|
+
function installForCodex(installDir, options = {}) {
|
|
484
1522
|
console.log('\n[INSTALL] Installing for Codex CLI...\n');
|
|
1523
|
+
const { filter = null } = options;
|
|
485
1524
|
|
|
486
1525
|
const home = process.env.HOME || process.env.USERPROFILE;
|
|
487
1526
|
const configDir = path.join(home, '.codex');
|
|
@@ -519,6 +1558,10 @@ function installForCodex(installDir) {
|
|
|
519
1558
|
const skillMappings = discovery.getCodexSkillMappings(installDir);
|
|
520
1559
|
|
|
521
1560
|
for (const [skillName, plugin, sourceFile, description] of skillMappings) {
|
|
1561
|
+
// Apply filter: skip commands/skills not in the filter list
|
|
1562
|
+
if (filter && filter.commands.length > 0) {
|
|
1563
|
+
if (!filter.commands.includes(skillName)) continue;
|
|
1564
|
+
}
|
|
522
1565
|
if (!description) {
|
|
523
1566
|
console.log(` [WARN] Skipping skill ${skillName}: missing description`);
|
|
524
1567
|
continue;
|
|
@@ -555,6 +1598,101 @@ function installForCodex(installDir) {
|
|
|
555
1598
|
return true;
|
|
556
1599
|
}
|
|
557
1600
|
|
|
1601
|
+
function installForCursor(installDir, options = {}) {
|
|
1602
|
+
console.log('\n[INSTALL] Installing for Cursor...\n');
|
|
1603
|
+
const { filter = null } = options;
|
|
1604
|
+
const cwd = process.cwd();
|
|
1605
|
+
|
|
1606
|
+
// Create target directories (all project-scoped)
|
|
1607
|
+
const skillsDir = path.join(cwd, '.cursor', 'skills');
|
|
1608
|
+
const commandsDir = path.join(cwd, '.cursor', 'commands');
|
|
1609
|
+
const rulesDir = path.join(cwd, '.cursor', 'rules');
|
|
1610
|
+
fs.mkdirSync(skillsDir, { recursive: true });
|
|
1611
|
+
fs.mkdirSync(commandsDir, { recursive: true });
|
|
1612
|
+
fs.mkdirSync(rulesDir, { recursive: true });
|
|
1613
|
+
|
|
1614
|
+
// Cleanup old agentsys files from rules dir
|
|
1615
|
+
for (const f of fs.readdirSync(rulesDir).filter(f => f.startsWith('agentsys-') && f.endsWith('.mdc'))) {
|
|
1616
|
+
fs.unlinkSync(path.join(rulesDir, f));
|
|
1617
|
+
}
|
|
1618
|
+
|
|
1619
|
+
// Cleanup old agentsys files from commands dir (only those matching known commands)
|
|
1620
|
+
const commandMappingsForCleanup = discovery.getCommandMappings(installDir);
|
|
1621
|
+
const knownCommandFiles = new Set(commandMappingsForCleanup.map(([target]) => target));
|
|
1622
|
+
for (const f of fs.readdirSync(commandsDir).filter(f => f.endsWith('.md'))) {
|
|
1623
|
+
if (knownCommandFiles.has(f)) {
|
|
1624
|
+
fs.unlinkSync(path.join(commandsDir, f));
|
|
1625
|
+
}
|
|
1626
|
+
}
|
|
1627
|
+
|
|
1628
|
+
// Collect known skill names from discovery before cleanup
|
|
1629
|
+
const pluginDirs = discovery.discoverPlugins(installDir);
|
|
1630
|
+
const knownSkillNames = new Set();
|
|
1631
|
+
for (const pluginName of pluginDirs) {
|
|
1632
|
+
const srcSkillsDir = path.join(installDir, 'plugins', pluginName, 'skills');
|
|
1633
|
+
if (!fs.existsSync(srcSkillsDir)) continue;
|
|
1634
|
+
for (const d of fs.readdirSync(srcSkillsDir, { withFileTypes: true })) {
|
|
1635
|
+
if (d.isDirectory() && /^[a-zA-Z0-9_-]+$/.test(d.name)) knownSkillNames.add(d.name);
|
|
1636
|
+
}
|
|
1637
|
+
}
|
|
1638
|
+
|
|
1639
|
+
// Cleanup old agentsys skill dirs (only known names, preserve user-created skills)
|
|
1640
|
+
for (const entry of fs.readdirSync(skillsDir, { withFileTypes: true })) {
|
|
1641
|
+
if (entry.isDirectory() && knownSkillNames.has(entry.name)) {
|
|
1642
|
+
fs.rmSync(path.join(skillsDir, entry.name), { recursive: true, force: true });
|
|
1643
|
+
}
|
|
1644
|
+
}
|
|
1645
|
+
|
|
1646
|
+
// Install skills
|
|
1647
|
+
let skillCount = 0;
|
|
1648
|
+
for (const pluginName of pluginDirs) {
|
|
1649
|
+
const srcSkillsDir = path.join(installDir, 'plugins', pluginName, 'skills');
|
|
1650
|
+
if (!fs.existsSync(srcSkillsDir)) continue;
|
|
1651
|
+
const entries = fs.readdirSync(srcSkillsDir, { withFileTypes: true }).filter(d => d.isDirectory());
|
|
1652
|
+
for (const entry of entries) {
|
|
1653
|
+
if (!/^[a-zA-Z0-9_-]+$/.test(entry.name)) continue;
|
|
1654
|
+
if (filter && filter.skills && filter.skills.length > 0 && !filter.skills.includes(entry.name)) continue;
|
|
1655
|
+
const srcPath = path.join(srcSkillsDir, entry.name, 'SKILL.md');
|
|
1656
|
+
if (!fs.existsSync(srcPath)) continue;
|
|
1657
|
+
const destDir = path.join(skillsDir, entry.name);
|
|
1658
|
+
fs.mkdirSync(destDir, { recursive: true });
|
|
1659
|
+
let content = fs.readFileSync(srcPath, 'utf8');
|
|
1660
|
+
content = transforms.transformSkillForCursor(content, {
|
|
1661
|
+
pluginInstallPath: path.join(installDir, 'plugins', pluginName)
|
|
1662
|
+
});
|
|
1663
|
+
fs.writeFileSync(path.join(destDir, 'SKILL.md'), content);
|
|
1664
|
+
skillCount++;
|
|
1665
|
+
}
|
|
1666
|
+
}
|
|
1667
|
+
|
|
1668
|
+
// Install commands
|
|
1669
|
+
const commandMappings = discovery.getCommandMappings(installDir);
|
|
1670
|
+
let cmdCount = 0;
|
|
1671
|
+
for (const [target, plugin, source] of commandMappings) {
|
|
1672
|
+
if (filter && filter.commands && filter.commands.length > 0) {
|
|
1673
|
+
const cmdName = target.replace(/\.md$/, '');
|
|
1674
|
+
if (!filter.commands.includes(cmdName)) continue;
|
|
1675
|
+
}
|
|
1676
|
+
const srcPath = path.join(installDir, 'plugins', plugin, 'commands', source);
|
|
1677
|
+
if (!fs.existsSync(srcPath)) {
|
|
1678
|
+
console.log(` [WARN] Source file not found: ${srcPath}`);
|
|
1679
|
+
continue;
|
|
1680
|
+
}
|
|
1681
|
+
let content = fs.readFileSync(srcPath, 'utf8');
|
|
1682
|
+
content = transforms.transformCommandForCursor(content, {
|
|
1683
|
+
pluginInstallPath: path.join(installDir, 'plugins', plugin)
|
|
1684
|
+
});
|
|
1685
|
+
fs.writeFileSync(path.join(commandsDir, target), content);
|
|
1686
|
+
cmdCount++;
|
|
1687
|
+
}
|
|
1688
|
+
|
|
1689
|
+
console.log(`\n[OK] Cursor installation complete!`);
|
|
1690
|
+
console.log(` Skills: ${skillCount} installed to ${skillsDir}`);
|
|
1691
|
+
console.log(` Commands: ${cmdCount} installed to ${commandsDir}`);
|
|
1692
|
+
console.log(' All content is project-scoped and auto-loaded by Cursor.\n');
|
|
1693
|
+
return true;
|
|
1694
|
+
}
|
|
1695
|
+
|
|
558
1696
|
function removeInstallation() {
|
|
559
1697
|
const installDir = getInstallDir();
|
|
560
1698
|
|
|
@@ -571,6 +1709,113 @@ function removeInstallation() {
|
|
|
571
1709
|
console.log(' - Claude: /plugin marketplace remove agentsys');
|
|
572
1710
|
console.log(' - OpenCode: Remove files under ~/.config/opencode/ (commands/*.md, agents/*.md, skills/*/SKILL.md) and ~/.config/opencode/plugins/agentsys.ts');
|
|
573
1711
|
console.log(' - Codex: Remove ~/.codex/skills/*/');
|
|
1712
|
+
console.log(' - Cursor: Remove .cursor/skills/, .cursor/commands/, and .cursor/rules/agentsys-*.mdc from your project');
|
|
1713
|
+
}
|
|
1714
|
+
|
|
1715
|
+
function printSubcommandHelp(subcommand) {
|
|
1716
|
+
const helps = {
|
|
1717
|
+
install: `
|
|
1718
|
+
agentsys install — Install plugins and components
|
|
1719
|
+
|
|
1720
|
+
Usage:
|
|
1721
|
+
agentsys install <plugin> Install a full plugin (all agents, skills, commands)
|
|
1722
|
+
agentsys install <plugin>:<component> Install a single agent, skill, or command
|
|
1723
|
+
agentsys install <plugin>@<version> Install a specific version
|
|
1724
|
+
|
|
1725
|
+
Examples:
|
|
1726
|
+
agentsys install next-task Install next-task + dependencies (deslop, ship, sync-docs)
|
|
1727
|
+
agentsys install next-task:ci-fixer Install just the ci-fixer agent
|
|
1728
|
+
agentsys install deslop:deslop Install just the deslop skill
|
|
1729
|
+
agentsys install enhance:enhance-docs Install just the enhance-docs skill
|
|
1730
|
+
agentsys install perf@1.2.0 Install perf at version 1.2.0
|
|
1731
|
+
|
|
1732
|
+
Options:
|
|
1733
|
+
--tool <name> Install for a specific platform (claude, opencode, codex, cursor)
|
|
1734
|
+
--tools <list> Install for multiple platforms (comma-separated)
|
|
1735
|
+
|
|
1736
|
+
Notes:
|
|
1737
|
+
- Dependencies are resolved automatically (e.g., deslop requires next-task)
|
|
1738
|
+
- The full plugin is cached locally; granular install only affects what gets
|
|
1739
|
+
copied to platform directories (OpenCode, Codex)
|
|
1740
|
+
- Claude Code always installs whole plugins (platform limitation)
|
|
1741
|
+
- Use "agentsys search <plugin>:" to list available components
|
|
1742
|
+
`,
|
|
1743
|
+
list: `
|
|
1744
|
+
agentsys list — List installed plugins and components
|
|
1745
|
+
|
|
1746
|
+
Usage:
|
|
1747
|
+
agentsys list Plugin summary (name, version, scope, counts)
|
|
1748
|
+
agentsys list --all Show everything (plugins, agents, skills, commands, hooks)
|
|
1749
|
+
agentsys list --plugins Show plugins with version and scope
|
|
1750
|
+
agentsys list --agents Show all agents across all installed plugins
|
|
1751
|
+
agentsys list --skills Show all skills across all installed plugins
|
|
1752
|
+
agentsys list --commands Show all commands (slash commands)
|
|
1753
|
+
agentsys list --hooks Show all hooks
|
|
1754
|
+
|
|
1755
|
+
Output format:
|
|
1756
|
+
AGENTS
|
|
1757
|
+
plugin:agent-name model description
|
|
1758
|
+
SKILLS
|
|
1759
|
+
plugin:skill-name description
|
|
1760
|
+
COMMANDS
|
|
1761
|
+
/command-name description
|
|
1762
|
+
HOOKS
|
|
1763
|
+
plugin:event description
|
|
1764
|
+
|
|
1765
|
+
Scope tags:
|
|
1766
|
+
[full] All components of the plugin are installed
|
|
1767
|
+
[partial] Only selected components are installed
|
|
1768
|
+
`,
|
|
1769
|
+
search: `
|
|
1770
|
+
agentsys search — Search available plugins and components
|
|
1771
|
+
|
|
1772
|
+
Usage:
|
|
1773
|
+
agentsys search List all available plugins
|
|
1774
|
+
agentsys search <term> Filter plugins by name or description
|
|
1775
|
+
agentsys search <plugin>: List all components (agents, skills, commands) of a plugin
|
|
1776
|
+
|
|
1777
|
+
Examples:
|
|
1778
|
+
agentsys search Show all 13 plugins
|
|
1779
|
+
agentsys search perf Find plugins matching "perf"
|
|
1780
|
+
agentsys search next-task: Show next-task's 10 agents, 3 skills, 2 commands
|
|
1781
|
+
agentsys search :ci-fixer Search all plugins for "ci-fixer"
|
|
1782
|
+
|
|
1783
|
+
Output:
|
|
1784
|
+
NAME VERSION DESCRIPTION
|
|
1785
|
+
next-task 1.0.0 Master workflow orchestrator
|
|
1786
|
+
deslop 1.0.0 Clean AI slop from code
|
|
1787
|
+
`,
|
|
1788
|
+
remove: `
|
|
1789
|
+
agentsys remove — Remove an installed plugin
|
|
1790
|
+
|
|
1791
|
+
Usage:
|
|
1792
|
+
agentsys remove <plugin> Remove plugin from cache and platform directories
|
|
1793
|
+
|
|
1794
|
+
Notes:
|
|
1795
|
+
- Warns if another installed plugin depends on the one being removed
|
|
1796
|
+
- Claude Code: runs "claude plugin uninstall <plugin>@agentsys"
|
|
1797
|
+
- OpenCode/Codex: notes manual cleanup may be needed
|
|
1798
|
+
- Updates installed.json manifest
|
|
1799
|
+
`,
|
|
1800
|
+
update: `
|
|
1801
|
+
agentsys update — Update installed plugins to latest versions
|
|
1802
|
+
|
|
1803
|
+
Usage:
|
|
1804
|
+
agentsys update Re-fetch all installed plugins from GitHub
|
|
1805
|
+
|
|
1806
|
+
Notes:
|
|
1807
|
+
- Clears cached versions and re-downloads latest from each plugin's GitHub repo
|
|
1808
|
+
- Only updates plugins already in the cache (~/.agentsys/plugins/)
|
|
1809
|
+
- Does not change platform installations — run "agentsys" again to re-install
|
|
1810
|
+
`
|
|
1811
|
+
};
|
|
1812
|
+
|
|
1813
|
+
const text = helps[subcommand];
|
|
1814
|
+
if (text) {
|
|
1815
|
+
console.log(text);
|
|
1816
|
+
} else {
|
|
1817
|
+
console.log(`No help available for "${subcommand}". Run: agentsys --help`);
|
|
1818
|
+
}
|
|
574
1819
|
}
|
|
575
1820
|
|
|
576
1821
|
function printHelp() {
|
|
@@ -579,19 +1824,36 @@ agentsys v${VERSION} - Workflow automation for AI coding assistants
|
|
|
579
1824
|
|
|
580
1825
|
Usage:
|
|
581
1826
|
agentsys Interactive installer (select platforms)
|
|
582
|
-
agentsys --tool <name> Install for single tool (claude, opencode, codex)
|
|
1827
|
+
agentsys --tool <name> Install for single tool (claude, opencode, codex, cursor)
|
|
583
1828
|
agentsys --tools <list> Install for multiple tools (comma-separated)
|
|
1829
|
+
agentsys --only <plugins> Install only specified plugins (comma-separated, resolves deps)
|
|
584
1830
|
agentsys --development Development mode: install to ~/.claude/plugins
|
|
585
1831
|
agentsys --no-strip, -ns Include model specifications (stripped by default)
|
|
586
1832
|
agentsys --remove Remove local installation
|
|
587
1833
|
agentsys --version, -v Show version
|
|
588
1834
|
agentsys --help, -h Show this help
|
|
1835
|
+
agentsys install <plugin> Install a specific plugin (resolves deps)
|
|
1836
|
+
agentsys install <p>:<comp> Install a single agent, skill, or command
|
|
1837
|
+
agentsys install <p>@<ver> Install a specific version
|
|
1838
|
+
agentsys remove <plugin> Remove an installed plugin
|
|
1839
|
+
agentsys search [term] Search available plugins
|
|
1840
|
+
agentsys search <plugin>: List components of a plugin
|
|
1841
|
+
agentsys list List installed plugins (summary)
|
|
1842
|
+
agentsys list --all List everything (plugins, agents, skills, commands, hooks)
|
|
1843
|
+
agentsys list --plugins List plugins only
|
|
1844
|
+
agentsys list --agents List all agents across plugins
|
|
1845
|
+
agentsys list --skills List all skills across plugins
|
|
1846
|
+
agentsys list --commands List all commands across plugins
|
|
1847
|
+
agentsys list --hooks List all hooks across plugins
|
|
1848
|
+
agentsys update Re-fetch latest versions of installed plugins
|
|
589
1849
|
|
|
590
1850
|
Non-Interactive Examples:
|
|
591
1851
|
agentsys --tool claude # Install for Claude Code only
|
|
592
1852
|
agentsys --tool opencode # Install for OpenCode only
|
|
593
1853
|
agentsys --tools "claude,opencode" # Install for both
|
|
594
|
-
agentsys --tools claude,opencode,codex # Install for all
|
|
1854
|
+
agentsys --tools claude,opencode,codex,cursor # Install for all
|
|
1855
|
+
agentsys --only next-task # Install next-task + its dependencies
|
|
1856
|
+
agentsys --only "next-task,perf" # Install specific plugins + deps
|
|
595
1857
|
|
|
596
1858
|
Development Mode:
|
|
597
1859
|
agentsys --development # Install plugins directly to ~/.claude/plugins
|
|
@@ -609,12 +1871,13 @@ Supported Platforms:
|
|
|
609
1871
|
claude - Claude Code (marketplace install or development mode)
|
|
610
1872
|
opencode - OpenCode (local commands + native plugin)
|
|
611
1873
|
codex - Codex CLI (local skills)
|
|
1874
|
+
cursor - Cursor (project-scoped .mdc rules)
|
|
612
1875
|
|
|
613
1876
|
Install: npm install -g agentsys && agentsys
|
|
614
1877
|
Update: npm update -g agentsys && agentsys
|
|
615
1878
|
Remove: npm uninstall -g agentsys && agentsys --remove
|
|
616
1879
|
|
|
617
|
-
Docs: https://github.com/
|
|
1880
|
+
Docs: https://github.com/agent-sh/agentsys
|
|
618
1881
|
`);
|
|
619
1882
|
}
|
|
620
1883
|
|
|
@@ -639,6 +1902,46 @@ async function main() {
|
|
|
639
1902
|
return;
|
|
640
1903
|
}
|
|
641
1904
|
|
|
1905
|
+
// Handle subcommand help
|
|
1906
|
+
if (args.subcommandArg === '--help') {
|
|
1907
|
+
printSubcommandHelp(args.subcommand);
|
|
1908
|
+
return;
|
|
1909
|
+
}
|
|
1910
|
+
|
|
1911
|
+
// Handle subcommands
|
|
1912
|
+
if (args.subcommand === 'list') {
|
|
1913
|
+
listInstalledPlugins(args.subcommandArg);
|
|
1914
|
+
return;
|
|
1915
|
+
}
|
|
1916
|
+
|
|
1917
|
+
if (args.subcommand === 'update') {
|
|
1918
|
+
await updatePlugins();
|
|
1919
|
+
return;
|
|
1920
|
+
}
|
|
1921
|
+
|
|
1922
|
+
if (args.subcommand === 'search') {
|
|
1923
|
+
searchPlugins(args.subcommandArg);
|
|
1924
|
+
return;
|
|
1925
|
+
}
|
|
1926
|
+
|
|
1927
|
+
if (args.subcommand === 'install') {
|
|
1928
|
+
if (!args.subcommandArg) {
|
|
1929
|
+
console.error('[ERROR] Usage: agentsys install <plugin[@version]>');
|
|
1930
|
+
process.exit(1);
|
|
1931
|
+
}
|
|
1932
|
+
await installPlugin(args.subcommandArg, args);
|
|
1933
|
+
return;
|
|
1934
|
+
}
|
|
1935
|
+
|
|
1936
|
+
if (args.subcommand === 'remove') {
|
|
1937
|
+
if (!args.subcommandArg) {
|
|
1938
|
+
console.error('[ERROR] Usage: agentsys remove <plugin>');
|
|
1939
|
+
process.exit(1);
|
|
1940
|
+
}
|
|
1941
|
+
removePlugin(args.subcommandArg);
|
|
1942
|
+
return;
|
|
1943
|
+
}
|
|
1944
|
+
|
|
642
1945
|
// Determine which tools to install
|
|
643
1946
|
let selected = [];
|
|
644
1947
|
|
|
@@ -673,7 +1976,8 @@ async function main() {
|
|
|
673
1976
|
const options = [
|
|
674
1977
|
{ value: 'claude', label: 'Claude Code' },
|
|
675
1978
|
{ value: 'opencode', label: 'OpenCode' },
|
|
676
|
-
{ value: 'codex', label: 'Codex CLI' }
|
|
1979
|
+
{ value: 'codex', label: 'Codex CLI' },
|
|
1980
|
+
{ value: 'cursor', label: 'Cursor' }
|
|
677
1981
|
];
|
|
678
1982
|
|
|
679
1983
|
selected = await multiSelect(
|
|
@@ -684,15 +1988,26 @@ async function main() {
|
|
|
684
1988
|
if (selected.length === 0) {
|
|
685
1989
|
console.log('\nNo platforms selected. Exiting.');
|
|
686
1990
|
console.log('\nFor Claude Code, you can also install directly:');
|
|
687
|
-
console.log(' /plugin marketplace add
|
|
1991
|
+
console.log(' /plugin marketplace add agent-sh/agentsys');
|
|
688
1992
|
process.exit(0);
|
|
689
1993
|
}
|
|
690
1994
|
}
|
|
691
1995
|
|
|
692
1996
|
console.log(`\nInstalling for: ${selected.join(', ')}\n`);
|
|
693
1997
|
|
|
694
|
-
//
|
|
695
|
-
const
|
|
1998
|
+
// Fetch external plugins to cache
|
|
1999
|
+
const marketplace = loadMarketplace();
|
|
2000
|
+
const onlyPlugins = args.only;
|
|
2001
|
+
const pluginNames = onlyPlugins.length > 0 ? onlyPlugins : marketplace.plugins.map(p => p.name);
|
|
2002
|
+
|
|
2003
|
+
// Check core version compatibility
|
|
2004
|
+
for (const pName of pluginNames) {
|
|
2005
|
+
const entry = marketplace.plugins.find(p => p.name === pName);
|
|
2006
|
+
if (entry) checkCoreCompat(entry);
|
|
2007
|
+
}
|
|
2008
|
+
|
|
2009
|
+
// Only copy to ~/.agentsys if OpenCode, Codex, or Cursor selected (they need local files)
|
|
2010
|
+
const needsLocalInstall = selected.includes('opencode') || selected.includes('codex') || selected.includes('cursor');
|
|
696
2011
|
let installDir = null;
|
|
697
2012
|
|
|
698
2013
|
if (needsLocalInstall) {
|
|
@@ -702,6 +2017,8 @@ async function main() {
|
|
|
702
2017
|
installDependencies(installDir);
|
|
703
2018
|
}
|
|
704
2019
|
|
|
2020
|
+
await fetchExternalPlugins(pluginNames, marketplace);
|
|
2021
|
+
|
|
705
2022
|
// Install for each platform
|
|
706
2023
|
const failedPlatforms = [];
|
|
707
2024
|
for (const platform of selected) {
|
|
@@ -725,6 +2042,11 @@ async function main() {
|
|
|
725
2042
|
failedPlatforms.push('codex');
|
|
726
2043
|
}
|
|
727
2044
|
break;
|
|
2045
|
+
case 'cursor':
|
|
2046
|
+
if (!installForCursor(installDir)) {
|
|
2047
|
+
failedPlatforms.push('cursor');
|
|
2048
|
+
}
|
|
2049
|
+
break;
|
|
728
2050
|
}
|
|
729
2051
|
}
|
|
730
2052
|
|
|
@@ -739,7 +2061,7 @@ async function main() {
|
|
|
739
2061
|
}
|
|
740
2062
|
console.log('\nTo update: npm update -g agentsys');
|
|
741
2063
|
console.log('To remove: npm uninstall -g agentsys && agentsys --remove');
|
|
742
|
-
console.log('\nDocs: https://github.com/
|
|
2064
|
+
console.log('\nDocs: https://github.com/agent-sh/agentsys');
|
|
743
2065
|
}
|
|
744
2066
|
|
|
745
2067
|
// Export for testing when required as module
|
|
@@ -750,4 +2072,33 @@ if (require.main === module) {
|
|
|
750
2072
|
});
|
|
751
2073
|
}
|
|
752
2074
|
|
|
753
|
-
module.exports = {
|
|
2075
|
+
module.exports = {
|
|
2076
|
+
parseArgs,
|
|
2077
|
+
VALID_TOOLS,
|
|
2078
|
+
resolvePluginDeps,
|
|
2079
|
+
fetchPlugin,
|
|
2080
|
+
fetchExternalPlugins,
|
|
2081
|
+
resolvePluginRoot,
|
|
2082
|
+
loadMarketplace,
|
|
2083
|
+
getPluginCacheDir,
|
|
2084
|
+
listInstalledPlugins,
|
|
2085
|
+
updatePlugins,
|
|
2086
|
+
installPlugin,
|
|
2087
|
+
removePlugin,
|
|
2088
|
+
searchPlugins,
|
|
2089
|
+
loadInstalledJson,
|
|
2090
|
+
saveInstalledJson,
|
|
2091
|
+
recordInstall,
|
|
2092
|
+
recordRemove,
|
|
2093
|
+
satisfiesRange,
|
|
2094
|
+
checkCoreCompat,
|
|
2095
|
+
detectInstalledPlatforms,
|
|
2096
|
+
getInstalledJsonPath,
|
|
2097
|
+
parseInstallTarget,
|
|
2098
|
+
loadComponents,
|
|
2099
|
+
resolveComponent,
|
|
2100
|
+
buildFilterFromComponent,
|
|
2101
|
+
resolvePluginSource,
|
|
2102
|
+
parseGitHubSource,
|
|
2103
|
+
installForCursor
|
|
2104
|
+
};
|