agentsys 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agnix.toml +49 -0
- package/.claude-plugin/marketplace.json +110 -0
- package/.claude-plugin/plugin.json +20 -0
- package/AGENTS.md +260 -0
- package/CHANGELOG.md +190 -0
- package/LICENSE +21 -0
- package/README.md +916 -0
- package/SECURITY.md +45 -0
- package/adapters/README.md +258 -0
- package/adapters/codex/README.md +273 -0
- package/adapters/codex/install.sh +260 -0
- package/adapters/codex/skills/agnix/SKILL.md +138 -0
- package/adapters/codex/skills/audit-project/SKILL.md +334 -0
- package/adapters/codex/skills/audit-project-agents/SKILL.md +459 -0
- package/adapters/codex/skills/audit-project-github/SKILL.md +146 -0
- package/adapters/codex/skills/consult/SKILL.md +245 -0
- package/adapters/codex/skills/delivery-approval/SKILL.md +339 -0
- package/adapters/codex/skills/deslop/SKILL.md +167 -0
- package/adapters/codex/skills/drift-detect/SKILL.md +268 -0
- package/adapters/codex/skills/enhance/SKILL.md +177 -0
- package/adapters/codex/skills/learn/SKILL.md +188 -0
- package/adapters/codex/skills/next-task/SKILL.md +546 -0
- package/adapters/codex/skills/perf/SKILL.md +469 -0
- package/adapters/codex/skills/repo-map/SKILL.md +132 -0
- package/adapters/codex/skills/ship/SKILL.md +491 -0
- package/adapters/codex/skills/ship-ci-review-loop/SKILL.md +473 -0
- package/adapters/codex/skills/ship-deployment/SKILL.md +336 -0
- package/adapters/codex/skills/ship-error-handling/SKILL.md +260 -0
- package/adapters/codex/skills/sync-docs/SKILL.md +186 -0
- package/adapters/opencode/README.md +302 -0
- package/adapters/opencode/agents/agent-enhancer.md +65 -0
- package/adapters/opencode/agents/agnix-agent.md +56 -0
- package/adapters/opencode/agents/ci-fixer.md +104 -0
- package/adapters/opencode/agents/ci-monitor.md +127 -0
- package/adapters/opencode/agents/claudemd-enhancer.md +66 -0
- package/adapters/opencode/agents/consult-agent.md +124 -0
- package/adapters/opencode/agents/cross-file-enhancer.md +54 -0
- package/adapters/opencode/agents/delivery-validator.md +115 -0
- package/adapters/opencode/agents/deslop-agent.md +88 -0
- package/adapters/opencode/agents/docs-enhancer.md +65 -0
- package/adapters/opencode/agents/exploration-agent.md +143 -0
- package/adapters/opencode/agents/hooks-enhancer.md +66 -0
- package/adapters/opencode/agents/implementation-agent.md +206 -0
- package/adapters/opencode/agents/learn-agent.md +279 -0
- package/adapters/opencode/agents/map-validator.md +65 -0
- package/adapters/opencode/agents/perf-analyzer.md +40 -0
- package/adapters/opencode/agents/perf-code-paths.md +12 -0
- package/adapters/opencode/agents/perf-investigation-logger.md +44 -0
- package/adapters/opencode/agents/perf-orchestrator.md +147 -0
- package/adapters/opencode/agents/perf-theory-gatherer.md +18 -0
- package/adapters/opencode/agents/perf-theory-tester.md +43 -0
- package/adapters/opencode/agents/plan-synthesizer.md +229 -0
- package/adapters/opencode/agents/planning-agent.md +235 -0
- package/adapters/opencode/agents/plugin-enhancer.md +64 -0
- package/adapters/opencode/agents/prompt-enhancer.md +58 -0
- package/adapters/opencode/agents/simple-fixer.md +107 -0
- package/adapters/opencode/agents/skills-enhancer.md +66 -0
- package/adapters/opencode/agents/sync-docs-agent.md +153 -0
- package/adapters/opencode/agents/task-discoverer.md +80 -0
- package/adapters/opencode/agents/test-coverage-checker.md +144 -0
- package/adapters/opencode/agents/worktree-manager.md +209 -0
- package/adapters/opencode/commands/agnix.md +106 -0
- package/adapters/opencode/commands/audit-project-agents.md +125 -0
- package/adapters/opencode/commands/audit-project-github.md +145 -0
- package/adapters/opencode/commands/audit-project.md +268 -0
- package/adapters/opencode/commands/consult.md +252 -0
- package/adapters/opencode/commands/delivery-approval.md +212 -0
- package/adapters/opencode/commands/deslop.md +132 -0
- package/adapters/opencode/commands/drift-detect.md +173 -0
- package/adapters/opencode/commands/enhance.md +183 -0
- package/adapters/opencode/commands/learn.md +116 -0
- package/adapters/opencode/commands/next-task.md +393 -0
- package/adapters/opencode/commands/perf.md +49 -0
- package/adapters/opencode/commands/repo-map.md +69 -0
- package/adapters/opencode/commands/ship-ci-review-loop.md +334 -0
- package/adapters/opencode/commands/ship-deployment.md +336 -0
- package/adapters/opencode/commands/ship-error-handling.md +248 -0
- package/adapters/opencode/commands/ship.md +371 -0
- package/adapters/opencode/commands/sync-docs.md +108 -0
- package/adapters/opencode/install.sh +322 -0
- package/adapters/opencode/skills/agnix/SKILL.md +139 -0
- package/adapters/opencode/skills/consult/SKILL.md +292 -0
- package/adapters/opencode/skills/deslop/SKILL.md +169 -0
- package/adapters/opencode/skills/discover-tasks/SKILL.md +102 -0
- package/adapters/opencode/skills/drift-analysis/SKILL.md +279 -0
- package/adapters/opencode/skills/enhance-agent-prompts/SKILL.md +279 -0
- package/adapters/opencode/skills/enhance-claude-memory/SKILL.md +390 -0
- package/adapters/opencode/skills/enhance-cross-file/SKILL.md +112 -0
- package/adapters/opencode/skills/enhance-docs/SKILL.md +288 -0
- package/adapters/opencode/skills/enhance-hooks/SKILL.md +557 -0
- package/adapters/opencode/skills/enhance-orchestrator/SKILL.md +114 -0
- package/adapters/opencode/skills/enhance-plugins/SKILL.md +314 -0
- package/adapters/opencode/skills/enhance-prompts/SKILL.md +341 -0
- package/adapters/opencode/skills/enhance-skills/SKILL.md +443 -0
- package/adapters/opencode/skills/learn/SKILL.md +352 -0
- package/adapters/opencode/skills/orchestrate-review/SKILL.md +95 -0
- package/adapters/opencode/skills/perf-analyzer/SKILL.md +38 -0
- package/adapters/opencode/skills/perf-baseline-manager/SKILL.md +31 -0
- package/adapters/opencode/skills/perf-benchmarker/SKILL.md +49 -0
- package/adapters/opencode/skills/perf-code-paths/SKILL.md +33 -0
- package/adapters/opencode/skills/perf-investigation-logger/SKILL.md +42 -0
- package/adapters/opencode/skills/perf-profiler/SKILL.md +39 -0
- package/adapters/opencode/skills/perf-theory-gatherer/SKILL.md +36 -0
- package/adapters/opencode/skills/perf-theory-tester/SKILL.md +37 -0
- package/adapters/opencode/skills/repo-mapping/SKILL.md +86 -0
- package/adapters/opencode/skills/sync-docs/SKILL.md +246 -0
- package/adapters/opencode/skills/validate-delivery/SKILL.md +112 -0
- package/adapters/opencode-plugin/index.ts +346 -0
- package/adapters/opencode-plugin/package.json +21 -0
- package/agent-knowledge/AGENTS.md +62 -0
- package/agent-knowledge/ai-cli-advanced-integration-patterns.md +670 -0
- package/agent-knowledge/ai-cli-non-interactive-programmatic-usage.md +1394 -0
- package/agent-knowledge/resources/ai-cli-non-interactive-programmatic-usage-sources.json +500 -0
- package/bin/cli.js +719 -0
- package/bin/dev-cli.js +587 -0
- package/lib/adapter-transforms.js +278 -0
- package/lib/collectors/codebase.js +392 -0
- package/lib/collectors/docs-patterns.js +713 -0
- package/lib/collectors/documentation.js +219 -0
- package/lib/collectors/github.js +266 -0
- package/lib/collectors/index.js +126 -0
- package/lib/config/index.js +14 -0
- package/lib/cross-platform/index.js +539 -0
- package/lib/discovery/index.js +352 -0
- package/lib/drift-detect/collectors.js +37 -0
- package/lib/enhance/agent-analyzer.js +421 -0
- package/lib/enhance/agent-patterns.js +571 -0
- package/lib/enhance/auto-suppression.js +622 -0
- package/lib/enhance/benchmark.js +417 -0
- package/lib/enhance/cross-file-analyzer.js +930 -0
- package/lib/enhance/cross-file-patterns.js +370 -0
- package/lib/enhance/docs-analyzer.js +325 -0
- package/lib/enhance/docs-patterns.js +671 -0
- package/lib/enhance/fixer.js +721 -0
- package/lib/enhance/hook-analyzer.js +135 -0
- package/lib/enhance/hook-patterns.js +40 -0
- package/lib/enhance/index.js +127 -0
- package/lib/enhance/plugin-analyzer.js +402 -0
- package/lib/enhance/plugin-patterns.js +326 -0
- package/lib/enhance/projectmemory-analyzer.js +551 -0
- package/lib/enhance/projectmemory-patterns.js +617 -0
- package/lib/enhance/prompt-analyzer.js +457 -0
- package/lib/enhance/prompt-patterns.js +1484 -0
- package/lib/enhance/reporter.js +1348 -0
- package/lib/enhance/security-patterns.js +284 -0
- package/lib/enhance/skill-analyzer.js +182 -0
- package/lib/enhance/skill-patterns.js +147 -0
- package/lib/enhance/suppression.js +352 -0
- package/lib/enhance/tool-patterns.js +373 -0
- package/lib/index.js +270 -0
- package/lib/package.json +25 -0
- package/lib/patterns/cli-enhancers.js +611 -0
- package/lib/patterns/pipeline.js +948 -0
- package/lib/patterns/review-patterns.js +558 -0
- package/lib/patterns/slop-analyzers.js +2305 -0
- package/lib/patterns/slop-patterns.js +1187 -0
- package/lib/perf/analyzer/index.js +22 -0
- package/lib/perf/argument-parser.js +105 -0
- package/lib/perf/baseline-comparator.js +50 -0
- package/lib/perf/baseline-store.js +127 -0
- package/lib/perf/benchmark-runner.js +399 -0
- package/lib/perf/breaking-point-finder.js +52 -0
- package/lib/perf/breaking-point-runner.js +60 -0
- package/lib/perf/checkpoint.js +123 -0
- package/lib/perf/code-paths.js +86 -0
- package/lib/perf/consolidation.js +37 -0
- package/lib/perf/constraint-runner.js +71 -0
- package/lib/perf/experiment-runner.js +32 -0
- package/lib/perf/index.js +41 -0
- package/lib/perf/investigation-state.js +875 -0
- package/lib/perf/optimization-runner.js +79 -0
- package/lib/perf/profilers/go.js +22 -0
- package/lib/perf/profilers/index.js +46 -0
- package/lib/perf/profilers/java.js +23 -0
- package/lib/perf/profilers/node.js +27 -0
- package/lib/perf/profilers/python.js +23 -0
- package/lib/perf/profilers/rust.js +23 -0
- package/lib/perf/profiling-runner.js +56 -0
- package/lib/perf/schemas.js +140 -0
- package/lib/platform/detect-platform.js +413 -0
- package/lib/platform/detection-configs.js +93 -0
- package/lib/platform/state-dir.js +132 -0
- package/lib/platform/verify-tools.js +182 -0
- package/lib/repo-map/cache.js +152 -0
- package/lib/repo-map/index.js +222 -0
- package/lib/repo-map/installer.js +212 -0
- package/lib/repo-map/queries/go.js +27 -0
- package/lib/repo-map/queries/index.js +100 -0
- package/lib/repo-map/queries/java.js +38 -0
- package/lib/repo-map/queries/javascript.js +55 -0
- package/lib/repo-map/queries/python.js +24 -0
- package/lib/repo-map/queries/rust.js +73 -0
- package/lib/repo-map/queries/typescript.js +38 -0
- package/lib/repo-map/runner.js +1165 -0
- package/lib/repo-map/updater.js +474 -0
- package/lib/repo-map/usage-analyzer.js +407 -0
- package/lib/schemas/plugin-manifest.schema.json +57 -0
- package/lib/schemas/validator.js +247 -0
- package/lib/sources/custom-handler.js +199 -0
- package/lib/sources/policy-questions.js +246 -0
- package/lib/sources/source-cache.js +165 -0
- package/lib/state/workflow-state.js +575 -0
- package/lib/types/agent-frontmatter.d.ts +134 -0
- package/lib/types/command-frontmatter.d.ts +107 -0
- package/lib/types/hook-frontmatter.d.ts +115 -0
- package/lib/types/index.d.ts +84 -0
- package/lib/types/plugin-manifest.d.ts +102 -0
- package/lib/types/skill-frontmatter.d.ts +89 -0
- package/lib/utils/atomic-write.js +94 -0
- package/lib/utils/cache-manager.js +159 -0
- package/lib/utils/context-optimizer.js +300 -0
- package/lib/utils/deprecation.js +37 -0
- package/lib/utils/shell-escape.js +88 -0
- package/meta/skills/maintain-cross-platform/SKILL.md +1022 -0
- package/package.json +92 -0
- package/plugins/agnix/.claude-plugin/plugin.json +22 -0
- package/plugins/agnix/agents/agnix-agent.md +56 -0
- package/plugins/agnix/commands/agnix.md +139 -0
- package/plugins/agnix/skills/agnix/SKILL.md +138 -0
- package/plugins/audit-project/.claude-plugin/plugin.json +20 -0
- package/plugins/audit-project/commands/audit-project-agents.md +458 -0
- package/plugins/audit-project/commands/audit-project-github.md +144 -0
- package/plugins/audit-project/commands/audit-project.md +336 -0
- package/plugins/audit-project/lib/adapter-transforms.js +278 -0
- package/plugins/audit-project/lib/collectors/codebase.js +392 -0
- package/plugins/audit-project/lib/collectors/docs-patterns.js +713 -0
- package/plugins/audit-project/lib/collectors/documentation.js +219 -0
- package/plugins/audit-project/lib/collectors/github.js +266 -0
- package/plugins/audit-project/lib/collectors/index.js +126 -0
- package/plugins/audit-project/lib/config/index.js +14 -0
- package/plugins/audit-project/lib/cross-platform/index.js +539 -0
- package/plugins/audit-project/lib/discovery/index.js +352 -0
- package/plugins/audit-project/lib/drift-detect/collectors.js +37 -0
- package/plugins/audit-project/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/audit-project/lib/enhance/agent-patterns.js +571 -0
- package/plugins/audit-project/lib/enhance/auto-suppression.js +622 -0
- package/plugins/audit-project/lib/enhance/benchmark.js +417 -0
- package/plugins/audit-project/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/audit-project/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/audit-project/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/audit-project/lib/enhance/docs-patterns.js +671 -0
- package/plugins/audit-project/lib/enhance/fixer.js +721 -0
- package/plugins/audit-project/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/audit-project/lib/enhance/hook-patterns.js +40 -0
- package/plugins/audit-project/lib/enhance/index.js +127 -0
- package/plugins/audit-project/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/audit-project/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/audit-project/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/audit-project/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/audit-project/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/audit-project/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/audit-project/lib/enhance/reporter.js +1348 -0
- package/plugins/audit-project/lib/enhance/security-patterns.js +284 -0
- package/plugins/audit-project/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/audit-project/lib/enhance/skill-patterns.js +147 -0
- package/plugins/audit-project/lib/enhance/suppression.js +352 -0
- package/plugins/audit-project/lib/enhance/tool-patterns.js +373 -0
- package/plugins/audit-project/lib/index.js +270 -0
- package/plugins/audit-project/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/audit-project/lib/patterns/pipeline.js +948 -0
- package/plugins/audit-project/lib/patterns/review-patterns.js +558 -0
- package/plugins/audit-project/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/audit-project/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/audit-project/lib/perf/analyzer/index.js +22 -0
- package/plugins/audit-project/lib/perf/argument-parser.js +105 -0
- package/plugins/audit-project/lib/perf/baseline-comparator.js +50 -0
- package/plugins/audit-project/lib/perf/baseline-store.js +127 -0
- package/plugins/audit-project/lib/perf/benchmark-runner.js +399 -0
- package/plugins/audit-project/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/audit-project/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/audit-project/lib/perf/checkpoint.js +123 -0
- package/plugins/audit-project/lib/perf/code-paths.js +86 -0
- package/plugins/audit-project/lib/perf/consolidation.js +37 -0
- package/plugins/audit-project/lib/perf/constraint-runner.js +71 -0
- package/plugins/audit-project/lib/perf/experiment-runner.js +32 -0
- package/plugins/audit-project/lib/perf/index.js +41 -0
- package/plugins/audit-project/lib/perf/investigation-state.js +875 -0
- package/plugins/audit-project/lib/perf/optimization-runner.js +79 -0
- package/plugins/audit-project/lib/perf/profilers/go.js +22 -0
- package/plugins/audit-project/lib/perf/profilers/index.js +46 -0
- package/plugins/audit-project/lib/perf/profilers/java.js +23 -0
- package/plugins/audit-project/lib/perf/profilers/node.js +27 -0
- package/plugins/audit-project/lib/perf/profilers/python.js +23 -0
- package/plugins/audit-project/lib/perf/profilers/rust.js +23 -0
- package/plugins/audit-project/lib/perf/profiling-runner.js +56 -0
- package/plugins/audit-project/lib/perf/schemas.js +140 -0
- package/plugins/audit-project/lib/platform/detect-platform.js +413 -0
- package/plugins/audit-project/lib/platform/detection-configs.js +93 -0
- package/plugins/audit-project/lib/platform/state-dir.js +132 -0
- package/plugins/audit-project/lib/platform/verify-tools.js +182 -0
- package/plugins/audit-project/lib/repo-map/cache.js +152 -0
- package/plugins/audit-project/lib/repo-map/index.js +222 -0
- package/plugins/audit-project/lib/repo-map/installer.js +212 -0
- package/plugins/audit-project/lib/repo-map/queries/go.js +27 -0
- package/plugins/audit-project/lib/repo-map/queries/index.js +100 -0
- package/plugins/audit-project/lib/repo-map/queries/java.js +38 -0
- package/plugins/audit-project/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/audit-project/lib/repo-map/queries/python.js +24 -0
- package/plugins/audit-project/lib/repo-map/queries/rust.js +73 -0
- package/plugins/audit-project/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/audit-project/lib/repo-map/runner.js +1165 -0
- package/plugins/audit-project/lib/repo-map/updater.js +474 -0
- package/plugins/audit-project/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/audit-project/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/audit-project/lib/schemas/validator.js +247 -0
- package/plugins/audit-project/lib/sources/custom-handler.js +199 -0
- package/plugins/audit-project/lib/sources/policy-questions.js +246 -0
- package/plugins/audit-project/lib/sources/source-cache.js +165 -0
- package/plugins/audit-project/lib/state/workflow-state.js +575 -0
- package/plugins/audit-project/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/audit-project/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/audit-project/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/audit-project/lib/types/index.d.ts +84 -0
- package/plugins/audit-project/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/audit-project/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/audit-project/lib/utils/atomic-write.js +94 -0
- package/plugins/audit-project/lib/utils/cache-manager.js +159 -0
- package/plugins/audit-project/lib/utils/context-optimizer.js +300 -0
- package/plugins/audit-project/lib/utils/deprecation.js +37 -0
- package/plugins/audit-project/lib/utils/shell-escape.js +88 -0
- package/plugins/consult/.claude-plugin/plugin.json +24 -0
- package/plugins/consult/agents/consult-agent.md +129 -0
- package/plugins/consult/commands/consult.md +248 -0
- package/plugins/consult/skills/consult/SKILL.md +285 -0
- package/plugins/deslop/.claude-plugin/plugin.json +20 -0
- package/plugins/deslop/agents/deslop-agent.md +88 -0
- package/plugins/deslop/commands/deslop.md +168 -0
- package/plugins/deslop/lib/adapter-transforms.js +278 -0
- package/plugins/deslop/lib/collectors/codebase.js +392 -0
- package/plugins/deslop/lib/collectors/docs-patterns.js +713 -0
- package/plugins/deslop/lib/collectors/documentation.js +219 -0
- package/plugins/deslop/lib/collectors/github.js +266 -0
- package/plugins/deslop/lib/collectors/index.js +126 -0
- package/plugins/deslop/lib/config/index.js +14 -0
- package/plugins/deslop/lib/cross-platform/index.js +539 -0
- package/plugins/deslop/lib/discovery/index.js +352 -0
- package/plugins/deslop/lib/drift-detect/collectors.js +37 -0
- package/plugins/deslop/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/deslop/lib/enhance/agent-patterns.js +571 -0
- package/plugins/deslop/lib/enhance/auto-suppression.js +622 -0
- package/plugins/deslop/lib/enhance/benchmark.js +417 -0
- package/plugins/deslop/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/deslop/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/deslop/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/deslop/lib/enhance/docs-patterns.js +671 -0
- package/plugins/deslop/lib/enhance/fixer.js +721 -0
- package/plugins/deslop/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/deslop/lib/enhance/hook-patterns.js +40 -0
- package/plugins/deslop/lib/enhance/index.js +127 -0
- package/plugins/deslop/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/deslop/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/deslop/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/deslop/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/deslop/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/deslop/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/deslop/lib/enhance/reporter.js +1348 -0
- package/plugins/deslop/lib/enhance/security-patterns.js +284 -0
- package/plugins/deslop/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/deslop/lib/enhance/skill-patterns.js +147 -0
- package/plugins/deslop/lib/enhance/suppression.js +352 -0
- package/plugins/deslop/lib/enhance/tool-patterns.js +373 -0
- package/plugins/deslop/lib/index.js +270 -0
- package/plugins/deslop/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/deslop/lib/patterns/pipeline.js +948 -0
- package/plugins/deslop/lib/patterns/review-patterns.js +558 -0
- package/plugins/deslop/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/deslop/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/deslop/lib/perf/analyzer/index.js +22 -0
- package/plugins/deslop/lib/perf/argument-parser.js +105 -0
- package/plugins/deslop/lib/perf/baseline-comparator.js +50 -0
- package/plugins/deslop/lib/perf/baseline-store.js +127 -0
- package/plugins/deslop/lib/perf/benchmark-runner.js +399 -0
- package/plugins/deslop/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/deslop/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/deslop/lib/perf/checkpoint.js +123 -0
- package/plugins/deslop/lib/perf/code-paths.js +86 -0
- package/plugins/deslop/lib/perf/consolidation.js +37 -0
- package/plugins/deslop/lib/perf/constraint-runner.js +71 -0
- package/plugins/deslop/lib/perf/experiment-runner.js +32 -0
- package/plugins/deslop/lib/perf/index.js +41 -0
- package/plugins/deslop/lib/perf/investigation-state.js +875 -0
- package/plugins/deslop/lib/perf/optimization-runner.js +79 -0
- package/plugins/deslop/lib/perf/profilers/go.js +22 -0
- package/plugins/deslop/lib/perf/profilers/index.js +46 -0
- package/plugins/deslop/lib/perf/profilers/java.js +23 -0
- package/plugins/deslop/lib/perf/profilers/node.js +27 -0
- package/plugins/deslop/lib/perf/profilers/python.js +23 -0
- package/plugins/deslop/lib/perf/profilers/rust.js +23 -0
- package/plugins/deslop/lib/perf/profiling-runner.js +56 -0
- package/plugins/deslop/lib/perf/schemas.js +140 -0
- package/plugins/deslop/lib/platform/detect-platform.js +413 -0
- package/plugins/deslop/lib/platform/detection-configs.js +93 -0
- package/plugins/deslop/lib/platform/state-dir.js +132 -0
- package/plugins/deslop/lib/platform/verify-tools.js +182 -0
- package/plugins/deslop/lib/repo-map/cache.js +152 -0
- package/plugins/deslop/lib/repo-map/index.js +222 -0
- package/plugins/deslop/lib/repo-map/installer.js +212 -0
- package/plugins/deslop/lib/repo-map/queries/go.js +27 -0
- package/plugins/deslop/lib/repo-map/queries/index.js +100 -0
- package/plugins/deslop/lib/repo-map/queries/java.js +38 -0
- package/plugins/deslop/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/deslop/lib/repo-map/queries/python.js +24 -0
- package/plugins/deslop/lib/repo-map/queries/rust.js +73 -0
- package/plugins/deslop/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/deslop/lib/repo-map/runner.js +1165 -0
- package/plugins/deslop/lib/repo-map/updater.js +474 -0
- package/plugins/deslop/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/deslop/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/deslop/lib/schemas/validator.js +247 -0
- package/plugins/deslop/lib/sources/custom-handler.js +199 -0
- package/plugins/deslop/lib/sources/policy-questions.js +246 -0
- package/plugins/deslop/lib/sources/source-cache.js +165 -0
- package/plugins/deslop/lib/state/workflow-state.js +575 -0
- package/plugins/deslop/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/deslop/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/deslop/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/deslop/lib/types/index.d.ts +84 -0
- package/plugins/deslop/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/deslop/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/deslop/lib/utils/atomic-write.js +94 -0
- package/plugins/deslop/lib/utils/cache-manager.js +159 -0
- package/plugins/deslop/lib/utils/context-optimizer.js +300 -0
- package/plugins/deslop/lib/utils/deprecation.js +37 -0
- package/plugins/deslop/lib/utils/shell-escape.js +88 -0
- package/plugins/deslop/references/slop-categories.md +122 -0
- package/plugins/deslop/scripts/detect.js +134 -0
- package/plugins/deslop/skills/deslop/SKILL.md +204 -0
- package/plugins/drift-detect/.claude-plugin/plugin.json +23 -0
- package/plugins/drift-detect/agents/plan-synthesizer.md +225 -0
- package/plugins/drift-detect/commands/drift-detect.md +269 -0
- package/plugins/drift-detect/lib/adapter-transforms.js +278 -0
- package/plugins/drift-detect/lib/collectors/codebase.js +392 -0
- package/plugins/drift-detect/lib/collectors/docs-patterns.js +713 -0
- package/plugins/drift-detect/lib/collectors/documentation.js +219 -0
- package/plugins/drift-detect/lib/collectors/github.js +266 -0
- package/plugins/drift-detect/lib/collectors/index.js +126 -0
- package/plugins/drift-detect/lib/config/index.js +14 -0
- package/plugins/drift-detect/lib/cross-platform/index.js +539 -0
- package/plugins/drift-detect/lib/discovery/index.js +352 -0
- package/plugins/drift-detect/lib/drift-detect/collectors.js +37 -0
- package/plugins/drift-detect/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/drift-detect/lib/enhance/agent-patterns.js +571 -0
- package/plugins/drift-detect/lib/enhance/auto-suppression.js +622 -0
- package/plugins/drift-detect/lib/enhance/benchmark.js +417 -0
- package/plugins/drift-detect/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/drift-detect/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/drift-detect/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/drift-detect/lib/enhance/docs-patterns.js +671 -0
- package/plugins/drift-detect/lib/enhance/fixer.js +721 -0
- package/plugins/drift-detect/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/drift-detect/lib/enhance/hook-patterns.js +40 -0
- package/plugins/drift-detect/lib/enhance/index.js +127 -0
- package/plugins/drift-detect/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/drift-detect/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/drift-detect/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/drift-detect/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/drift-detect/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/drift-detect/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/drift-detect/lib/enhance/reporter.js +1348 -0
- package/plugins/drift-detect/lib/enhance/security-patterns.js +284 -0
- package/plugins/drift-detect/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/drift-detect/lib/enhance/skill-patterns.js +147 -0
- package/plugins/drift-detect/lib/enhance/suppression.js +352 -0
- package/plugins/drift-detect/lib/enhance/tool-patterns.js +373 -0
- package/plugins/drift-detect/lib/index.js +270 -0
- package/plugins/drift-detect/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/drift-detect/lib/patterns/pipeline.js +948 -0
- package/plugins/drift-detect/lib/patterns/review-patterns.js +558 -0
- package/plugins/drift-detect/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/drift-detect/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/drift-detect/lib/perf/analyzer/index.js +22 -0
- package/plugins/drift-detect/lib/perf/argument-parser.js +105 -0
- package/plugins/drift-detect/lib/perf/baseline-comparator.js +50 -0
- package/plugins/drift-detect/lib/perf/baseline-store.js +127 -0
- package/plugins/drift-detect/lib/perf/benchmark-runner.js +399 -0
- package/plugins/drift-detect/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/drift-detect/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/drift-detect/lib/perf/checkpoint.js +123 -0
- package/plugins/drift-detect/lib/perf/code-paths.js +86 -0
- package/plugins/drift-detect/lib/perf/consolidation.js +37 -0
- package/plugins/drift-detect/lib/perf/constraint-runner.js +71 -0
- package/plugins/drift-detect/lib/perf/experiment-runner.js +32 -0
- package/plugins/drift-detect/lib/perf/index.js +41 -0
- package/plugins/drift-detect/lib/perf/investigation-state.js +875 -0
- package/plugins/drift-detect/lib/perf/optimization-runner.js +79 -0
- package/plugins/drift-detect/lib/perf/profilers/go.js +22 -0
- package/plugins/drift-detect/lib/perf/profilers/index.js +46 -0
- package/plugins/drift-detect/lib/perf/profilers/java.js +23 -0
- package/plugins/drift-detect/lib/perf/profilers/node.js +27 -0
- package/plugins/drift-detect/lib/perf/profilers/python.js +23 -0
- package/plugins/drift-detect/lib/perf/profilers/rust.js +23 -0
- package/plugins/drift-detect/lib/perf/profiling-runner.js +56 -0
- package/plugins/drift-detect/lib/perf/schemas.js +140 -0
- package/plugins/drift-detect/lib/platform/detect-platform.js +413 -0
- package/plugins/drift-detect/lib/platform/detection-configs.js +93 -0
- package/plugins/drift-detect/lib/platform/state-dir.js +132 -0
- package/plugins/drift-detect/lib/platform/verify-tools.js +182 -0
- package/plugins/drift-detect/lib/repo-map/cache.js +152 -0
- package/plugins/drift-detect/lib/repo-map/index.js +222 -0
- package/plugins/drift-detect/lib/repo-map/installer.js +212 -0
- package/plugins/drift-detect/lib/repo-map/queries/go.js +27 -0
- package/plugins/drift-detect/lib/repo-map/queries/index.js +100 -0
- package/plugins/drift-detect/lib/repo-map/queries/java.js +38 -0
- package/plugins/drift-detect/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/drift-detect/lib/repo-map/queries/python.js +24 -0
- package/plugins/drift-detect/lib/repo-map/queries/rust.js +73 -0
- package/plugins/drift-detect/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/drift-detect/lib/repo-map/runner.js +1165 -0
- package/plugins/drift-detect/lib/repo-map/updater.js +474 -0
- package/plugins/drift-detect/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/drift-detect/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/drift-detect/lib/schemas/validator.js +247 -0
- package/plugins/drift-detect/lib/sources/custom-handler.js +199 -0
- package/plugins/drift-detect/lib/sources/policy-questions.js +246 -0
- package/plugins/drift-detect/lib/sources/source-cache.js +165 -0
- package/plugins/drift-detect/lib/state/workflow-state.js +575 -0
- package/plugins/drift-detect/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/drift-detect/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/drift-detect/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/drift-detect/lib/types/index.d.ts +84 -0
- package/plugins/drift-detect/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/drift-detect/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/drift-detect/lib/utils/atomic-write.js +94 -0
- package/plugins/drift-detect/lib/utils/cache-manager.js +159 -0
- package/plugins/drift-detect/lib/utils/context-optimizer.js +300 -0
- package/plugins/drift-detect/lib/utils/deprecation.js +37 -0
- package/plugins/drift-detect/lib/utils/shell-escape.js +88 -0
- package/plugins/drift-detect/skills/drift-analysis/SKILL.md +324 -0
- package/plugins/enhance/.claude-plugin/plugin.json +20 -0
- package/plugins/enhance/agents/agent-enhancer.md +64 -0
- package/plugins/enhance/agents/claudemd-enhancer.md +65 -0
- package/plugins/enhance/agents/cross-file-enhancer.md +54 -0
- package/plugins/enhance/agents/docs-enhancer.md +64 -0
- package/plugins/enhance/agents/hooks-enhancer.md +64 -0
- package/plugins/enhance/agents/plugin-enhancer.md +63 -0
- package/plugins/enhance/agents/prompt-enhancer.md +58 -0
- package/plugins/enhance/agents/skills-enhancer.md +64 -0
- package/plugins/enhance/commands/enhance.md +178 -0
- package/plugins/enhance/lib/adapter-transforms.js +278 -0
- package/plugins/enhance/lib/collectors/codebase.js +392 -0
- package/plugins/enhance/lib/collectors/docs-patterns.js +713 -0
- package/plugins/enhance/lib/collectors/documentation.js +219 -0
- package/plugins/enhance/lib/collectors/github.js +266 -0
- package/plugins/enhance/lib/collectors/index.js +126 -0
- package/plugins/enhance/lib/config/index.js +14 -0
- package/plugins/enhance/lib/cross-platform/index.js +539 -0
- package/plugins/enhance/lib/discovery/index.js +352 -0
- package/plugins/enhance/lib/drift-detect/collectors.js +37 -0
- package/plugins/enhance/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/enhance/lib/enhance/agent-patterns.js +571 -0
- package/plugins/enhance/lib/enhance/auto-suppression.js +622 -0
- package/plugins/enhance/lib/enhance/benchmark.js +417 -0
- package/plugins/enhance/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/enhance/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/enhance/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/enhance/lib/enhance/docs-patterns.js +671 -0
- package/plugins/enhance/lib/enhance/fixer.js +721 -0
- package/plugins/enhance/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/enhance/lib/enhance/hook-patterns.js +40 -0
- package/plugins/enhance/lib/enhance/index.js +127 -0
- package/plugins/enhance/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/enhance/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/enhance/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/enhance/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/enhance/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/enhance/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/enhance/lib/enhance/reporter.js +1348 -0
- package/plugins/enhance/lib/enhance/security-patterns.js +284 -0
- package/plugins/enhance/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/enhance/lib/enhance/skill-patterns.js +147 -0
- package/plugins/enhance/lib/enhance/suppression.js +352 -0
- package/plugins/enhance/lib/enhance/tool-patterns.js +373 -0
- package/plugins/enhance/lib/index.js +270 -0
- package/plugins/enhance/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/enhance/lib/patterns/pipeline.js +948 -0
- package/plugins/enhance/lib/patterns/review-patterns.js +558 -0
- package/plugins/enhance/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/enhance/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/enhance/lib/perf/analyzer/index.js +22 -0
- package/plugins/enhance/lib/perf/argument-parser.js +105 -0
- package/plugins/enhance/lib/perf/baseline-comparator.js +50 -0
- package/plugins/enhance/lib/perf/baseline-store.js +127 -0
- package/plugins/enhance/lib/perf/benchmark-runner.js +399 -0
- package/plugins/enhance/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/enhance/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/enhance/lib/perf/checkpoint.js +123 -0
- package/plugins/enhance/lib/perf/code-paths.js +86 -0
- package/plugins/enhance/lib/perf/consolidation.js +37 -0
- package/plugins/enhance/lib/perf/constraint-runner.js +71 -0
- package/plugins/enhance/lib/perf/experiment-runner.js +32 -0
- package/plugins/enhance/lib/perf/index.js +41 -0
- package/plugins/enhance/lib/perf/investigation-state.js +875 -0
- package/plugins/enhance/lib/perf/optimization-runner.js +79 -0
- package/plugins/enhance/lib/perf/profilers/go.js +22 -0
- package/plugins/enhance/lib/perf/profilers/index.js +46 -0
- package/plugins/enhance/lib/perf/profilers/java.js +23 -0
- package/plugins/enhance/lib/perf/profilers/node.js +27 -0
- package/plugins/enhance/lib/perf/profilers/python.js +23 -0
- package/plugins/enhance/lib/perf/profilers/rust.js +23 -0
- package/plugins/enhance/lib/perf/profiling-runner.js +56 -0
- package/plugins/enhance/lib/perf/schemas.js +140 -0
- package/plugins/enhance/lib/platform/detect-platform.js +413 -0
- package/plugins/enhance/lib/platform/detection-configs.js +93 -0
- package/plugins/enhance/lib/platform/state-dir.js +132 -0
- package/plugins/enhance/lib/platform/verify-tools.js +182 -0
- package/plugins/enhance/lib/repo-map/cache.js +152 -0
- package/plugins/enhance/lib/repo-map/index.js +222 -0
- package/plugins/enhance/lib/repo-map/installer.js +212 -0
- package/plugins/enhance/lib/repo-map/queries/go.js +27 -0
- package/plugins/enhance/lib/repo-map/queries/index.js +100 -0
- package/plugins/enhance/lib/repo-map/queries/java.js +38 -0
- package/plugins/enhance/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/enhance/lib/repo-map/queries/python.js +24 -0
- package/plugins/enhance/lib/repo-map/queries/rust.js +73 -0
- package/plugins/enhance/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/enhance/lib/repo-map/runner.js +1165 -0
- package/plugins/enhance/lib/repo-map/updater.js +474 -0
- package/plugins/enhance/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/enhance/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/enhance/lib/schemas/validator.js +247 -0
- package/plugins/enhance/lib/sources/custom-handler.js +199 -0
- package/plugins/enhance/lib/sources/policy-questions.js +246 -0
- package/plugins/enhance/lib/sources/source-cache.js +165 -0
- package/plugins/enhance/lib/state/workflow-state.js +575 -0
- package/plugins/enhance/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/enhance/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/enhance/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/enhance/lib/types/index.d.ts +84 -0
- package/plugins/enhance/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/enhance/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/enhance/lib/utils/atomic-write.js +94 -0
- package/plugins/enhance/lib/utils/cache-manager.js +159 -0
- package/plugins/enhance/lib/utils/context-optimizer.js +300 -0
- package/plugins/enhance/lib/utils/deprecation.js +37 -0
- package/plugins/enhance/lib/utils/shell-escape.js +88 -0
- package/plugins/enhance/skills/enhance-agent-prompts/SKILL.md +277 -0
- package/plugins/enhance/skills/enhance-claude-memory/SKILL.md +387 -0
- package/plugins/enhance/skills/enhance-cross-file/SKILL.md +110 -0
- package/plugins/enhance/skills/enhance-docs/SKILL.md +298 -0
- package/plugins/enhance/skills/enhance-hooks/SKILL.md +554 -0
- package/plugins/enhance/skills/enhance-orchestrator/SKILL.md +255 -0
- package/plugins/enhance/skills/enhance-plugins/SKILL.md +319 -0
- package/plugins/enhance/skills/enhance-prompts/SKILL.md +340 -0
- package/plugins/enhance/skills/enhance-skills/SKILL.md +436 -0
- package/plugins/learn/.claude-plugin/plugin.json +21 -0
- package/plugins/learn/agents/learn-agent.md +331 -0
- package/plugins/learn/commands/learn.md +190 -0
- package/plugins/learn/lib/adapter-transforms.js +278 -0
- package/plugins/learn/lib/collectors/codebase.js +392 -0
- package/plugins/learn/lib/collectors/docs-patterns.js +713 -0
- package/plugins/learn/lib/collectors/documentation.js +219 -0
- package/plugins/learn/lib/collectors/github.js +266 -0
- package/plugins/learn/lib/collectors/index.js +126 -0
- package/plugins/learn/lib/config/index.js +14 -0
- package/plugins/learn/lib/cross-platform/index.js +539 -0
- package/plugins/learn/lib/discovery/index.js +352 -0
- package/plugins/learn/lib/drift-detect/collectors.js +37 -0
- package/plugins/learn/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/learn/lib/enhance/agent-patterns.js +571 -0
- package/plugins/learn/lib/enhance/auto-suppression.js +622 -0
- package/plugins/learn/lib/enhance/benchmark.js +417 -0
- package/plugins/learn/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/learn/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/learn/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/learn/lib/enhance/docs-patterns.js +671 -0
- package/plugins/learn/lib/enhance/fixer.js +721 -0
- package/plugins/learn/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/learn/lib/enhance/hook-patterns.js +40 -0
- package/plugins/learn/lib/enhance/index.js +127 -0
- package/plugins/learn/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/learn/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/learn/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/learn/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/learn/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/learn/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/learn/lib/enhance/reporter.js +1348 -0
- package/plugins/learn/lib/enhance/security-patterns.js +284 -0
- package/plugins/learn/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/learn/lib/enhance/skill-patterns.js +147 -0
- package/plugins/learn/lib/enhance/suppression.js +352 -0
- package/plugins/learn/lib/enhance/tool-patterns.js +373 -0
- package/plugins/learn/lib/index.js +270 -0
- package/plugins/learn/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/learn/lib/patterns/pipeline.js +948 -0
- package/plugins/learn/lib/patterns/review-patterns.js +558 -0
- package/plugins/learn/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/learn/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/learn/lib/perf/analyzer/index.js +22 -0
- package/plugins/learn/lib/perf/argument-parser.js +105 -0
- package/plugins/learn/lib/perf/baseline-comparator.js +50 -0
- package/plugins/learn/lib/perf/baseline-store.js +127 -0
- package/plugins/learn/lib/perf/benchmark-runner.js +399 -0
- package/plugins/learn/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/learn/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/learn/lib/perf/checkpoint.js +123 -0
- package/plugins/learn/lib/perf/code-paths.js +86 -0
- package/plugins/learn/lib/perf/consolidation.js +37 -0
- package/plugins/learn/lib/perf/constraint-runner.js +71 -0
- package/plugins/learn/lib/perf/experiment-runner.js +32 -0
- package/plugins/learn/lib/perf/index.js +41 -0
- package/plugins/learn/lib/perf/investigation-state.js +875 -0
- package/plugins/learn/lib/perf/optimization-runner.js +79 -0
- package/plugins/learn/lib/perf/profilers/go.js +22 -0
- package/plugins/learn/lib/perf/profilers/index.js +46 -0
- package/plugins/learn/lib/perf/profilers/java.js +23 -0
- package/plugins/learn/lib/perf/profilers/node.js +27 -0
- package/plugins/learn/lib/perf/profilers/python.js +23 -0
- package/plugins/learn/lib/perf/profilers/rust.js +23 -0
- package/plugins/learn/lib/perf/profiling-runner.js +56 -0
- package/plugins/learn/lib/perf/schemas.js +140 -0
- package/plugins/learn/lib/platform/detect-platform.js +413 -0
- package/plugins/learn/lib/platform/detection-configs.js +93 -0
- package/plugins/learn/lib/platform/state-dir.js +132 -0
- package/plugins/learn/lib/platform/verify-tools.js +182 -0
- package/plugins/learn/lib/repo-map/cache.js +152 -0
- package/plugins/learn/lib/repo-map/index.js +222 -0
- package/plugins/learn/lib/repo-map/installer.js +212 -0
- package/plugins/learn/lib/repo-map/queries/go.js +27 -0
- package/plugins/learn/lib/repo-map/queries/index.js +100 -0
- package/plugins/learn/lib/repo-map/queries/java.js +38 -0
- package/plugins/learn/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/learn/lib/repo-map/queries/python.js +24 -0
- package/plugins/learn/lib/repo-map/queries/rust.js +73 -0
- package/plugins/learn/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/learn/lib/repo-map/runner.js +1165 -0
- package/plugins/learn/lib/repo-map/updater.js +474 -0
- package/plugins/learn/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/learn/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/learn/lib/schemas/validator.js +247 -0
- package/plugins/learn/lib/sources/custom-handler.js +199 -0
- package/plugins/learn/lib/sources/policy-questions.js +246 -0
- package/plugins/learn/lib/sources/source-cache.js +165 -0
- package/plugins/learn/lib/state/workflow-state.js +575 -0
- package/plugins/learn/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/learn/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/learn/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/learn/lib/types/index.d.ts +84 -0
- package/plugins/learn/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/learn/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/learn/lib/utils/atomic-write.js +94 -0
- package/plugins/learn/lib/utils/cache-manager.js +159 -0
- package/plugins/learn/lib/utils/context-optimizer.js +300 -0
- package/plugins/learn/lib/utils/deprecation.js +37 -0
- package/plugins/learn/lib/utils/shell-escape.js +88 -0
- package/plugins/learn/skills/learn/SKILL.md +349 -0
- package/plugins/next-task/.claude-plugin/plugin.json +24 -0
- package/plugins/next-task/agents/ci-fixer.md +259 -0
- package/plugins/next-task/agents/ci-monitor.md +342 -0
- package/plugins/next-task/agents/delivery-validator.md +115 -0
- package/plugins/next-task/agents/exploration-agent.md +316 -0
- package/plugins/next-task/agents/implementation-agent.md +465 -0
- package/plugins/next-task/agents/planning-agent.md +377 -0
- package/plugins/next-task/agents/simple-fixer.md +139 -0
- package/plugins/next-task/agents/task-discoverer.md +89 -0
- package/plugins/next-task/agents/test-coverage-checker.md +451 -0
- package/plugins/next-task/agents/worktree-manager.md +257 -0
- package/plugins/next-task/commands/delivery-approval.md +341 -0
- package/plugins/next-task/commands/next-task.md +547 -0
- package/plugins/next-task/hooks/hooks.json +14 -0
- package/plugins/next-task/lib/adapter-transforms.js +278 -0
- package/plugins/next-task/lib/collectors/codebase.js +392 -0
- package/plugins/next-task/lib/collectors/docs-patterns.js +713 -0
- package/plugins/next-task/lib/collectors/documentation.js +219 -0
- package/plugins/next-task/lib/collectors/github.js +266 -0
- package/plugins/next-task/lib/collectors/index.js +126 -0
- package/plugins/next-task/lib/config/index.js +14 -0
- package/plugins/next-task/lib/cross-platform/index.js +539 -0
- package/plugins/next-task/lib/discovery/index.js +352 -0
- package/plugins/next-task/lib/drift-detect/collectors.js +37 -0
- package/plugins/next-task/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/next-task/lib/enhance/agent-patterns.js +571 -0
- package/plugins/next-task/lib/enhance/auto-suppression.js +622 -0
- package/plugins/next-task/lib/enhance/benchmark.js +417 -0
- package/plugins/next-task/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/next-task/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/next-task/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/next-task/lib/enhance/docs-patterns.js +671 -0
- package/plugins/next-task/lib/enhance/fixer.js +721 -0
- package/plugins/next-task/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/next-task/lib/enhance/hook-patterns.js +40 -0
- package/plugins/next-task/lib/enhance/index.js +127 -0
- package/plugins/next-task/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/next-task/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/next-task/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/next-task/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/next-task/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/next-task/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/next-task/lib/enhance/reporter.js +1348 -0
- package/plugins/next-task/lib/enhance/security-patterns.js +284 -0
- package/plugins/next-task/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/next-task/lib/enhance/skill-patterns.js +147 -0
- package/plugins/next-task/lib/enhance/suppression.js +352 -0
- package/plugins/next-task/lib/enhance/tool-patterns.js +373 -0
- package/plugins/next-task/lib/index.js +270 -0
- package/plugins/next-task/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/next-task/lib/patterns/pipeline.js +948 -0
- package/plugins/next-task/lib/patterns/review-patterns.js +558 -0
- package/plugins/next-task/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/next-task/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/next-task/lib/perf/analyzer/index.js +22 -0
- package/plugins/next-task/lib/perf/argument-parser.js +105 -0
- package/plugins/next-task/lib/perf/baseline-comparator.js +50 -0
- package/plugins/next-task/lib/perf/baseline-store.js +127 -0
- package/plugins/next-task/lib/perf/benchmark-runner.js +399 -0
- package/plugins/next-task/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/next-task/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/next-task/lib/perf/checkpoint.js +123 -0
- package/plugins/next-task/lib/perf/code-paths.js +86 -0
- package/plugins/next-task/lib/perf/consolidation.js +37 -0
- package/plugins/next-task/lib/perf/constraint-runner.js +71 -0
- package/plugins/next-task/lib/perf/experiment-runner.js +32 -0
- package/plugins/next-task/lib/perf/index.js +41 -0
- package/plugins/next-task/lib/perf/investigation-state.js +875 -0
- package/plugins/next-task/lib/perf/optimization-runner.js +79 -0
- package/plugins/next-task/lib/perf/profilers/go.js +22 -0
- package/plugins/next-task/lib/perf/profilers/index.js +46 -0
- package/plugins/next-task/lib/perf/profilers/java.js +23 -0
- package/plugins/next-task/lib/perf/profilers/node.js +27 -0
- package/plugins/next-task/lib/perf/profilers/python.js +23 -0
- package/plugins/next-task/lib/perf/profilers/rust.js +23 -0
- package/plugins/next-task/lib/perf/profiling-runner.js +56 -0
- package/plugins/next-task/lib/perf/schemas.js +140 -0
- package/plugins/next-task/lib/platform/detect-platform.js +413 -0
- package/plugins/next-task/lib/platform/detection-configs.js +93 -0
- package/plugins/next-task/lib/platform/state-dir.js +132 -0
- package/plugins/next-task/lib/platform/verify-tools.js +182 -0
- package/plugins/next-task/lib/repo-map/cache.js +152 -0
- package/plugins/next-task/lib/repo-map/index.js +222 -0
- package/plugins/next-task/lib/repo-map/installer.js +212 -0
- package/plugins/next-task/lib/repo-map/queries/go.js +27 -0
- package/plugins/next-task/lib/repo-map/queries/index.js +100 -0
- package/plugins/next-task/lib/repo-map/queries/java.js +38 -0
- package/plugins/next-task/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/next-task/lib/repo-map/queries/python.js +24 -0
- package/plugins/next-task/lib/repo-map/queries/rust.js +73 -0
- package/plugins/next-task/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/next-task/lib/repo-map/runner.js +1165 -0
- package/plugins/next-task/lib/repo-map/updater.js +474 -0
- package/plugins/next-task/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/next-task/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/next-task/lib/schemas/validator.js +247 -0
- package/plugins/next-task/lib/sources/custom-handler.js +199 -0
- package/plugins/next-task/lib/sources/policy-questions.js +246 -0
- package/plugins/next-task/lib/sources/source-cache.js +165 -0
- package/plugins/next-task/lib/state/workflow-state.js +575 -0
- package/plugins/next-task/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/next-task/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/next-task/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/next-task/lib/types/index.d.ts +84 -0
- package/plugins/next-task/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/next-task/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/next-task/lib/utils/atomic-write.js +94 -0
- package/plugins/next-task/lib/utils/cache-manager.js +159 -0
- package/plugins/next-task/lib/utils/context-optimizer.js +300 -0
- package/plugins/next-task/lib/utils/deprecation.js +37 -0
- package/plugins/next-task/lib/utils/shell-escape.js +88 -0
- package/plugins/next-task/skills/discover-tasks/SKILL.md +191 -0
- package/plugins/next-task/skills/orchestrate-review/SKILL.md +239 -0
- package/plugins/next-task/skills/validate-delivery/SKILL.md +186 -0
- package/plugins/perf/.claude-plugin/plugin.json +20 -0
- package/plugins/perf/agents/perf-analyzer.md +43 -0
- package/plugins/perf/agents/perf-code-paths.md +16 -0
- package/plugins/perf/agents/perf-investigation-logger.md +47 -0
- package/plugins/perf/agents/perf-orchestrator.md +344 -0
- package/plugins/perf/agents/perf-theory-gatherer.md +25 -0
- package/plugins/perf/agents/perf-theory-tester.md +58 -0
- package/plugins/perf/commands/perf.md +470 -0
- package/plugins/perf/hooks/checkpoint.md +35 -0
- package/plugins/perf/hooks/constraint-tester.md +40 -0
- package/plugins/perf/lib/adapter-transforms.js +278 -0
- package/plugins/perf/lib/collectors/codebase.js +392 -0
- package/plugins/perf/lib/collectors/docs-patterns.js +713 -0
- package/plugins/perf/lib/collectors/documentation.js +219 -0
- package/plugins/perf/lib/collectors/github.js +266 -0
- package/plugins/perf/lib/collectors/index.js +126 -0
- package/plugins/perf/lib/config/index.js +14 -0
- package/plugins/perf/lib/cross-platform/index.js +539 -0
- package/plugins/perf/lib/discovery/index.js +352 -0
- package/plugins/perf/lib/drift-detect/collectors.js +37 -0
- package/plugins/perf/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/perf/lib/enhance/agent-patterns.js +571 -0
- package/plugins/perf/lib/enhance/auto-suppression.js +622 -0
- package/plugins/perf/lib/enhance/benchmark.js +417 -0
- package/plugins/perf/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/perf/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/perf/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/perf/lib/enhance/docs-patterns.js +671 -0
- package/plugins/perf/lib/enhance/fixer.js +721 -0
- package/plugins/perf/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/perf/lib/enhance/hook-patterns.js +40 -0
- package/plugins/perf/lib/enhance/index.js +127 -0
- package/plugins/perf/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/perf/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/perf/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/perf/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/perf/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/perf/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/perf/lib/enhance/reporter.js +1348 -0
- package/plugins/perf/lib/enhance/security-patterns.js +284 -0
- package/plugins/perf/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/perf/lib/enhance/skill-patterns.js +147 -0
- package/plugins/perf/lib/enhance/suppression.js +352 -0
- package/plugins/perf/lib/enhance/tool-patterns.js +373 -0
- package/plugins/perf/lib/index.js +270 -0
- package/plugins/perf/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/perf/lib/patterns/pipeline.js +948 -0
- package/plugins/perf/lib/patterns/review-patterns.js +558 -0
- package/plugins/perf/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/perf/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/perf/lib/perf/analyzer/index.js +22 -0
- package/plugins/perf/lib/perf/argument-parser.js +105 -0
- package/plugins/perf/lib/perf/baseline-comparator.js +50 -0
- package/plugins/perf/lib/perf/baseline-store.js +127 -0
- package/plugins/perf/lib/perf/benchmark-runner.js +399 -0
- package/plugins/perf/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/perf/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/perf/lib/perf/checkpoint.js +123 -0
- package/plugins/perf/lib/perf/code-paths.js +86 -0
- package/plugins/perf/lib/perf/consolidation.js +37 -0
- package/plugins/perf/lib/perf/constraint-runner.js +71 -0
- package/plugins/perf/lib/perf/experiment-runner.js +32 -0
- package/plugins/perf/lib/perf/index.js +41 -0
- package/plugins/perf/lib/perf/investigation-state.js +875 -0
- package/plugins/perf/lib/perf/optimization-runner.js +79 -0
- package/plugins/perf/lib/perf/profilers/go.js +22 -0
- package/plugins/perf/lib/perf/profilers/index.js +46 -0
- package/plugins/perf/lib/perf/profilers/java.js +23 -0
- package/plugins/perf/lib/perf/profilers/node.js +27 -0
- package/plugins/perf/lib/perf/profilers/python.js +23 -0
- package/plugins/perf/lib/perf/profilers/rust.js +23 -0
- package/plugins/perf/lib/perf/profiling-runner.js +56 -0
- package/plugins/perf/lib/perf/schemas.js +140 -0
- package/plugins/perf/lib/platform/detect-platform.js +413 -0
- package/plugins/perf/lib/platform/detection-configs.js +93 -0
- package/plugins/perf/lib/platform/state-dir.js +132 -0
- package/plugins/perf/lib/platform/verify-tools.js +182 -0
- package/plugins/perf/lib/repo-map/cache.js +152 -0
- package/plugins/perf/lib/repo-map/index.js +222 -0
- package/plugins/perf/lib/repo-map/installer.js +212 -0
- package/plugins/perf/lib/repo-map/queries/go.js +27 -0
- package/plugins/perf/lib/repo-map/queries/index.js +100 -0
- package/plugins/perf/lib/repo-map/queries/java.js +38 -0
- package/plugins/perf/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/perf/lib/repo-map/queries/python.js +24 -0
- package/plugins/perf/lib/repo-map/queries/rust.js +73 -0
- package/plugins/perf/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/perf/lib/repo-map/runner.js +1165 -0
- package/plugins/perf/lib/repo-map/updater.js +474 -0
- package/plugins/perf/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/perf/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/perf/lib/schemas/validator.js +247 -0
- package/plugins/perf/lib/sources/custom-handler.js +199 -0
- package/plugins/perf/lib/sources/policy-questions.js +246 -0
- package/plugins/perf/lib/sources/source-cache.js +165 -0
- package/plugins/perf/lib/state/workflow-state.js +575 -0
- package/plugins/perf/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/perf/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/perf/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/perf/lib/types/index.d.ts +84 -0
- package/plugins/perf/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/perf/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/perf/lib/utils/atomic-write.js +94 -0
- package/plugins/perf/lib/utils/cache-manager.js +159 -0
- package/plugins/perf/lib/utils/context-optimizer.js +300 -0
- package/plugins/perf/lib/utils/deprecation.js +37 -0
- package/plugins/perf/lib/utils/shell-escape.js +88 -0
- package/plugins/perf/skills/perf-analyzer/SKILL.md +37 -0
- package/plugins/perf/skills/perf-baseline-manager/SKILL.md +30 -0
- package/plugins/perf/skills/perf-benchmarker/SKILL.md +52 -0
- package/plugins/perf/skills/perf-code-paths/SKILL.md +32 -0
- package/plugins/perf/skills/perf-investigation-logger/SKILL.md +41 -0
- package/plugins/perf/skills/perf-profiler/SKILL.md +42 -0
- package/plugins/perf/skills/perf-theory-gatherer/SKILL.md +35 -0
- package/plugins/perf/skills/perf-theory-tester/SKILL.md +36 -0
- package/plugins/repo-map/.claude-plugin/plugin.json +22 -0
- package/plugins/repo-map/agents/map-validator.md +60 -0
- package/plugins/repo-map/commands/repo-map.md +133 -0
- package/plugins/repo-map/lib/adapter-transforms.js +278 -0
- package/plugins/repo-map/lib/collectors/codebase.js +392 -0
- package/plugins/repo-map/lib/collectors/docs-patterns.js +713 -0
- package/plugins/repo-map/lib/collectors/documentation.js +219 -0
- package/plugins/repo-map/lib/collectors/github.js +266 -0
- package/plugins/repo-map/lib/collectors/index.js +126 -0
- package/plugins/repo-map/lib/config/index.js +14 -0
- package/plugins/repo-map/lib/cross-platform/index.js +539 -0
- package/plugins/repo-map/lib/discovery/index.js +352 -0
- package/plugins/repo-map/lib/drift-detect/collectors.js +37 -0
- package/plugins/repo-map/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/repo-map/lib/enhance/agent-patterns.js +571 -0
- package/plugins/repo-map/lib/enhance/auto-suppression.js +622 -0
- package/plugins/repo-map/lib/enhance/benchmark.js +417 -0
- package/plugins/repo-map/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/repo-map/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/repo-map/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/repo-map/lib/enhance/docs-patterns.js +671 -0
- package/plugins/repo-map/lib/enhance/fixer.js +721 -0
- package/plugins/repo-map/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/repo-map/lib/enhance/hook-patterns.js +40 -0
- package/plugins/repo-map/lib/enhance/index.js +127 -0
- package/plugins/repo-map/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/repo-map/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/repo-map/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/repo-map/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/repo-map/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/repo-map/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/repo-map/lib/enhance/reporter.js +1348 -0
- package/plugins/repo-map/lib/enhance/security-patterns.js +284 -0
- package/plugins/repo-map/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/repo-map/lib/enhance/skill-patterns.js +147 -0
- package/plugins/repo-map/lib/enhance/suppression.js +352 -0
- package/plugins/repo-map/lib/enhance/tool-patterns.js +373 -0
- package/plugins/repo-map/lib/index.js +270 -0
- package/plugins/repo-map/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/repo-map/lib/patterns/pipeline.js +948 -0
- package/plugins/repo-map/lib/patterns/review-patterns.js +558 -0
- package/plugins/repo-map/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/repo-map/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/repo-map/lib/perf/analyzer/index.js +22 -0
- package/plugins/repo-map/lib/perf/argument-parser.js +105 -0
- package/plugins/repo-map/lib/perf/baseline-comparator.js +50 -0
- package/plugins/repo-map/lib/perf/baseline-store.js +127 -0
- package/plugins/repo-map/lib/perf/benchmark-runner.js +399 -0
- package/plugins/repo-map/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/repo-map/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/repo-map/lib/perf/checkpoint.js +123 -0
- package/plugins/repo-map/lib/perf/code-paths.js +86 -0
- package/plugins/repo-map/lib/perf/consolidation.js +37 -0
- package/plugins/repo-map/lib/perf/constraint-runner.js +71 -0
- package/plugins/repo-map/lib/perf/experiment-runner.js +32 -0
- package/plugins/repo-map/lib/perf/index.js +41 -0
- package/plugins/repo-map/lib/perf/investigation-state.js +875 -0
- package/plugins/repo-map/lib/perf/optimization-runner.js +79 -0
- package/plugins/repo-map/lib/perf/profilers/go.js +22 -0
- package/plugins/repo-map/lib/perf/profilers/index.js +46 -0
- package/plugins/repo-map/lib/perf/profilers/java.js +23 -0
- package/plugins/repo-map/lib/perf/profilers/node.js +27 -0
- package/plugins/repo-map/lib/perf/profilers/python.js +23 -0
- package/plugins/repo-map/lib/perf/profilers/rust.js +23 -0
- package/plugins/repo-map/lib/perf/profiling-runner.js +56 -0
- package/plugins/repo-map/lib/perf/schemas.js +140 -0
- package/plugins/repo-map/lib/platform/detect-platform.js +413 -0
- package/plugins/repo-map/lib/platform/detection-configs.js +93 -0
- package/plugins/repo-map/lib/platform/state-dir.js +132 -0
- package/plugins/repo-map/lib/platform/verify-tools.js +182 -0
- package/plugins/repo-map/lib/repo-map/cache.js +152 -0
- package/plugins/repo-map/lib/repo-map/index.js +222 -0
- package/plugins/repo-map/lib/repo-map/installer.js +212 -0
- package/plugins/repo-map/lib/repo-map/queries/go.js +27 -0
- package/plugins/repo-map/lib/repo-map/queries/index.js +100 -0
- package/plugins/repo-map/lib/repo-map/queries/java.js +38 -0
- package/plugins/repo-map/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/repo-map/lib/repo-map/queries/python.js +24 -0
- package/plugins/repo-map/lib/repo-map/queries/rust.js +73 -0
- package/plugins/repo-map/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/repo-map/lib/repo-map/runner.js +1165 -0
- package/plugins/repo-map/lib/repo-map/updater.js +474 -0
- package/plugins/repo-map/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/repo-map/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/repo-map/lib/schemas/validator.js +247 -0
- package/plugins/repo-map/lib/sources/custom-handler.js +199 -0
- package/plugins/repo-map/lib/sources/policy-questions.js +246 -0
- package/plugins/repo-map/lib/sources/source-cache.js +165 -0
- package/plugins/repo-map/lib/state/workflow-state.js +575 -0
- package/plugins/repo-map/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/repo-map/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/repo-map/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/repo-map/lib/types/index.d.ts +84 -0
- package/plugins/repo-map/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/repo-map/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/repo-map/lib/utils/atomic-write.js +94 -0
- package/plugins/repo-map/lib/utils/cache-manager.js +159 -0
- package/plugins/repo-map/lib/utils/context-optimizer.js +300 -0
- package/plugins/repo-map/lib/utils/deprecation.js +37 -0
- package/plugins/repo-map/lib/utils/shell-escape.js +88 -0
- package/plugins/repo-map/skills/repo-mapping/SKILL.md +83 -0
- package/plugins/ship/.claude-plugin/plugin.json +21 -0
- package/plugins/ship/commands/ship-ci-review-loop.md +472 -0
- package/plugins/ship/commands/ship-deployment.md +335 -0
- package/plugins/ship/commands/ship-error-handling.md +258 -0
- package/plugins/ship/commands/ship.md +492 -0
- package/plugins/ship/lib/adapter-transforms.js +278 -0
- package/plugins/ship/lib/collectors/codebase.js +392 -0
- package/plugins/ship/lib/collectors/docs-patterns.js +713 -0
- package/plugins/ship/lib/collectors/documentation.js +219 -0
- package/plugins/ship/lib/collectors/github.js +266 -0
- package/plugins/ship/lib/collectors/index.js +126 -0
- package/plugins/ship/lib/config/index.js +14 -0
- package/plugins/ship/lib/cross-platform/index.js +539 -0
- package/plugins/ship/lib/discovery/index.js +352 -0
- package/plugins/ship/lib/drift-detect/collectors.js +37 -0
- package/plugins/ship/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/ship/lib/enhance/agent-patterns.js +571 -0
- package/plugins/ship/lib/enhance/auto-suppression.js +622 -0
- package/plugins/ship/lib/enhance/benchmark.js +417 -0
- package/plugins/ship/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/ship/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/ship/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/ship/lib/enhance/docs-patterns.js +671 -0
- package/plugins/ship/lib/enhance/fixer.js +721 -0
- package/plugins/ship/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/ship/lib/enhance/hook-patterns.js +40 -0
- package/plugins/ship/lib/enhance/index.js +127 -0
- package/plugins/ship/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/ship/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/ship/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/ship/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/ship/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/ship/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/ship/lib/enhance/reporter.js +1348 -0
- package/plugins/ship/lib/enhance/security-patterns.js +284 -0
- package/plugins/ship/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/ship/lib/enhance/skill-patterns.js +147 -0
- package/plugins/ship/lib/enhance/suppression.js +352 -0
- package/plugins/ship/lib/enhance/tool-patterns.js +373 -0
- package/plugins/ship/lib/index.js +270 -0
- package/plugins/ship/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/ship/lib/patterns/pipeline.js +948 -0
- package/plugins/ship/lib/patterns/review-patterns.js +558 -0
- package/plugins/ship/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/ship/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/ship/lib/perf/analyzer/index.js +22 -0
- package/plugins/ship/lib/perf/argument-parser.js +105 -0
- package/plugins/ship/lib/perf/baseline-comparator.js +50 -0
- package/plugins/ship/lib/perf/baseline-store.js +127 -0
- package/plugins/ship/lib/perf/benchmark-runner.js +399 -0
- package/plugins/ship/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/ship/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/ship/lib/perf/checkpoint.js +123 -0
- package/plugins/ship/lib/perf/code-paths.js +86 -0
- package/plugins/ship/lib/perf/consolidation.js +37 -0
- package/plugins/ship/lib/perf/constraint-runner.js +71 -0
- package/plugins/ship/lib/perf/experiment-runner.js +32 -0
- package/plugins/ship/lib/perf/index.js +41 -0
- package/plugins/ship/lib/perf/investigation-state.js +875 -0
- package/plugins/ship/lib/perf/optimization-runner.js +79 -0
- package/plugins/ship/lib/perf/profilers/go.js +22 -0
- package/plugins/ship/lib/perf/profilers/index.js +46 -0
- package/plugins/ship/lib/perf/profilers/java.js +23 -0
- package/plugins/ship/lib/perf/profilers/node.js +27 -0
- package/plugins/ship/lib/perf/profilers/python.js +23 -0
- package/plugins/ship/lib/perf/profilers/rust.js +23 -0
- package/plugins/ship/lib/perf/profiling-runner.js +56 -0
- package/plugins/ship/lib/perf/schemas.js +140 -0
- package/plugins/ship/lib/platform/detect-platform.js +413 -0
- package/plugins/ship/lib/platform/detection-configs.js +93 -0
- package/plugins/ship/lib/platform/state-dir.js +132 -0
- package/plugins/ship/lib/platform/verify-tools.js +182 -0
- package/plugins/ship/lib/repo-map/cache.js +152 -0
- package/plugins/ship/lib/repo-map/index.js +222 -0
- package/plugins/ship/lib/repo-map/installer.js +212 -0
- package/plugins/ship/lib/repo-map/queries/go.js +27 -0
- package/plugins/ship/lib/repo-map/queries/index.js +100 -0
- package/plugins/ship/lib/repo-map/queries/java.js +38 -0
- package/plugins/ship/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/ship/lib/repo-map/queries/python.js +24 -0
- package/plugins/ship/lib/repo-map/queries/rust.js +73 -0
- package/plugins/ship/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/ship/lib/repo-map/runner.js +1165 -0
- package/plugins/ship/lib/repo-map/updater.js +474 -0
- package/plugins/ship/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/ship/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/ship/lib/schemas/validator.js +247 -0
- package/plugins/ship/lib/sources/custom-handler.js +199 -0
- package/plugins/ship/lib/sources/policy-questions.js +246 -0
- package/plugins/ship/lib/sources/source-cache.js +165 -0
- package/plugins/ship/lib/state/workflow-state.js +575 -0
- package/plugins/ship/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/ship/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/ship/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/ship/lib/types/index.d.ts +84 -0
- package/plugins/ship/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/ship/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/ship/lib/utils/atomic-write.js +94 -0
- package/plugins/ship/lib/utils/cache-manager.js +159 -0
- package/plugins/ship/lib/utils/context-optimizer.js +300 -0
- package/plugins/ship/lib/utils/deprecation.js +37 -0
- package/plugins/ship/lib/utils/shell-escape.js +88 -0
- package/plugins/sync-docs/.claude-plugin/plugin.json +20 -0
- package/plugins/sync-docs/agents/sync-docs-agent.md +154 -0
- package/plugins/sync-docs/commands/sync-docs.md +186 -0
- package/plugins/sync-docs/lib/adapter-transforms.js +278 -0
- package/plugins/sync-docs/lib/collectors/codebase.js +392 -0
- package/plugins/sync-docs/lib/collectors/docs-patterns.js +713 -0
- package/plugins/sync-docs/lib/collectors/documentation.js +219 -0
- package/plugins/sync-docs/lib/collectors/github.js +266 -0
- package/plugins/sync-docs/lib/collectors/index.js +126 -0
- package/plugins/sync-docs/lib/config/index.js +14 -0
- package/plugins/sync-docs/lib/cross-platform/index.js +539 -0
- package/plugins/sync-docs/lib/discovery/index.js +352 -0
- package/plugins/sync-docs/lib/drift-detect/collectors.js +37 -0
- package/plugins/sync-docs/lib/enhance/agent-analyzer.js +421 -0
- package/plugins/sync-docs/lib/enhance/agent-patterns.js +571 -0
- package/plugins/sync-docs/lib/enhance/auto-suppression.js +622 -0
- package/plugins/sync-docs/lib/enhance/benchmark.js +417 -0
- package/plugins/sync-docs/lib/enhance/cross-file-analyzer.js +930 -0
- package/plugins/sync-docs/lib/enhance/cross-file-patterns.js +370 -0
- package/plugins/sync-docs/lib/enhance/docs-analyzer.js +325 -0
- package/plugins/sync-docs/lib/enhance/docs-patterns.js +671 -0
- package/plugins/sync-docs/lib/enhance/fixer.js +721 -0
- package/plugins/sync-docs/lib/enhance/hook-analyzer.js +135 -0
- package/plugins/sync-docs/lib/enhance/hook-patterns.js +40 -0
- package/plugins/sync-docs/lib/enhance/index.js +127 -0
- package/plugins/sync-docs/lib/enhance/plugin-analyzer.js +402 -0
- package/plugins/sync-docs/lib/enhance/plugin-patterns.js +326 -0
- package/plugins/sync-docs/lib/enhance/projectmemory-analyzer.js +551 -0
- package/plugins/sync-docs/lib/enhance/projectmemory-patterns.js +617 -0
- package/plugins/sync-docs/lib/enhance/prompt-analyzer.js +457 -0
- package/plugins/sync-docs/lib/enhance/prompt-patterns.js +1484 -0
- package/plugins/sync-docs/lib/enhance/reporter.js +1348 -0
- package/plugins/sync-docs/lib/enhance/security-patterns.js +284 -0
- package/plugins/sync-docs/lib/enhance/skill-analyzer.js +182 -0
- package/plugins/sync-docs/lib/enhance/skill-patterns.js +147 -0
- package/plugins/sync-docs/lib/enhance/suppression.js +352 -0
- package/plugins/sync-docs/lib/enhance/tool-patterns.js +373 -0
- package/plugins/sync-docs/lib/index.js +270 -0
- package/plugins/sync-docs/lib/patterns/cli-enhancers.js +611 -0
- package/plugins/sync-docs/lib/patterns/pipeline.js +948 -0
- package/plugins/sync-docs/lib/patterns/review-patterns.js +558 -0
- package/plugins/sync-docs/lib/patterns/slop-analyzers.js +2305 -0
- package/plugins/sync-docs/lib/patterns/slop-patterns.js +1187 -0
- package/plugins/sync-docs/lib/perf/analyzer/index.js +22 -0
- package/plugins/sync-docs/lib/perf/argument-parser.js +105 -0
- package/plugins/sync-docs/lib/perf/baseline-comparator.js +50 -0
- package/plugins/sync-docs/lib/perf/baseline-store.js +127 -0
- package/plugins/sync-docs/lib/perf/benchmark-runner.js +399 -0
- package/plugins/sync-docs/lib/perf/breaking-point-finder.js +52 -0
- package/plugins/sync-docs/lib/perf/breaking-point-runner.js +60 -0
- package/plugins/sync-docs/lib/perf/checkpoint.js +123 -0
- package/plugins/sync-docs/lib/perf/code-paths.js +86 -0
- package/plugins/sync-docs/lib/perf/consolidation.js +37 -0
- package/plugins/sync-docs/lib/perf/constraint-runner.js +71 -0
- package/plugins/sync-docs/lib/perf/experiment-runner.js +32 -0
- package/plugins/sync-docs/lib/perf/index.js +41 -0
- package/plugins/sync-docs/lib/perf/investigation-state.js +875 -0
- package/plugins/sync-docs/lib/perf/optimization-runner.js +79 -0
- package/plugins/sync-docs/lib/perf/profilers/go.js +22 -0
- package/plugins/sync-docs/lib/perf/profilers/index.js +46 -0
- package/plugins/sync-docs/lib/perf/profilers/java.js +23 -0
- package/plugins/sync-docs/lib/perf/profilers/node.js +27 -0
- package/plugins/sync-docs/lib/perf/profilers/python.js +23 -0
- package/plugins/sync-docs/lib/perf/profilers/rust.js +23 -0
- package/plugins/sync-docs/lib/perf/profiling-runner.js +56 -0
- package/plugins/sync-docs/lib/perf/schemas.js +140 -0
- package/plugins/sync-docs/lib/platform/detect-platform.js +413 -0
- package/plugins/sync-docs/lib/platform/detection-configs.js +93 -0
- package/plugins/sync-docs/lib/platform/state-dir.js +132 -0
- package/plugins/sync-docs/lib/platform/verify-tools.js +182 -0
- package/plugins/sync-docs/lib/repo-map/cache.js +152 -0
- package/plugins/sync-docs/lib/repo-map/index.js +222 -0
- package/plugins/sync-docs/lib/repo-map/installer.js +212 -0
- package/plugins/sync-docs/lib/repo-map/queries/go.js +27 -0
- package/plugins/sync-docs/lib/repo-map/queries/index.js +100 -0
- package/plugins/sync-docs/lib/repo-map/queries/java.js +38 -0
- package/plugins/sync-docs/lib/repo-map/queries/javascript.js +55 -0
- package/plugins/sync-docs/lib/repo-map/queries/python.js +24 -0
- package/plugins/sync-docs/lib/repo-map/queries/rust.js +73 -0
- package/plugins/sync-docs/lib/repo-map/queries/typescript.js +38 -0
- package/plugins/sync-docs/lib/repo-map/runner.js +1165 -0
- package/plugins/sync-docs/lib/repo-map/updater.js +474 -0
- package/plugins/sync-docs/lib/repo-map/usage-analyzer.js +407 -0
- package/plugins/sync-docs/lib/schemas/plugin-manifest.schema.json +57 -0
- package/plugins/sync-docs/lib/schemas/validator.js +247 -0
- package/plugins/sync-docs/lib/sources/custom-handler.js +199 -0
- package/plugins/sync-docs/lib/sources/policy-questions.js +246 -0
- package/plugins/sync-docs/lib/sources/source-cache.js +165 -0
- package/plugins/sync-docs/lib/state/workflow-state.js +575 -0
- package/plugins/sync-docs/lib/types/agent-frontmatter.d.ts +134 -0
- package/plugins/sync-docs/lib/types/command-frontmatter.d.ts +107 -0
- package/plugins/sync-docs/lib/types/hook-frontmatter.d.ts +115 -0
- package/plugins/sync-docs/lib/types/index.d.ts +84 -0
- package/plugins/sync-docs/lib/types/plugin-manifest.d.ts +102 -0
- package/plugins/sync-docs/lib/types/skill-frontmatter.d.ts +89 -0
- package/plugins/sync-docs/lib/utils/atomic-write.js +94 -0
- package/plugins/sync-docs/lib/utils/cache-manager.js +159 -0
- package/plugins/sync-docs/lib/utils/context-optimizer.js +300 -0
- package/plugins/sync-docs/lib/utils/deprecation.js +37 -0
- package/plugins/sync-docs/lib/utils/shell-escape.js +88 -0
- package/plugins/sync-docs/skills/sync-docs/SKILL.md +351 -0
- package/scripts/bump-version.js +92 -0
- package/scripts/check-hardcoded-paths.js +199 -0
- package/scripts/dev-install.js +493 -0
- package/scripts/expand-templates.js +269 -0
- package/scripts/gen-adapters.js +323 -0
- package/scripts/generate-docs.js +558 -0
- package/scripts/generate-plugin-list.js +20 -0
- package/scripts/migrate-opencode.js +307 -0
- package/scripts/perf/repo-map-create.js +46 -0
- package/scripts/plugins.txt +12 -0
- package/scripts/preflight.js +1263 -0
- package/scripts/scaffold.js +490 -0
- package/scripts/setup-hooks.js +169 -0
- package/scripts/stamp-version.js +175 -0
- package/scripts/test-transform.js +85 -0
- package/scripts/validate-agent-skill-compliance.js +284 -0
- package/scripts/validate-counts.js +457 -0
- package/scripts/validate-cross-platform-docs.js +550 -0
- package/scripts/validate-opencode-install.js +182 -0
- package/site/assets/css/main.css +1525 -0
- package/site/assets/css/tokens.css +493 -0
- package/site/assets/favicon.svg +23 -0
- package/site/assets/js/main.js +801 -0
- package/site/assets/logo.png +0 -0
- package/site/assets/og-image.html +163 -0
- package/site/content.json +453 -0
- package/site/index.html +698 -0
- package/site/ux-spec.md +683 -0
- package/site/version.json +5 -0
- package/templates/agent-snippets/enhance-integration-points.md +6 -0
- package/templates/agent-snippets/enhance-skill-delegation.md +18 -0
- package/templates/agent-snippets/model-choice.md +6 -0
package/bin/cli.js
ADDED
|
@@ -0,0 +1,719 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
/**
|
|
3
|
+
* AgentSys CLI installer
|
|
4
|
+
*
|
|
5
|
+
* Install: npm install -g agentsys@latest
|
|
6
|
+
* Run: agentsys
|
|
7
|
+
* Update: npm update -g agentsys
|
|
8
|
+
* Remove: npm uninstall -g agentsys && agentsys --remove
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
const { execSync } = require('child_process');
|
|
12
|
+
const fs = require('fs');
|
|
13
|
+
const path = require('path');
|
|
14
|
+
const readline = require('readline');
|
|
15
|
+
|
|
16
|
+
const VERSION = require('../package.json').version;
|
|
17
|
+
// Use the installed npm package directory as source (no git clone needed)
|
|
18
|
+
const PACKAGE_DIR = path.join(__dirname, '..');
|
|
19
|
+
const discovery = require('../lib/discovery');
|
|
20
|
+
const transforms = require('../lib/adapter-transforms');
|
|
21
|
+
|
|
22
|
+
// Valid tool names
|
|
23
|
+
const VALID_TOOLS = ['claude', 'opencode', 'codex'];
|
|
24
|
+
|
|
25
|
+
function getInstallDir() {
|
|
26
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
27
|
+
return path.join(home, '.agentsys');
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
function getClaudePluginsDir() {
|
|
31
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
32
|
+
return path.join(home, '.claude', 'plugins');
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
function getOpenCodeConfigDir() {
|
|
36
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
37
|
+
const xdgConfigHome = process.env.XDG_CONFIG_HOME;
|
|
38
|
+
if (xdgConfigHome && xdgConfigHome.trim()) {
|
|
39
|
+
return path.join(xdgConfigHome, 'opencode');
|
|
40
|
+
}
|
|
41
|
+
return path.join(home, '.config', 'opencode');
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
function getConfigPath(platform) {
|
|
45
|
+
if (platform === 'opencode') {
|
|
46
|
+
return path.join(getOpenCodeConfigDir(), 'opencode.json');
|
|
47
|
+
}
|
|
48
|
+
if (platform === 'codex') {
|
|
49
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
50
|
+
return path.join(home, '.codex', 'config.toml');
|
|
51
|
+
}
|
|
52
|
+
return null;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
function commandExists(cmd) {
|
|
56
|
+
try {
|
|
57
|
+
execSync(`${process.platform === 'win32' ? 'where' : 'which'} ${cmd}`, { stdio: 'pipe' });
|
|
58
|
+
return true;
|
|
59
|
+
} catch {
|
|
60
|
+
return false;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
function copyDirRecursive(src, dest) {
|
|
65
|
+
fs.mkdirSync(dest, { recursive: true });
|
|
66
|
+
const entries = fs.readdirSync(src, { withFileTypes: true });
|
|
67
|
+
for (const entry of entries) {
|
|
68
|
+
const srcPath = path.join(src, entry.name);
|
|
69
|
+
const destPath = path.join(dest, entry.name);
|
|
70
|
+
if (entry.isDirectory()) {
|
|
71
|
+
copyDirRecursive(srcPath, destPath);
|
|
72
|
+
} else {
|
|
73
|
+
fs.copyFileSync(srcPath, destPath);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
function parseArgs(args) {
|
|
79
|
+
const result = {
|
|
80
|
+
help: false,
|
|
81
|
+
version: false,
|
|
82
|
+
remove: false,
|
|
83
|
+
development: false,
|
|
84
|
+
stripModels: true, // Default: strip models
|
|
85
|
+
tool: null, // Single tool
|
|
86
|
+
tools: [], // Multiple tools
|
|
87
|
+
};
|
|
88
|
+
|
|
89
|
+
for (let i = 0; i < args.length; i++) {
|
|
90
|
+
const arg = args[i];
|
|
91
|
+
|
|
92
|
+
if (arg === '--help' || arg === '-h') {
|
|
93
|
+
result.help = true;
|
|
94
|
+
} else if (arg === '--version' || arg === '-v') {
|
|
95
|
+
result.version = true;
|
|
96
|
+
} else if (arg === '--remove' || arg === '--uninstall') {
|
|
97
|
+
result.remove = true;
|
|
98
|
+
} else if (arg === '--development' || arg === '--dev') {
|
|
99
|
+
result.development = true;
|
|
100
|
+
} else if (arg === '--no-strip' || arg === '-ns') {
|
|
101
|
+
result.stripModels = false;
|
|
102
|
+
} else if (arg === '--strip-models') {
|
|
103
|
+
// Legacy flag, now default behavior
|
|
104
|
+
result.stripModels = true;
|
|
105
|
+
} else if (arg === '--tool' && args[i + 1]) {
|
|
106
|
+
const tool = args[i + 1].toLowerCase();
|
|
107
|
+
if (VALID_TOOLS.includes(tool)) {
|
|
108
|
+
result.tool = tool;
|
|
109
|
+
} else {
|
|
110
|
+
console.error(`[ERROR] Invalid tool: ${tool}. Valid options: ${VALID_TOOLS.join(', ')}`);
|
|
111
|
+
process.exit(1);
|
|
112
|
+
}
|
|
113
|
+
i++;
|
|
114
|
+
} else if (arg === '--tools' && args[i + 1]) {
|
|
115
|
+
const toolList = args[i + 1].toLowerCase().split(',').map(t => t.trim());
|
|
116
|
+
for (const tool of toolList) {
|
|
117
|
+
if (!VALID_TOOLS.includes(tool)) {
|
|
118
|
+
console.error(`[ERROR] Invalid tool: ${tool}. Valid options: ${VALID_TOOLS.join(', ')}`);
|
|
119
|
+
process.exit(1);
|
|
120
|
+
}
|
|
121
|
+
result.tools.push(tool);
|
|
122
|
+
}
|
|
123
|
+
i++;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
// Environment variable override for strip models (legacy support)
|
|
128
|
+
if (['0', 'false', 'no'].includes((process.env.AGENTSYS_STRIP_MODELS || '').toLowerCase())) {
|
|
129
|
+
result.stripModels = false;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
return result;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
async function multiSelect(question, options) {
|
|
136
|
+
const rl = readline.createInterface({
|
|
137
|
+
input: process.stdin,
|
|
138
|
+
output: process.stdout
|
|
139
|
+
});
|
|
140
|
+
|
|
141
|
+
console.log(`\n${question}\n`);
|
|
142
|
+
console.log('Enter numbers separated by spaces (e.g., "1 2" or "1,2,3"), then press Enter:\n');
|
|
143
|
+
|
|
144
|
+
options.forEach((opt, i) => {
|
|
145
|
+
console.log(` ${i + 1}) ${opt.label}`);
|
|
146
|
+
});
|
|
147
|
+
|
|
148
|
+
console.log();
|
|
149
|
+
|
|
150
|
+
return new Promise((resolve) => {
|
|
151
|
+
rl.question('Your selection: ', (answer) => {
|
|
152
|
+
rl.close();
|
|
153
|
+
|
|
154
|
+
// Parse input like "1 2 3" or "1,2,3" or "1, 2, 3"
|
|
155
|
+
const nums = answer.split(/[\s,]+/).map(s => parseInt(s.trim(), 10)).filter(n => !isNaN(n));
|
|
156
|
+
|
|
157
|
+
const result = [];
|
|
158
|
+
for (const num of nums) {
|
|
159
|
+
if (num >= 1 && num <= options.length) {
|
|
160
|
+
result.push(options[num - 1].value);
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
resolve([...new Set(result)]); // Dedupe
|
|
165
|
+
});
|
|
166
|
+
});
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
function cleanOldInstallation(installDir) {
|
|
170
|
+
if (fs.existsSync(installDir)) {
|
|
171
|
+
console.log('Removing previous installation...');
|
|
172
|
+
fs.rmSync(installDir, { recursive: true, force: true });
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
function copyFromPackage(installDir) {
|
|
177
|
+
console.log('Installing AgentSys files...');
|
|
178
|
+
// Copy from npm package to ~/.agentsys
|
|
179
|
+
fs.cpSync(PACKAGE_DIR, installDir, {
|
|
180
|
+
recursive: true,
|
|
181
|
+
filter: (src) => {
|
|
182
|
+
// Skip node_modules and .git directories
|
|
183
|
+
const basename = path.basename(src);
|
|
184
|
+
return basename !== 'node_modules' && basename !== '.git';
|
|
185
|
+
}
|
|
186
|
+
});
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
function installDependencies(installDir) {
|
|
190
|
+
console.log('Installing dependencies...');
|
|
191
|
+
execSync('npm install --production', { cwd: installDir, stdio: 'inherit' });
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
function installForClaude() {
|
|
195
|
+
console.log('\n[INSTALL] Installing for Claude Code...\n');
|
|
196
|
+
|
|
197
|
+
if (!commandExists('claude')) {
|
|
198
|
+
console.log('[WARN] Claude Code CLI not detected.');
|
|
199
|
+
console.log(' Install it first: https://claude.ai/code\n');
|
|
200
|
+
console.log(' Then run in Claude Code:');
|
|
201
|
+
console.log(' /plugin marketplace add avifenesh/agentsys');
|
|
202
|
+
console.log(' /plugin install next-task@agentsys\n');
|
|
203
|
+
return false;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
try {
|
|
207
|
+
// Add GitHub marketplace
|
|
208
|
+
console.log('Adding marketplace...');
|
|
209
|
+
try {
|
|
210
|
+
execSync('claude plugin marketplace add avifenesh/agentsys', { stdio: 'pipe' });
|
|
211
|
+
} catch {
|
|
212
|
+
// May already exist
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
// Discover plugins from filesystem convention
|
|
216
|
+
const plugins = discovery.discoverPlugins(PACKAGE_DIR);
|
|
217
|
+
for (const plugin of plugins) {
|
|
218
|
+
// Validate plugin name before shell use (prevents injection)
|
|
219
|
+
if (!/^[a-z0-9][a-z0-9-]*$/.test(plugin)) continue;
|
|
220
|
+
console.log(` Installing ${plugin}...`);
|
|
221
|
+
try {
|
|
222
|
+
// Try install first
|
|
223
|
+
execSync(`claude plugin install ${plugin}@agentsys`, { stdio: 'pipe' });
|
|
224
|
+
} catch {
|
|
225
|
+
// If install fails (already installed), try update
|
|
226
|
+
try {
|
|
227
|
+
execSync(`claude plugin update ${plugin}@agentsys`, { stdio: 'pipe' });
|
|
228
|
+
} catch {
|
|
229
|
+
// Ignore if update also fails
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
console.log('\n[OK] Claude Code installation complete!\n');
|
|
235
|
+
console.log('Commands: ' + plugins.map(p => '/' + p).join(', '));
|
|
236
|
+
return true;
|
|
237
|
+
} catch (err) {
|
|
238
|
+
console.log('[ERROR] Auto-install failed. Manual installation:');
|
|
239
|
+
console.log(' /plugin marketplace add avifenesh/agentsys');
|
|
240
|
+
console.log(' /plugin install next-task@agentsys');
|
|
241
|
+
return false;
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
function installForClaudeDevelopment() {
|
|
246
|
+
console.log('\n[INSTALL] Installing for Claude Code (DEVELOPMENT MODE)...\n');
|
|
247
|
+
|
|
248
|
+
if (!commandExists('claude')) {
|
|
249
|
+
console.log('[WARN] Claude Code CLI not detected.');
|
|
250
|
+
console.log(' Install it first: https://claude.ai/code\n');
|
|
251
|
+
return false;
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
const pluginsDir = getClaudePluginsDir();
|
|
255
|
+
const plugins = discovery.discoverPlugins(PACKAGE_DIR);
|
|
256
|
+
|
|
257
|
+
// Remove marketplace plugins first
|
|
258
|
+
console.log('Removing marketplace plugins...');
|
|
259
|
+
try {
|
|
260
|
+
execSync('claude plugin marketplace remove avifenesh/agentsys', { stdio: 'pipe' });
|
|
261
|
+
console.log(' [OK] Removed marketplace');
|
|
262
|
+
} catch {
|
|
263
|
+
// May not exist
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
for (const plugin of plugins) {
|
|
267
|
+
// Validate plugin name before shell use (prevents injection)
|
|
268
|
+
if (!/^[a-z0-9][a-z0-9-]*$/.test(plugin)) continue;
|
|
269
|
+
// Uninstall both current and pre-rename plugin IDs
|
|
270
|
+
for (const suffix of ['agentsys', 'awesome-slash']) {
|
|
271
|
+
try {
|
|
272
|
+
execSync(`claude plugin uninstall ${plugin}@${suffix}`, { stdio: 'pipe' });
|
|
273
|
+
console.log(` [OK] Uninstalled ${plugin}@${suffix}`);
|
|
274
|
+
} catch {
|
|
275
|
+
// May not be installed
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
// Create plugins directory
|
|
281
|
+
fs.mkdirSync(pluginsDir, { recursive: true });
|
|
282
|
+
|
|
283
|
+
// Copy each plugin directly
|
|
284
|
+
console.log('\nCopying plugins from package...');
|
|
285
|
+
for (const plugin of plugins) {
|
|
286
|
+
const srcDir = path.join(PACKAGE_DIR, 'plugins', plugin);
|
|
287
|
+
const destDir = path.join(pluginsDir, `${plugin}@agentsys`);
|
|
288
|
+
|
|
289
|
+
if (fs.existsSync(srcDir)) {
|
|
290
|
+
// Remove existing
|
|
291
|
+
if (fs.existsSync(destDir)) {
|
|
292
|
+
fs.rmSync(destDir, { recursive: true, force: true });
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
// Copy plugin
|
|
296
|
+
fs.cpSync(srcDir, destDir, {
|
|
297
|
+
recursive: true,
|
|
298
|
+
filter: (src) => {
|
|
299
|
+
const basename = path.basename(src);
|
|
300
|
+
return basename !== 'node_modules' && basename !== '.git';
|
|
301
|
+
}
|
|
302
|
+
});
|
|
303
|
+
console.log(` [OK] Installed ${plugin}`);
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
console.log('\n[OK] Claude Code development installation complete!');
|
|
308
|
+
console.log(' Plugins installed to: ' + pluginsDir);
|
|
309
|
+
console.log(' Commands: ' + plugins.map(p => '/' + p).join(', '));
|
|
310
|
+
console.log('\n[NOTE] To revert to marketplace version:');
|
|
311
|
+
console.log(' rm -rf ~/.claude/plugins/*@agentsys');
|
|
312
|
+
console.log(' agentsys --tool claude');
|
|
313
|
+
return true;
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
function installForOpenCode(installDir, options = {}) {
|
|
317
|
+
console.log('\n[INSTALL] Installing for OpenCode...\n');
|
|
318
|
+
const { stripModels = true } = options;
|
|
319
|
+
|
|
320
|
+
if (stripModels) {
|
|
321
|
+
console.log(' [INFO] Model specifications stripped (default). Use --no-strip to include.');
|
|
322
|
+
} else {
|
|
323
|
+
console.log(' [INFO] Model specifications included (--no-strip).');
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
327
|
+
const opencodeConfigDir = getOpenCodeConfigDir();
|
|
328
|
+
// OpenCode global locations are under ~/.config/opencode (or $XDG_CONFIG_HOME/opencode).
|
|
329
|
+
const commandsDir = path.join(opencodeConfigDir, 'commands');
|
|
330
|
+
const pluginDir = path.join(opencodeConfigDir, 'plugins');
|
|
331
|
+
|
|
332
|
+
fs.mkdirSync(commandsDir, { recursive: true });
|
|
333
|
+
fs.mkdirSync(pluginDir, { recursive: true });
|
|
334
|
+
|
|
335
|
+
// Install native OpenCode plugin (auto-thinking, workflow enforcement, compaction)
|
|
336
|
+
const pluginSrcDir = path.join(installDir, 'adapters', 'opencode-plugin');
|
|
337
|
+
if (fs.existsSync(pluginSrcDir)) {
|
|
338
|
+
// OpenCode loads plugin files directly from the plugins directory.
|
|
339
|
+
const srcPath = path.join(pluginSrcDir, 'index.ts');
|
|
340
|
+
const destPath = path.join(pluginDir, 'agentsys.ts');
|
|
341
|
+
// Remove legacy plugin file from pre-rename installs to prevent dual loading
|
|
342
|
+
const legacyPluginFile = path.join(pluginDir, 'awesome-slash.ts');
|
|
343
|
+
if (fs.existsSync(legacyPluginFile)) {
|
|
344
|
+
fs.unlinkSync(legacyPluginFile);
|
|
345
|
+
}
|
|
346
|
+
if (fs.existsSync(srcPath)) {
|
|
347
|
+
fs.copyFileSync(srcPath, destPath);
|
|
348
|
+
console.log(' [OK] Installed native plugin (auto-thinking, workflow enforcement)');
|
|
349
|
+
}
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
// Clean up the legacy (pre-XDG) install location if it exists.
|
|
353
|
+
// This location is not used by OpenCode and was used by older versions.
|
|
354
|
+
const legacyCommandsDir = path.join(home, '.opencode', 'commands', 'agentsys');
|
|
355
|
+
if (fs.existsSync(legacyCommandsDir)) {
|
|
356
|
+
fs.rmSync(legacyCommandsDir, { recursive: true, force: true });
|
|
357
|
+
}
|
|
358
|
+
const legacyPluginDir = path.join(home, '.opencode', 'plugins', 'agentsys');
|
|
359
|
+
if (fs.existsSync(legacyPluginDir)) {
|
|
360
|
+
fs.rmSync(legacyPluginDir, { recursive: true, force: true });
|
|
361
|
+
}
|
|
362
|
+
// Also clean pre-rename paths (awesome-slash) for users upgrading from v4.x
|
|
363
|
+
const preRenameCommandsDir = path.join(home, '.opencode', 'commands', 'awesome-slash');
|
|
364
|
+
if (fs.existsSync(preRenameCommandsDir)) {
|
|
365
|
+
fs.rmSync(preRenameCommandsDir, { recursive: true, force: true });
|
|
366
|
+
}
|
|
367
|
+
const preRenamePluginDir = path.join(home, '.opencode', 'plugins', 'awesome-slash');
|
|
368
|
+
if (fs.existsSync(preRenamePluginDir)) {
|
|
369
|
+
fs.rmSync(preRenamePluginDir, { recursive: true, force: true });
|
|
370
|
+
}
|
|
371
|
+
|
|
372
|
+
// Discover command mappings from filesystem
|
|
373
|
+
const commandMappings = discovery.getCommandMappings(installDir);
|
|
374
|
+
|
|
375
|
+
// Transform and copy command files
|
|
376
|
+
for (const [target, plugin, source] of commandMappings) {
|
|
377
|
+
const srcPath = path.join(installDir, 'plugins', plugin, 'commands', source);
|
|
378
|
+
const destPath = path.join(commandsDir, target);
|
|
379
|
+
if (fs.existsSync(srcPath)) {
|
|
380
|
+
let content = fs.readFileSync(srcPath, 'utf8');
|
|
381
|
+
content = transforms.transformBodyForOpenCode(content, installDir);
|
|
382
|
+
content = transforms.transformCommandFrontmatterForOpenCode(content);
|
|
383
|
+
fs.writeFileSync(destPath, content);
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
|
|
387
|
+
// Install agents to global OpenCode location
|
|
388
|
+
// OpenCode looks for agents in ~/.config/opencode/agents/ (global) or .opencode/agents/ (per-project)
|
|
389
|
+
const agentsDir = path.join(opencodeConfigDir, 'agents');
|
|
390
|
+
fs.mkdirSync(agentsDir, { recursive: true });
|
|
391
|
+
|
|
392
|
+
console.log(' Installing agents for OpenCode...');
|
|
393
|
+
const pluginDirs = discovery.discoverPlugins(installDir);
|
|
394
|
+
let agentCount = 0;
|
|
395
|
+
|
|
396
|
+
for (const pluginName of pluginDirs) {
|
|
397
|
+
const srcAgentsDir = path.join(installDir, 'plugins', pluginName, 'agents');
|
|
398
|
+
if (fs.existsSync(srcAgentsDir)) {
|
|
399
|
+
const agentFiles = fs.readdirSync(srcAgentsDir).filter(f => f.endsWith('.md'));
|
|
400
|
+
for (const agentFile of agentFiles) {
|
|
401
|
+
const srcPath = path.join(srcAgentsDir, agentFile);
|
|
402
|
+
const destPath = path.join(agentsDir, agentFile);
|
|
403
|
+
let content = fs.readFileSync(srcPath, 'utf8');
|
|
404
|
+
|
|
405
|
+
// Transform body and frontmatter for OpenCode
|
|
406
|
+
content = transforms.transformBodyForOpenCode(content, installDir);
|
|
407
|
+
content = transforms.transformAgentFrontmatterForOpenCode(content, { stripModels });
|
|
408
|
+
|
|
409
|
+
fs.writeFileSync(destPath, content);
|
|
410
|
+
agentCount++;
|
|
411
|
+
}
|
|
412
|
+
}
|
|
413
|
+
}
|
|
414
|
+
console.log(` [OK] Installed ${agentCount} agents to ${agentsDir}`);
|
|
415
|
+
|
|
416
|
+
// Copy lib files to commands directory for require() access
|
|
417
|
+
const libSrcDir = path.join(installDir, 'lib');
|
|
418
|
+
const libDestDir = path.join(commandsDir, 'lib');
|
|
419
|
+
if (fs.existsSync(libSrcDir)) {
|
|
420
|
+
console.log(' Installing lib files...');
|
|
421
|
+
copyDirRecursive(libSrcDir, libDestDir);
|
|
422
|
+
console.log(` [OK] Installed lib to ${libDestDir}`);
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
// Install skills to the OpenCode global skills directory (~/.config/opencode/skills/<skill-name>/SKILL.md)
|
|
426
|
+
const skillsDestDir = path.join(opencodeConfigDir, 'skills');
|
|
427
|
+
fs.mkdirSync(skillsDestDir, { recursive: true });
|
|
428
|
+
console.log(' Installing skills...');
|
|
429
|
+
let skillCount = 0;
|
|
430
|
+
|
|
431
|
+
for (const pluginName of pluginDirs) {
|
|
432
|
+
const srcSkillsDir = path.join(installDir, 'plugins', pluginName, 'skills');
|
|
433
|
+
if (fs.existsSync(srcSkillsDir)) {
|
|
434
|
+
const skillDirs = fs.readdirSync(srcSkillsDir, { withFileTypes: true })
|
|
435
|
+
.filter(d => d.isDirectory());
|
|
436
|
+
for (const skillDir of skillDirs) {
|
|
437
|
+
const skillName = skillDir.name;
|
|
438
|
+
const srcSkillPath = path.join(srcSkillsDir, skillName, 'SKILL.md');
|
|
439
|
+
if (fs.existsSync(srcSkillPath)) {
|
|
440
|
+
const destSkillDir = path.join(skillsDestDir, skillName);
|
|
441
|
+
fs.mkdirSync(destSkillDir, { recursive: true });
|
|
442
|
+
let content = fs.readFileSync(srcSkillPath, 'utf8');
|
|
443
|
+
content = transforms.transformSkillBodyForOpenCode(content, installDir);
|
|
444
|
+
fs.writeFileSync(path.join(destSkillDir, 'SKILL.md'), content);
|
|
445
|
+
skillCount++;
|
|
446
|
+
}
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
}
|
|
450
|
+
console.log(` [OK] Installed ${skillCount} skills to ${skillsDestDir}`);
|
|
451
|
+
|
|
452
|
+
console.log('[OK] OpenCode installation complete!');
|
|
453
|
+
console.log(` Commands: ${commandsDir}`);
|
|
454
|
+
console.log(` Agents: ${agentsDir}`);
|
|
455
|
+
console.log(` Plugin: ${pluginDir}`);
|
|
456
|
+
console.log(' Access via: ' + commandMappings.map(([target]) => '/' + target.replace(/\.md$/, '')).join(', '));
|
|
457
|
+
console.log(' Native features: Auto-thinking selection, workflow enforcement, session compaction\n');
|
|
458
|
+
return true;
|
|
459
|
+
}
|
|
460
|
+
|
|
461
|
+
function installForCodex(installDir) {
|
|
462
|
+
console.log('\n[INSTALL] Installing for Codex CLI...\n');
|
|
463
|
+
|
|
464
|
+
const home = process.env.HOME || process.env.USERPROFILE;
|
|
465
|
+
const configDir = path.join(home, '.codex');
|
|
466
|
+
const skillsDir = path.join(configDir, 'skills');
|
|
467
|
+
|
|
468
|
+
fs.mkdirSync(configDir, { recursive: true });
|
|
469
|
+
fs.mkdirSync(skillsDir, { recursive: true });
|
|
470
|
+
|
|
471
|
+
// Remove old/deprecated prompts directory if it exists
|
|
472
|
+
const oldPromptsDir = path.join(configDir, 'prompts');
|
|
473
|
+
if (fs.existsSync(oldPromptsDir)) {
|
|
474
|
+
const oldFiles = ['next-task.md', 'ship.md', 'deslop.md', 'audit-project.md',
|
|
475
|
+
'drift-detect.md', 'delivery-approval.md', 'sync-docs.md',
|
|
476
|
+
'drift-detect-set.md', 'pr-merge.md'];
|
|
477
|
+
for (const file of oldFiles) {
|
|
478
|
+
const oldPath = path.join(oldPromptsDir, file);
|
|
479
|
+
if (fs.existsSync(oldPath)) {
|
|
480
|
+
fs.unlinkSync(oldPath);
|
|
481
|
+
console.log(` Removed old prompt: ${file}`);
|
|
482
|
+
}
|
|
483
|
+
}
|
|
484
|
+
}
|
|
485
|
+
|
|
486
|
+
// Remove old/deprecated skills
|
|
487
|
+
const oldSkillDirs = ['deslop', 'review', 'drift-detect-set', 'pr-merge'];
|
|
488
|
+
for (const dir of oldSkillDirs) {
|
|
489
|
+
const oldPath = path.join(skillsDir, dir);
|
|
490
|
+
if (fs.existsSync(oldPath)) {
|
|
491
|
+
fs.rmSync(oldPath, { recursive: true, force: true });
|
|
492
|
+
console.log(` Removed deprecated skill: ${dir}`);
|
|
493
|
+
}
|
|
494
|
+
}
|
|
495
|
+
|
|
496
|
+
// Discover skill mappings from filesystem (descriptions from codex-description frontmatter)
|
|
497
|
+
const skillMappings = discovery.getCodexSkillMappings(installDir);
|
|
498
|
+
|
|
499
|
+
for (const [skillName, plugin, sourceFile, description] of skillMappings) {
|
|
500
|
+
if (!description) {
|
|
501
|
+
console.log(` [WARN] Skipping skill ${skillName}: missing description`);
|
|
502
|
+
continue;
|
|
503
|
+
}
|
|
504
|
+
const srcPath = path.join(installDir, 'plugins', plugin, 'commands', sourceFile);
|
|
505
|
+
const skillDir = path.join(skillsDir, skillName);
|
|
506
|
+
const destPath = path.join(skillDir, 'SKILL.md');
|
|
507
|
+
|
|
508
|
+
if (fs.existsSync(srcPath)) {
|
|
509
|
+
if (fs.existsSync(skillDir)) {
|
|
510
|
+
fs.rmSync(skillDir, { recursive: true, force: true });
|
|
511
|
+
}
|
|
512
|
+
// Create skill directory
|
|
513
|
+
fs.mkdirSync(skillDir, { recursive: true });
|
|
514
|
+
|
|
515
|
+
// Read source file and transform using shared transforms
|
|
516
|
+
let content = fs.readFileSync(srcPath, 'utf8');
|
|
517
|
+
const pluginInstallPath = path.join(installDir, 'plugins', plugin);
|
|
518
|
+
content = transforms.transformForCodex(content, {
|
|
519
|
+
skillName,
|
|
520
|
+
description,
|
|
521
|
+
pluginInstallPath
|
|
522
|
+
});
|
|
523
|
+
|
|
524
|
+
fs.writeFileSync(destPath, content);
|
|
525
|
+
console.log(` [OK] Installed skill: ${skillName}`);
|
|
526
|
+
}
|
|
527
|
+
}
|
|
528
|
+
|
|
529
|
+
console.log('\n[OK] Codex CLI installation complete!');
|
|
530
|
+
console.log(` Config: ${configDir}`);
|
|
531
|
+
console.log(` Skills: ${skillsDir}`);
|
|
532
|
+
console.log(' Access via: $next-task, $ship, $deslop, etc.\n');
|
|
533
|
+
return true;
|
|
534
|
+
}
|
|
535
|
+
|
|
536
|
+
function removeInstallation() {
|
|
537
|
+
const installDir = getInstallDir();
|
|
538
|
+
|
|
539
|
+
if (!fs.existsSync(installDir)) {
|
|
540
|
+
console.log('Nothing to remove. agentsys is not installed.');
|
|
541
|
+
return;
|
|
542
|
+
}
|
|
543
|
+
|
|
544
|
+
console.log('Removing agentsys...');
|
|
545
|
+
fs.rmSync(installDir, { recursive: true, force: true });
|
|
546
|
+
|
|
547
|
+
console.log('\n[OK] Removed ~/.agentsys');
|
|
548
|
+
console.log('\nTo fully uninstall, also remove:');
|
|
549
|
+
console.log(' - Claude: /plugin marketplace remove agentsys');
|
|
550
|
+
console.log(' - OpenCode: Remove files under ~/.config/opencode/ (commands/*.md, agents/*.md, skills/*/SKILL.md) and ~/.config/opencode/plugins/agentsys.ts');
|
|
551
|
+
console.log(' - Codex: Remove ~/.codex/skills/*/');
|
|
552
|
+
}
|
|
553
|
+
|
|
554
|
+
function printHelp() {
|
|
555
|
+
console.log(`
|
|
556
|
+
agentsys v${VERSION} - Workflow automation for AI coding assistants
|
|
557
|
+
|
|
558
|
+
Usage:
|
|
559
|
+
agentsys Interactive installer (select platforms)
|
|
560
|
+
agentsys --tool <name> Install for single tool (claude, opencode, codex)
|
|
561
|
+
agentsys --tools <list> Install for multiple tools (comma-separated)
|
|
562
|
+
agentsys --development Development mode: install to ~/.claude/plugins
|
|
563
|
+
agentsys --no-strip, -ns Include model specifications (stripped by default)
|
|
564
|
+
agentsys --remove Remove local installation
|
|
565
|
+
agentsys --version, -v Show version
|
|
566
|
+
agentsys --help, -h Show this help
|
|
567
|
+
|
|
568
|
+
Non-Interactive Examples:
|
|
569
|
+
agentsys --tool claude # Install for Claude Code only
|
|
570
|
+
agentsys --tool opencode # Install for OpenCode only
|
|
571
|
+
agentsys --tools "claude,opencode" # Install for both
|
|
572
|
+
agentsys --tools claude,opencode,codex # Install for all three
|
|
573
|
+
|
|
574
|
+
Development Mode:
|
|
575
|
+
agentsys --development # Install plugins directly to ~/.claude/plugins
|
|
576
|
+
# Bypasses marketplace for testing RC versions
|
|
577
|
+
|
|
578
|
+
Model Handling:
|
|
579
|
+
By default, model specifications (sonnet/opus/haiku) are stripped from agents
|
|
580
|
+
when installing for OpenCode. This is because most users don't have the
|
|
581
|
+
required model mappings configured. Use --no-strip or -ns to include models.
|
|
582
|
+
|
|
583
|
+
Environment Variables:
|
|
584
|
+
AGENTSYS_STRIP_MODELS=0 Same as --no-strip
|
|
585
|
+
|
|
586
|
+
Supported Platforms:
|
|
587
|
+
claude - Claude Code (marketplace install or development mode)
|
|
588
|
+
opencode - OpenCode (local commands + native plugin)
|
|
589
|
+
codex - Codex CLI (local skills)
|
|
590
|
+
|
|
591
|
+
Install: npm install -g agentsys && agentsys
|
|
592
|
+
Update: npm update -g agentsys && agentsys
|
|
593
|
+
Remove: npm uninstall -g agentsys && agentsys --remove
|
|
594
|
+
|
|
595
|
+
Docs: https://github.com/avifenesh/agentsys
|
|
596
|
+
`);
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
async function main() {
|
|
600
|
+
const args = parseArgs(process.argv.slice(2));
|
|
601
|
+
|
|
602
|
+
// Handle --remove / --uninstall
|
|
603
|
+
if (args.remove) {
|
|
604
|
+
removeInstallation();
|
|
605
|
+
return;
|
|
606
|
+
}
|
|
607
|
+
|
|
608
|
+
// Handle --version
|
|
609
|
+
if (args.version) {
|
|
610
|
+
console.log(`agentsys v${VERSION}`);
|
|
611
|
+
return;
|
|
612
|
+
}
|
|
613
|
+
|
|
614
|
+
// Handle --help
|
|
615
|
+
if (args.help) {
|
|
616
|
+
printHelp();
|
|
617
|
+
return;
|
|
618
|
+
}
|
|
619
|
+
|
|
620
|
+
// Determine which tools to install
|
|
621
|
+
let selected = [];
|
|
622
|
+
|
|
623
|
+
if (args.tool) {
|
|
624
|
+
// Single tool specified
|
|
625
|
+
selected = [args.tool];
|
|
626
|
+
} else if (args.tools.length > 0) {
|
|
627
|
+
// Multiple tools specified
|
|
628
|
+
selected = args.tools;
|
|
629
|
+
}
|
|
630
|
+
|
|
631
|
+
// If no tools specified via flags, show interactive prompt
|
|
632
|
+
if (selected.length === 0) {
|
|
633
|
+
const title = `agentsys v${VERSION}`;
|
|
634
|
+
const subtitle = 'Workflow automation for AI assistants';
|
|
635
|
+
const width = Math.max(title.length, subtitle.length) + 6;
|
|
636
|
+
const pad = (str) => {
|
|
637
|
+
const left = Math.floor((width - str.length) / 2);
|
|
638
|
+
const right = width - str.length - left;
|
|
639
|
+
return ' '.repeat(left) + str + ' '.repeat(right);
|
|
640
|
+
};
|
|
641
|
+
|
|
642
|
+
console.log(`
|
|
643
|
+
┌${'─'.repeat(width)}┐
|
|
644
|
+
│${pad(title)}│
|
|
645
|
+
│${' '.repeat(width)}│
|
|
646
|
+
│${pad(subtitle)}│
|
|
647
|
+
└${'─'.repeat(width)}┘
|
|
648
|
+
`);
|
|
649
|
+
|
|
650
|
+
// Multi-select platforms
|
|
651
|
+
const options = [
|
|
652
|
+
{ value: 'claude', label: 'Claude Code' },
|
|
653
|
+
{ value: 'opencode', label: 'OpenCode' },
|
|
654
|
+
{ value: 'codex', label: 'Codex CLI' }
|
|
655
|
+
];
|
|
656
|
+
|
|
657
|
+
selected = await multiSelect(
|
|
658
|
+
'Which platforms do you want to install for?',
|
|
659
|
+
options
|
|
660
|
+
);
|
|
661
|
+
|
|
662
|
+
if (selected.length === 0) {
|
|
663
|
+
console.log('\nNo platforms selected. Exiting.');
|
|
664
|
+
console.log('\nFor Claude Code, you can also install directly:');
|
|
665
|
+
console.log(' /plugin marketplace add avifenesh/agentsys');
|
|
666
|
+
process.exit(0);
|
|
667
|
+
}
|
|
668
|
+
}
|
|
669
|
+
|
|
670
|
+
console.log(`\nInstalling for: ${selected.join(', ')}\n`);
|
|
671
|
+
|
|
672
|
+
// Only copy to ~/.agentsys if OpenCode or Codex selected (they need local files)
|
|
673
|
+
const needsLocalInstall = selected.includes('opencode') || selected.includes('codex');
|
|
674
|
+
let installDir = null;
|
|
675
|
+
|
|
676
|
+
if (needsLocalInstall) {
|
|
677
|
+
installDir = getInstallDir();
|
|
678
|
+
cleanOldInstallation(installDir);
|
|
679
|
+
copyFromPackage(installDir);
|
|
680
|
+
installDependencies(installDir);
|
|
681
|
+
}
|
|
682
|
+
|
|
683
|
+
// Install for each platform
|
|
684
|
+
for (const platform of selected) {
|
|
685
|
+
switch (platform) {
|
|
686
|
+
case 'claude':
|
|
687
|
+
if (args.development) {
|
|
688
|
+
installForClaudeDevelopment();
|
|
689
|
+
} else {
|
|
690
|
+
installForClaude();
|
|
691
|
+
}
|
|
692
|
+
break;
|
|
693
|
+
case 'opencode':
|
|
694
|
+
installForOpenCode(installDir, { stripModels: args.stripModels });
|
|
695
|
+
break;
|
|
696
|
+
case 'codex':
|
|
697
|
+
installForCodex(installDir);
|
|
698
|
+
break;
|
|
699
|
+
}
|
|
700
|
+
}
|
|
701
|
+
|
|
702
|
+
console.log('─'.repeat(45));
|
|
703
|
+
if (installDir) {
|
|
704
|
+
console.log(`\nInstallation directory: ${installDir}`);
|
|
705
|
+
}
|
|
706
|
+
console.log('\nTo update: npm update -g agentsys');
|
|
707
|
+
console.log('To remove: npm uninstall -g agentsys && agentsys --remove');
|
|
708
|
+
console.log('\nDocs: https://github.com/avifenesh/agentsys');
|
|
709
|
+
}
|
|
710
|
+
|
|
711
|
+
// Export for testing when required as module
|
|
712
|
+
if (require.main === module) {
|
|
713
|
+
main().catch(err => {
|
|
714
|
+
console.error('Error:', err.message);
|
|
715
|
+
process.exit(1);
|
|
716
|
+
});
|
|
717
|
+
}
|
|
718
|
+
|
|
719
|
+
module.exports = { parseArgs, VALID_TOOLS };
|