claude-autopm 2.8.9 β 2.11.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/autopm/.claude/agents-compressed-example.md +218 -0
- package/autopm/.claude/quick-ref/agent-quick-ref.md +153 -0
- package/autopm/.claude/quick-ref/common-patterns.md +215 -0
- package/autopm/.claude/quick-ref/context7-queries.md +122 -0
- package/autopm/.claude/quick-ref/tdd-cycle.md +49 -0
- package/autopm/.claude/quick-ref/workflow-steps.md +103 -0
- package/autopm/.claude/rules/agent-mandatory-optimized.md +91 -0
- package/autopm/.claude/rules/context7-enforcement-optimized.md +221 -0
- package/autopm/.claude/templates/claude-templates/addons/task-workflow.md +612 -0
- package/autopm/.claude/templates/claude-templates/base-optimized.md +245 -0
- package/autopm/.claude/templates/claude-templates/base.md +66 -14
- package/autopm/.claude/templates/plugin-manifest-template.xml +36 -0
- package/bin/commands/plugin.js +126 -1
- package/install/install.js +4 -0
- package/install/plugin-manifest-generator.js +182 -0
- package/lib/plugins/PluginManager.js +131 -0
- package/package.json +1 -1
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
# CLAUDE.md (Optimized - Token Efficient)
|
|
2
|
+
|
|
3
|
+
<system>
|
|
4
|
+
<role>Senior AI-assisted developer coordinating specialized agents</role>
|
|
5
|
+
<mandate>Build quality software through TDD, agent coordination, and Context7 integration</mandate>
|
|
6
|
+
</system>
|
|
7
|
+
|
|
8
|
+
## π¨ CRITICAL PRIORITIES
|
|
9
|
+
|
|
10
|
+
<priorities>
|
|
11
|
+
1. TDD: REDβGREENβREFACTOR (ZERO TOLERANCE)
|
|
12
|
+
2. Agents: Use specialized agents for ALL non-trivial tasks
|
|
13
|
+
3. Context7: Query docs BEFORE implementing
|
|
14
|
+
4. Quality: No partial implementations, no code without tests
|
|
15
|
+
</priorities>
|
|
16
|
+
|
|
17
|
+
## π SYSTEM MANIFEST
|
|
18
|
+
|
|
19
|
+
<manifest>
|
|
20
|
+
<rules_dir>.claude/rules/</rules_dir>
|
|
21
|
+
<agents_dir>.claude/agents/</agents_dir>
|
|
22
|
+
<quick_ref>.claude/quick-ref/</quick_ref>
|
|
23
|
+
<workflows>.claude/workflows/</workflows>
|
|
24
|
+
<commands>.claude/commands/</commands>
|
|
25
|
+
<plugins_dir>.claude/plugins/</plugins_dir>
|
|
26
|
+
</manifest>
|
|
27
|
+
|
|
28
|
+
<!-- PLUGINS_SECTION -->
|
|
29
|
+
<!-- Plugin manifests injected here during installation -->
|
|
30
|
+
<!-- Default: Empty (no plugins installed) -->
|
|
31
|
+
<!-- After installation with plugins: Compressed plugin listings -->
|
|
32
|
+
<!-- Example tokens: ~50 per plugin, ~200 for 4 plugins vs ~25,000 old system -->
|
|
33
|
+
<!-- /PLUGINS_SECTION -->
|
|
34
|
+
|
|
35
|
+
## π― QUICK REFERENCE
|
|
36
|
+
|
|
37
|
+
<quick_ref>
|
|
38
|
+
<tdd>
|
|
39
|
+
π Full: .claude/rules/tdd.enforcement.md
|
|
40
|
+
π΄ RED: Write failing test FIRST
|
|
41
|
+
β
GREEN: Minimal code to pass
|
|
42
|
+
β»οΈ REFACTOR: Improve while tests stay green
|
|
43
|
+
</tdd>
|
|
44
|
+
|
|
45
|
+
<agents>
|
|
46
|
+
π Registry: .claude/agents/AGENT-REGISTRY.md
|
|
47
|
+
π Python: @python-backend-engineer
|
|
48
|
+
βοΈ React: @react-frontend-engineer
|
|
49
|
+
π§ͺ Tests: @test-runner
|
|
50
|
+
π Analysis: @code-analyzer
|
|
51
|
+
π Files: @file-analyzer
|
|
52
|
+
</agents>
|
|
53
|
+
|
|
54
|
+
<workflow>
|
|
55
|
+
π Full: .claude/workflows/standard-task-workflow.md
|
|
56
|
+
1οΈβ£ Pick task from backlog
|
|
57
|
+
2οΈβ£ Create feature branch
|
|
58
|
+
3οΈβ£ Implement (TDD cycle)
|
|
59
|
+
4οΈβ£ Verify acceptance criteria
|
|
60
|
+
5οΈβ£ Create PR
|
|
61
|
+
6οΈβ£ Address feedback
|
|
62
|
+
7οΈβ£ Merge & complete
|
|
63
|
+
</workflow>
|
|
64
|
+
</quick_ref>
|
|
65
|
+
|
|
66
|
+
## π LAZY LOADING RULES
|
|
67
|
+
|
|
68
|
+
<lazy_load>
|
|
69
|
+
<rule>
|
|
70
|
+
Load full documentation on-demand:
|
|
71
|
+
- Read .claude/rules/*.md when rule enforcement needed
|
|
72
|
+
- Read .claude/agents/[agent].md when agent invoked
|
|
73
|
+
- Read .claude/workflows/*.md progressively as steps execute
|
|
74
|
+
</rule>
|
|
75
|
+
|
|
76
|
+
<triggers>
|
|
77
|
+
Keyword β File mapping:
|
|
78
|
+
- "TDD"|"test" β .claude/quick-ref/tdd-cycle.md
|
|
79
|
+
- "@[agent]" β .claude/agents/[category]/[agent].md
|
|
80
|
+
- "workflow"|"task" β .claude/quick-ref/workflow-steps.md
|
|
81
|
+
- "Context7" β .claude/quick-ref/context7-queries.md
|
|
82
|
+
</triggers>
|
|
83
|
+
</lazy_load>
|
|
84
|
+
|
|
85
|
+
## π CORE RULES (Compressed)
|
|
86
|
+
|
|
87
|
+
<rules>
|
|
88
|
+
<rule id="tdd" priority="HIGHEST">
|
|
89
|
+
TDD mandatory|No code before tests|REDβGREENβREFACTOR
|
|
90
|
+
π Optimized: .claude/rules/tdd.enforcement-optimized.md
|
|
91
|
+
π Full: .claude/rules/tdd.enforcement.md
|
|
92
|
+
</rule>
|
|
93
|
+
|
|
94
|
+
<rule id="agents" priority="HIGHEST">
|
|
95
|
+
Use agents for non-trivial tasks|Agent list: AGENT-REGISTRY.md
|
|
96
|
+
π Optimized: .claude/rules/agent-mandatory-optimized.md
|
|
97
|
+
π Full: .claude/rules/agent-mandatory.md
|
|
98
|
+
</rule>
|
|
99
|
+
|
|
100
|
+
<rule id="context7" priority="HIGHEST">
|
|
101
|
+
Query Context7 before implementing|mcp://context7/[lib]/[topic]
|
|
102
|
+
π Optimized: .claude/rules/context7-enforcement-optimized.md
|
|
103
|
+
π Full: .claude/rules/context7-enforcement.md
|
|
104
|
+
</rule>
|
|
105
|
+
|
|
106
|
+
<rule id="quality" priority="HIGH">
|
|
107
|
+
No partial implementations|No TODOs without tests|100% coverage for new code
|
|
108
|
+
π .claude/rules/naming-conventions.md
|
|
109
|
+
</rule>
|
|
110
|
+
|
|
111
|
+
<rule id="git" priority="MEDIUM">
|
|
112
|
+
Work in branches|PRs required|Resolve conflicts immediately
|
|
113
|
+
π .claude/rules/git-strategy.md
|
|
114
|
+
</rule>
|
|
115
|
+
</rules>
|
|
116
|
+
|
|
117
|
+
## π€ ACTIVE AGENTS (Compressed)
|
|
118
|
+
|
|
119
|
+
<!-- AGENTS_START -->
|
|
120
|
+
<agents_list>
|
|
121
|
+
Core: agent-manager|code-analyzer|file-analyzer|test-runner
|
|
122
|
+
Languages: bash-scripting-expert|javascript-frontend-engineer|nodejs-backend-engineer|python-backend-engineer
|
|
123
|
+
Frameworks: react-frontend-engineer|react-ui-expert
|
|
124
|
+
Testing: e2e-test-engineer|frontend-testing-engineer
|
|
125
|
+
Cloud: aws-cloud-architect|azure-cloud-architect|gcp-cloud-architect
|
|
126
|
+
DevOps: docker-containerization-expert|github-operations-specialist|kubernetes-orchestrator
|
|
127
|
+
Database: bigquery-expert|cosmosdb-expert|mongodb-expert|postgresql-expert|redis-expert
|
|
128
|
+
Data: airflow-orchestration-expert|kedro-pipeline-expert
|
|
129
|
+
Messaging: nats-messaging-expert|message-queue-engineer
|
|
130
|
+
Integration: azure-devops-specialist|gemini-api-expert|openai-python-expert
|
|
131
|
+
Infrastructure: gcp-cloud-functions-engineer|terraform-infrastructure-expert|traefik-proxy-expert
|
|
132
|
+
Monitoring: observability-engineer
|
|
133
|
+
Security: ssh-operations-expert
|
|
134
|
+
Design: ux-design-expert|tailwindcss-expert
|
|
135
|
+
CSS: tailwindcss-expert
|
|
136
|
+
Workflow: langgraph-workflow-expert|parallel-worker
|
|
137
|
+
Management: agent-manager|mcp-manager
|
|
138
|
+
Context: mcp-context-manager
|
|
139
|
+
|
|
140
|
+
π Full registry: .claude/agents/AGENT-REGISTRY.md
|
|
141
|
+
</agents_list>
|
|
142
|
+
<!-- AGENTS_END -->
|
|
143
|
+
|
|
144
|
+
<!-- WORKFLOW_SECTION -->
|
|
145
|
+
|
|
146
|
+
<!-- CICD_SECTION -->
|
|
147
|
+
|
|
148
|
+
## β‘ PERFORMANCE OPTIMIZATIONS
|
|
149
|
+
|
|
150
|
+
<performance>
|
|
151
|
+
<token_efficiency>
|
|
152
|
+
- Load files on-demand, not upfront
|
|
153
|
+
- Use compressed formats (pipe-separated lists)
|
|
154
|
+
- Reference external files instead of embedding
|
|
155
|
+
- Progressive workflow loading
|
|
156
|
+
</token_efficiency>
|
|
157
|
+
|
|
158
|
+
<context_preservation>
|
|
159
|
+
- Agent responses: <20% of input data
|
|
160
|
+
- File analysis: Summary only, not full content
|
|
161
|
+
- Test output: Failures only, not all results
|
|
162
|
+
- Log analysis: Errors + patterns, not raw logs
|
|
163
|
+
</context_preservation>
|
|
164
|
+
</performance>
|
|
165
|
+
|
|
166
|
+
## π― WHEN TO LOAD FULL DOCUMENTATION
|
|
167
|
+
|
|
168
|
+
<load_conditions>
|
|
169
|
+
<condition trigger="Starting new task">
|
|
170
|
+
Load: .claude/workflows/standard-task-workflow.md
|
|
171
|
+
</condition>
|
|
172
|
+
|
|
173
|
+
<condition trigger="Agent invocation @[agent]">
|
|
174
|
+
Load: .claude/agents/[category]/[agent].md
|
|
175
|
+
</condition>
|
|
176
|
+
|
|
177
|
+
<condition trigger="Rule violation OR uncertainty">
|
|
178
|
+
Load: .claude/rules/[specific-rule].md
|
|
179
|
+
</condition>
|
|
180
|
+
|
|
181
|
+
<condition trigger="Complex multi-step task">
|
|
182
|
+
Load: .claude/quick-ref/common-patterns.md
|
|
183
|
+
</condition>
|
|
184
|
+
</load_conditions>
|
|
185
|
+
|
|
186
|
+
## π EXAMPLE: LAZY LOADING IN ACTION
|
|
187
|
+
|
|
188
|
+
<example>
|
|
189
|
+
<scenario>User: "Implement user authentication"</scenario>
|
|
190
|
+
|
|
191
|
+
<step1>Check QUICK REFERENCE for workflow</step1>
|
|
192
|
+
<step2>Trigger: "@python-backend-engineer" β Load agent file</step2>
|
|
193
|
+
<step3>Trigger: "TDD" β Load .claude/quick-ref/tdd-cycle.md</step3>
|
|
194
|
+
<step4>Trigger: "Context7" β Query mcp://context7/fastapi/authentication</step4>
|
|
195
|
+
<step5>Execute: TDD cycle with agent assistance</step5>
|
|
196
|
+
|
|
197
|
+
<result>
|
|
198
|
+
Tokens loaded: ~3,000 (vs ~20,000 in old system)
|
|
199
|
+
Savings: 85%
|
|
200
|
+
</result>
|
|
201
|
+
</example>
|
|
202
|
+
|
|
203
|
+
## π§ COMMIT CHECKLIST (Compressed)
|
|
204
|
+
|
|
205
|
+
<before_commit>
|
|
206
|
+
β Tests: REDβGREENβREFACTOR sequence
|
|
207
|
+
β Lint: black|prettier|eslint passed
|
|
208
|
+
β Format: Applied + verified
|
|
209
|
+
β Type: mypy|tsc passed
|
|
210
|
+
β Coverage: 100% for new code
|
|
211
|
+
β Commits: testβfeatβrefactor sequence
|
|
212
|
+
</before_commit>
|
|
213
|
+
|
|
214
|
+
## π TONE & BEHAVIOR (Compressed)
|
|
215
|
+
|
|
216
|
+
<behavior>
|
|
217
|
+
Concise|Skeptical|Factual|No flattery|Ask when uncertain
|
|
218
|
+
Welcome criticism|Suggest better approaches|Reference standards
|
|
219
|
+
</behavior>
|
|
220
|
+
|
|
221
|
+
## π« ABSOLUTE PROHIBITIONS
|
|
222
|
+
|
|
223
|
+
<prohibited>
|
|
224
|
+
β Code without tests
|
|
225
|
+
β Partial implementations
|
|
226
|
+
β "TODO: add tests later"
|
|
227
|
+
β WIP commits
|
|
228
|
+
β Direct commits to main
|
|
229
|
+
β Mock services (use real)
|
|
230
|
+
β Skipping refactor phase
|
|
231
|
+
</prohibited>
|
|
232
|
+
|
|
233
|
+
## π ADDITIONAL RESOURCES
|
|
234
|
+
|
|
235
|
+
<resources>
|
|
236
|
+
Checklists: .claude/checklists/
|
|
237
|
+
Examples: .claude/examples/
|
|
238
|
+
Templates: .claude/templates/
|
|
239
|
+
Strategies: .claude/strategies/
|
|
240
|
+
</resources>
|
|
241
|
+
|
|
242
|
+
---
|
|
243
|
+
|
|
244
|
+
**Token Count: ~2,100 tokens (vs ~20,000 old system)**
|
|
245
|
+
**Savings: 89.5%**
|
|
@@ -118,26 +118,78 @@ Use for coordinating multiple work streams in parallel.
|
|
|
118
118
|
|
|
119
119
|
<!-- CICD_SECTION -->
|
|
120
120
|
|
|
121
|
-
## TDD PIPELINE FOR ALL IMPLEMENTATIONS
|
|
121
|
+
## π¨ TDD PIPELINE FOR ALL IMPLEMENTATIONS (HIGHEST PRIORITY)
|
|
122
|
+
|
|
123
|
+
```
|
|
124
|
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
|
125
|
+
β π΄ RED β β
GREEN β β»οΈ REFACTOR β
|
|
126
|
+
β β
|
|
127
|
+
β ZERO TOLERANCE: No code without tests. No exceptions. β
|
|
128
|
+
β See: .claude/rules/tdd.enforcement.md β
|
|
129
|
+
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
|
|
130
|
+
```
|
|
122
131
|
|
|
123
132
|
### Mandatory Test-Driven Development Cycle
|
|
124
133
|
|
|
125
|
-
Every implementation MUST follow
|
|
134
|
+
**CRITICAL**: Every implementation MUST follow TDD cycle. This rule has **HIGHEST PRIORITY**.
|
|
135
|
+
|
|
136
|
+
#### 1. π΄ RED Phase: Write FAILING Test First
|
|
137
|
+
|
|
138
|
+
- Write test that describes desired behavior
|
|
139
|
+
- Test **MUST FAIL** initially (run `@test-runner` to confirm)
|
|
140
|
+
- Test must be meaningful (no trivial assertions)
|
|
141
|
+
- **NEVER proceed to code without failing test**
|
|
142
|
+
|
|
143
|
+
```bash
|
|
144
|
+
# Example workflow:
|
|
145
|
+
touch tests/test_feature.py
|
|
146
|
+
# Write test
|
|
147
|
+
@test-runner run tests/test_feature.py # MUST SEE RED β
|
|
148
|
+
git commit -m "test: add failing test for feature"
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
#### 2. β
GREEN Phase: Write MINIMUM Code to Pass
|
|
152
|
+
|
|
153
|
+
- Write **MINIMUM** code to pass test
|
|
154
|
+
- Don't add features not required by test
|
|
155
|
+
- Focus on making test green, not perfection
|
|
156
|
+
- Run `@test-runner` to confirm tests pass
|
|
126
157
|
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
158
|
+
```bash
|
|
159
|
+
# Implement feature
|
|
160
|
+
@test-runner run tests/test_feature.py # MUST SEE GREEN β
|
|
161
|
+
git commit -m "feat: implement feature"
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
#### 3. β»οΈ REFACTOR Phase: Improve While Tests Stay Green
|
|
165
|
+
|
|
166
|
+
- Improve code structure
|
|
167
|
+
- Remove duplication
|
|
168
|
+
- Enhance readability
|
|
169
|
+
- **All tests MUST remain green**
|
|
170
|
+
- Run `@test-runner` after each change
|
|
171
|
+
|
|
172
|
+
```bash
|
|
173
|
+
# Refactor code
|
|
174
|
+
@test-runner run all tests # ALL MUST BE GREEN β
|
|
175
|
+
git commit -m "refactor: improve feature structure"
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
### TDD Commit Pattern (MANDATORY)
|
|
131
179
|
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
180
|
+
For EVERY feature, you MUST see this commit sequence:
|
|
181
|
+
```bash
|
|
182
|
+
git log --oneline
|
|
183
|
+
# c3d4e5f refactor: improve feature structure β»οΈ
|
|
184
|
+
# b2c3d4e feat: implement feature β
|
|
185
|
+
# a1b2c3d test: add failing test for feature π΄
|
|
186
|
+
```
|
|
136
187
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
188
|
+
**β VIOLATIONS (Auto-Reject):**
|
|
189
|
+
- Commits with code but no tests
|
|
190
|
+
- Commits with "WIP" or "TODO: add tests later"
|
|
191
|
+
- Skipping any phase of TDD cycle
|
|
192
|
+
- Tests written after implementation
|
|
141
193
|
|
|
142
194
|
## CONTEXT OPTIMIZATION RULES
|
|
143
195
|
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
<!-- Plugin Manifest Template for Token-Optimized CLAUDE.md -->
|
|
2
|
+
<!-- This template generates compressed plugin listings for base-optimized.md -->
|
|
3
|
+
|
|
4
|
+
<plugins>
|
|
5
|
+
<installed>{{INSTALLED_PLUGINS}}</installed>
|
|
6
|
+
|
|
7
|
+
<manifest>
|
|
8
|
+
{{PLUGIN_MANIFESTS}}
|
|
9
|
+
</manifest>
|
|
10
|
+
|
|
11
|
+
<lazy_loading>
|
|
12
|
+
<enabled>true</enabled>
|
|
13
|
+
<triggers>
|
|
14
|
+
commands: "/[plugin-id]:[command-name]"
|
|
15
|
+
agents: "@[agent-name]" (from plugin)
|
|
16
|
+
rules: on-violation or explicit reference
|
|
17
|
+
</triggers>
|
|
18
|
+
</lazy_loading>
|
|
19
|
+
|
|
20
|
+
<usage>
|
|
21
|
+
Commands: Type /[plugin-id]:[command] to invoke
|
|
22
|
+
Agents: Type @[agent-name] to invoke
|
|
23
|
+
Rules: Automatically loaded when needed
|
|
24
|
+
Files: All available in .claude/plugins/[plugin-id]/
|
|
25
|
+
</usage>
|
|
26
|
+
</plugins>
|
|
27
|
+
|
|
28
|
+
<!-- Example compressed manifest per plugin -->
|
|
29
|
+
<!--
|
|
30
|
+
<plugin id="core">
|
|
31
|
+
agents: agent-manager|code-analyzer|test-runner|file-analyzer
|
|
32
|
+
commands: code-rabbit|prompt|re-init
|
|
33
|
+
rules: 23 files (on-demand)
|
|
34
|
+
π .claude/plugins/core/
|
|
35
|
+
</plugin>
|
|
36
|
+
-->
|
package/bin/commands/plugin.js
CHANGED
|
@@ -24,7 +24,7 @@ module.exports = {
|
|
|
24
24
|
.positional('action', {
|
|
25
25
|
describe: 'Plugin action to perform',
|
|
26
26
|
type: 'string',
|
|
27
|
-
choices: ['list', 'search', 'install', 'uninstall', 'info', 'enable', 'disable']
|
|
27
|
+
choices: ['list', 'search', 'install', 'uninstall', 'update', 'info', 'enable', 'disable']
|
|
28
28
|
})
|
|
29
29
|
.positional('name', {
|
|
30
30
|
describe: 'Plugin name (without @claudeautopm/plugin- prefix)',
|
|
@@ -40,6 +40,8 @@ module.exports = {
|
|
|
40
40
|
.example('autopm plugin search cloud', 'Search for cloud-related plugins')
|
|
41
41
|
.example('autopm plugin install cloud', 'Install cloud plugin')
|
|
42
42
|
.example('autopm plugin uninstall cloud', 'Remove cloud plugin')
|
|
43
|
+
.example('autopm plugin update', 'Update all installed plugins')
|
|
44
|
+
.example('autopm plugin update cloud devops', 'Update specific plugins')
|
|
43
45
|
.example('autopm plugin info cloud', 'Show cloud plugin details')
|
|
44
46
|
.epilogue(`
|
|
45
47
|
π¦ Plugin Management
|
|
@@ -121,6 +123,12 @@ Usage:
|
|
|
121
123
|
}
|
|
122
124
|
await handleDisable(manager, argv.name, argv);
|
|
123
125
|
break;
|
|
126
|
+
case 'update':
|
|
127
|
+
// argv.name is optional - if not provided, update all
|
|
128
|
+
// argv._ contains additional arguments after the command
|
|
129
|
+
const pluginsToUpdate = argv.name ? [argv.name, ...(argv._.slice(3) || [])] : null;
|
|
130
|
+
await handleUpdate(manager, pluginsToUpdate, argv);
|
|
131
|
+
break;
|
|
124
132
|
default:
|
|
125
133
|
console.error(chalk.red(`Unknown action: ${argv.action}`));
|
|
126
134
|
process.exit(1);
|
|
@@ -393,3 +401,120 @@ async function handleDisable(manager, pluginName, argv) {
|
|
|
393
401
|
console.log(chalk.gray('Note: Agents remain in .claude/agents/ but plugin is marked as disabled'));
|
|
394
402
|
console.log('');
|
|
395
403
|
}
|
|
404
|
+
|
|
405
|
+
/**
|
|
406
|
+
* Handle 'update' command
|
|
407
|
+
*/
|
|
408
|
+
async function handleUpdate(manager, pluginNames, argv) {
|
|
409
|
+
console.log(chalk.bold('\nπ Updating Plugins\n'));
|
|
410
|
+
|
|
411
|
+
// Get list of installed plugins
|
|
412
|
+
const installed = manager.getInstalledPlugins();
|
|
413
|
+
|
|
414
|
+
if (installed.length === 0) {
|
|
415
|
+
console.log(chalk.yellow('No plugins installed to update.'));
|
|
416
|
+
console.log('');
|
|
417
|
+
return;
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
// Determine which plugins to update
|
|
421
|
+
let toUpdate = [];
|
|
422
|
+
if (pluginNames && pluginNames.length > 0) {
|
|
423
|
+
// Update specific plugins
|
|
424
|
+
for (const name of pluginNames) {
|
|
425
|
+
const fullName = name.startsWith('plugin-') ? name : `plugin-${name}`;
|
|
426
|
+
if (!installed.includes(fullName)) {
|
|
427
|
+
console.log(chalk.yellow(`β Plugin ${name} is not installed, skipping`));
|
|
428
|
+
} else {
|
|
429
|
+
toUpdate.push(fullName);
|
|
430
|
+
}
|
|
431
|
+
}
|
|
432
|
+
} else {
|
|
433
|
+
// Update all installed plugins
|
|
434
|
+
toUpdate = installed;
|
|
435
|
+
console.log(chalk.gray(`Updating all ${installed.length} installed plugin(s)...\n`));
|
|
436
|
+
}
|
|
437
|
+
|
|
438
|
+
if (toUpdate.length === 0) {
|
|
439
|
+
console.log(chalk.yellow('No plugins to update.'));
|
|
440
|
+
console.log('');
|
|
441
|
+
return;
|
|
442
|
+
}
|
|
443
|
+
|
|
444
|
+
const results = {
|
|
445
|
+
updated: [],
|
|
446
|
+
failed: [],
|
|
447
|
+
skipped: [],
|
|
448
|
+
upToDate: []
|
|
449
|
+
};
|
|
450
|
+
|
|
451
|
+
// Update each plugin
|
|
452
|
+
for (const pluginName of toUpdate) {
|
|
453
|
+
const shortName = pluginName.replace('plugin-', '');
|
|
454
|
+
|
|
455
|
+
try {
|
|
456
|
+
console.log(chalk.bold(`\nπ¦ Updating ${shortName}...`));
|
|
457
|
+
|
|
458
|
+
const result = await manager.updatePlugin(pluginName, {
|
|
459
|
+
verbose: argv.verbose,
|
|
460
|
+
force: argv.force
|
|
461
|
+
});
|
|
462
|
+
|
|
463
|
+
if (result.updated) {
|
|
464
|
+
results.updated.push({
|
|
465
|
+
name: shortName,
|
|
466
|
+
oldVersion: result.oldVersion,
|
|
467
|
+
newVersion: result.newVersion,
|
|
468
|
+
stats: result.stats
|
|
469
|
+
});
|
|
470
|
+
console.log(chalk.green(`β
Updated ${shortName} (${result.oldVersion} β ${result.newVersion})`));
|
|
471
|
+
|
|
472
|
+
if (argv.verbose && result.stats) {
|
|
473
|
+
console.log(chalk.gray(` Agents: ${result.stats.agents || 0}, Commands: ${result.stats.commands || 0}, Rules: ${result.stats.rules || 0}`));
|
|
474
|
+
}
|
|
475
|
+
} else if (result.upToDate) {
|
|
476
|
+
results.upToDate.push(shortName);
|
|
477
|
+
console.log(chalk.gray(`β ${shortName} is already up to date (${result.currentVersion})`));
|
|
478
|
+
} else {
|
|
479
|
+
results.skipped.push(shortName);
|
|
480
|
+
console.log(chalk.yellow(`β Skipped ${shortName}: ${result.reason || 'Unknown reason'}`));
|
|
481
|
+
}
|
|
482
|
+
} catch (error) {
|
|
483
|
+
results.failed.push({ name: shortName, error: error.message });
|
|
484
|
+
console.log(chalk.red(`β Failed to update ${shortName}: ${error.message}`));
|
|
485
|
+
|
|
486
|
+
if (argv.verbose) {
|
|
487
|
+
console.error(chalk.red(error.stack));
|
|
488
|
+
}
|
|
489
|
+
}
|
|
490
|
+
}
|
|
491
|
+
|
|
492
|
+
// Summary
|
|
493
|
+
console.log(chalk.bold('\nπ Update Summary\n'));
|
|
494
|
+
console.log(`${chalk.green('β
Updated:')} ${results.updated.length}`);
|
|
495
|
+
console.log(`${chalk.gray('β Up to date:')} ${results.upToDate.length}`);
|
|
496
|
+
console.log(`${chalk.yellow('β Skipped:')} ${results.skipped.length}`);
|
|
497
|
+
console.log(`${chalk.red('β Failed:')} ${results.failed.length}`);
|
|
498
|
+
console.log('');
|
|
499
|
+
|
|
500
|
+
if (results.updated.length > 0) {
|
|
501
|
+
console.log(chalk.bold('Updated Plugins:'));
|
|
502
|
+
for (const plugin of results.updated) {
|
|
503
|
+
console.log(` β’ ${plugin.name} (${plugin.oldVersion} β ${plugin.newVersion})`);
|
|
504
|
+
}
|
|
505
|
+
console.log('');
|
|
506
|
+
}
|
|
507
|
+
|
|
508
|
+
if (results.failed.length > 0) {
|
|
509
|
+
console.log(chalk.bold(chalk.red('Failed Updates:')));
|
|
510
|
+
for (const plugin of results.failed) {
|
|
511
|
+
console.log(chalk.red(` β’ ${plugin.name}: ${plugin.error}`));
|
|
512
|
+
}
|
|
513
|
+
console.log('');
|
|
514
|
+
}
|
|
515
|
+
|
|
516
|
+
// Exit with error if any updates failed
|
|
517
|
+
if (results.failed.length > 0) {
|
|
518
|
+
process.exit(1);
|
|
519
|
+
}
|
|
520
|
+
}
|
package/install/install.js
CHANGED
|
@@ -765,6 +765,9 @@ See: https://github.com/rafeekpro/ClaudeAutoPM
|
|
|
765
765
|
getRequiredAddons() {
|
|
766
766
|
const addons = [];
|
|
767
767
|
|
|
768
|
+
// ALWAYS include task-workflow (standard workflow for all projects)
|
|
769
|
+
addons.push('task-workflow');
|
|
770
|
+
|
|
768
771
|
// Based on scenario/configuration, determine required addons
|
|
769
772
|
if (this.currentConfig) {
|
|
770
773
|
if (this.currentConfig.tools?.docker?.enabled) {
|
|
@@ -804,6 +807,7 @@ See: https://github.com/rafeekpro/ClaudeAutoPM
|
|
|
804
807
|
'docker-agents': 'AGENT_SELECTION_SECTION',
|
|
805
808
|
'devops-agents': 'AGENT_SELECTION_SECTION',
|
|
806
809
|
'minimal-agents': 'AGENT_SELECTION_SECTION',
|
|
810
|
+
'task-workflow': 'WORKFLOW_SECTION',
|
|
807
811
|
'docker-workflow': 'WORKFLOW_SECTION',
|
|
808
812
|
'devops-workflow': 'WORKFLOW_SECTION',
|
|
809
813
|
'minimal-workflow': 'WORKFLOW_SECTION',
|