claude-code-orchestrator-kit 1.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/.claude/agents/database/workers/api-builder.md +155 -0
- package/.claude/agents/database/workers/database-architect.md +193 -0
- package/.claude/agents/database/workers/supabase-auditor.md +1070 -0
- package/.claude/agents/development/workers/code-reviewer.md +968 -0
- package/.claude/agents/development/workers/cost-calculator-specialist.md +683 -0
- package/.claude/agents/development/workers/llm-service-specialist.md +999 -0
- package/.claude/agents/development/workers/skill-builder-v2.md +480 -0
- package/.claude/agents/development/workers/typescript-types-specialist.md +649 -0
- package/.claude/agents/development/workers/utility-builder.md +582 -0
- package/.claude/agents/documentation/workers/technical-writer.md +152 -0
- package/.claude/agents/frontend/workers/fullstack-nextjs-specialist.md +206 -0
- package/.claude/agents/frontend/workers/visual-effects-creator.md +159 -0
- package/.claude/agents/health/orchestrators/bug-orchestrator.md +1045 -0
- package/.claude/agents/health/orchestrators/dead-code-orchestrator.md +1045 -0
- package/.claude/agents/health/orchestrators/dependency-orchestrator.md +1045 -0
- package/.claude/agents/health/orchestrators/security-orchestrator.md +1045 -0
- package/.claude/agents/health/workers/bug-fixer.md +525 -0
- package/.claude/agents/health/workers/bug-hunter.md +649 -0
- package/.claude/agents/health/workers/dead-code-hunter.md +446 -0
- package/.claude/agents/health/workers/dead-code-remover.md +437 -0
- package/.claude/agents/health/workers/dependency-auditor.md +379 -0
- package/.claude/agents/health/workers/dependency-updater.md +436 -0
- package/.claude/agents/health/workers/security-scanner.md +700 -0
- package/.claude/agents/health/workers/vulnerability-fixer.md +524 -0
- package/.claude/agents/infrastructure/workers/infrastructure-specialist.md +156 -0
- package/.claude/agents/infrastructure/workers/orchestration-logic-specialist.md +1260 -0
- package/.claude/agents/infrastructure/workers/qdrant-specialist.md +503 -0
- package/.claude/agents/infrastructure/workers/quality-validator-specialist.md +984 -0
- package/.claude/agents/meta/workers/meta-agent-v3.md +503 -0
- package/.claude/agents/research/workers/problem-investigator.md +507 -0
- package/.claude/agents/research/workers/research-specialist.md +423 -0
- package/.claude/agents/testing/workers/accessibility-tester.md +813 -0
- package/.claude/agents/testing/workers/integration-tester.md +188 -0
- package/.claude/agents/testing/workers/mobile-fixes-implementer.md +252 -0
- package/.claude/agents/testing/workers/mobile-responsiveness-tester.md +180 -0
- package/.claude/agents/testing/workers/performance-optimizer.md +262 -0
- package/.claude/agents/testing/workers/test-writer.md +800 -0
- package/.claude/commands/health-bugs.md +297 -0
- package/.claude/commands/health-cleanup.md +297 -0
- package/.claude/commands/health-deps.md +297 -0
- package/.claude/commands/health-metrics.md +747 -0
- package/.claude/commands/health-security.md +297 -0
- package/.claude/commands/push.md +21 -0
- package/.claude/commands/speckit.analyze.md +184 -0
- package/.claude/commands/speckit.checklist.md +294 -0
- package/.claude/commands/speckit.clarify.md +178 -0
- package/.claude/commands/speckit.constitution.md +78 -0
- package/.claude/commands/speckit.implement.md +182 -0
- package/.claude/commands/speckit.plan.md +87 -0
- package/.claude/commands/speckit.specify.md +250 -0
- package/.claude/commands/speckit.tasks.md +137 -0
- package/.claude/commands/translate-doc.md +95 -0
- package/.claude/commands/worktree-cleanup.md +382 -0
- package/.claude/commands/worktree-create.md +287 -0
- package/.claude/commands/worktree-list.md +239 -0
- package/.claude/commands/worktree-remove.md +339 -0
- package/.claude/schemas/base-plan.schema.json +82 -0
- package/.claude/schemas/bug-plan.schema.json +71 -0
- package/.claude/schemas/dead-code-plan.schema.json +71 -0
- package/.claude/schemas/dependency-plan.schema.json +74 -0
- package/.claude/schemas/security-plan.schema.json +71 -0
- package/.claude/scripts/gates/check-bundle-size.sh +47 -0
- package/.claude/scripts/gates/check-coverage.sh +67 -0
- package/.claude/scripts/gates/check-security.sh +46 -0
- package/.claude/scripts/release.sh +740 -0
- package/.claude/settings.local.json +21 -0
- package/.claude/settings.local.json.example +20 -0
- package/.claude/skills/calculate-priority-score/SKILL.md +229 -0
- package/.claude/skills/calculate-priority-score/scoring-matrix.json +83 -0
- package/.claude/skills/extract-version/SKILL.md +228 -0
- package/.claude/skills/format-commit-message/SKILL.md +189 -0
- package/.claude/skills/format-commit-message/template.md +64 -0
- package/.claude/skills/format-markdown-table/SKILL.md +202 -0
- package/.claude/skills/format-markdown-table/examples.md +84 -0
- package/.claude/skills/format-todo-list/SKILL.md +222 -0
- package/.claude/skills/format-todo-list/template.json +30 -0
- package/.claude/skills/generate-changelog/SKILL.md +258 -0
- package/.claude/skills/generate-changelog/commit-mapping.json +47 -0
- package/.claude/skills/generate-report-header/SKILL.md +228 -0
- package/.claude/skills/generate-report-header/template.md +66 -0
- package/.claude/skills/parse-error-logs/SKILL.md +286 -0
- package/.claude/skills/parse-error-logs/patterns.json +26 -0
- package/.claude/skills/parse-git-status/SKILL.md +164 -0
- package/.claude/skills/parse-package-json/SKILL.md +151 -0
- package/.claude/skills/parse-package-json/schema.json +43 -0
- package/.claude/skills/render-template/SKILL.md +245 -0
- package/.claude/skills/rollback-changes/SKILL.md +582 -0
- package/.claude/skills/rollback-changes/changes-log-schema.json +101 -0
- package/.claude/skills/run-quality-gate/SKILL.md +404 -0
- package/.claude/skills/run-quality-gate/gate-mappings.json +97 -0
- package/.claude/skills/validate-plan-file/SKILL.md +327 -0
- package/.claude/skills/validate-plan-file/schema.json +35 -0
- package/.claude/skills/validate-report-file/SKILL.md +256 -0
- package/.claude/skills/validate-report-file/schema.json +67 -0
- package/.env.example +49 -0
- package/.github/BRANCH_PROTECTION.md +137 -0
- package/.github/workflows/build.yml +70 -0
- package/.github/workflows/claude-code-review.yml +255 -0
- package/.github/workflows/claude.yml +79 -0
- package/.github/workflows/deploy-staging.yml +90 -0
- package/.github/workflows/test.yml +104 -0
- package/.gitignore +116 -0
- package/CLAUDE.md +137 -0
- package/LICENSE +72 -0
- package/README.md +1098 -0
- package/docs/ARCHITECTURE.md +746 -0
- package/docs/Agents Ecosystem/AGENT-ORCHESTRATION.md +568 -0
- package/docs/Agents Ecosystem/AI-AGENT-ECOSYSTEM-README.md +658 -0
- package/docs/Agents Ecosystem/ARCHITECTURE.md +606 -0
- package/docs/Agents Ecosystem/QUALITY-GATES-SPECIFICATION.md +1315 -0
- package/docs/Agents Ecosystem/REPORT-TEMPLATE-STANDARD.md +1324 -0
- package/docs/Agents Ecosystem/spec-kit-comprehensive-updates.md +478 -0
- package/docs/FAQ.md +572 -0
- package/docs/MIGRATION-GUIDE.md +542 -0
- package/docs/PERFORMANCE-OPTIMIZATION.md +494 -0
- package/docs/ROADMAP.md +439 -0
- package/docs/TUTORIAL-CUSTOM-AGENTS.md +2041 -0
- package/docs/USE-CASES.md +706 -0
- package/index.js +96 -0
- package/mcp/.mcp.base.json +21 -0
- package/mcp/.mcp.frontend.json +29 -0
- package/mcp/.mcp.full.json +67 -0
- package/mcp/.mcp.local.example.json +7 -0
- package/mcp/.mcp.local.json +7 -0
- package/mcp/.mcp.n8n.json +45 -0
- package/mcp/.mcp.supabase-full.json +35 -0
- package/mcp/.mcp.supabase-only.json +28 -0
- package/package.json +78 -0
- package/postinstall.js +71 -0
- package/switch-mcp.sh +101 -0
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: generate-report-header
|
|
3
|
+
description: Create standardized report headers with metadata for all agent-generated reports. Use when generating bug reports, security audits, dependency reports, or any worker output requiring consistent formatting.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Generate Report Header
|
|
7
|
+
|
|
8
|
+
Create consistent, well-formatted headers for all agent-generated reports with proper metadata.
|
|
9
|
+
|
|
10
|
+
## When to Use
|
|
11
|
+
|
|
12
|
+
- Beginning of all worker-generated reports
|
|
13
|
+
- Summary documents
|
|
14
|
+
- Validation reports
|
|
15
|
+
- Audit reports
|
|
16
|
+
- Any standardized output requiring header
|
|
17
|
+
|
|
18
|
+
## Instructions
|
|
19
|
+
|
|
20
|
+
### Step 1: Collect Header Information
|
|
21
|
+
|
|
22
|
+
Gather required information for header.
|
|
23
|
+
|
|
24
|
+
**Expected Input**:
|
|
25
|
+
- `reportType`: String (e.g., "Bug Hunting", "Security Audit", "Version Update")
|
|
26
|
+
- `version`: String (e.g., "0.8.0", "2025-10-17", "final")
|
|
27
|
+
- `status`: String (success|partial|failed|in_progress)
|
|
28
|
+
- `timestamp`: String (optional, ISO-8601 format, defaults to current time)
|
|
29
|
+
- `duration`: String (optional, e.g., "3m 45s", "1h 12m")
|
|
30
|
+
- `workflow`: String (optional, e.g., "bugs", "security", "dead-code", "dependencies")
|
|
31
|
+
- `phase`: String (optional, e.g., "detection", "fixing", "verification")
|
|
32
|
+
- `additionalMetadata`: Object (optional, extra fields)
|
|
33
|
+
|
|
34
|
+
### Step 2: Format Timestamp
|
|
35
|
+
|
|
36
|
+
Convert timestamp to readable format if needed.
|
|
37
|
+
|
|
38
|
+
**Format**: "YYYY-MM-DD HH:mm:ss UTC"
|
|
39
|
+
|
|
40
|
+
**Example**: "2025-10-17 14:30:00 UTC"
|
|
41
|
+
|
|
42
|
+
### Step 3: Determine Status Emoji
|
|
43
|
+
|
|
44
|
+
Map status to appropriate emoji.
|
|
45
|
+
|
|
46
|
+
**Status Mapping**:
|
|
47
|
+
- `success`: ✅
|
|
48
|
+
- `partial`: ⚠️
|
|
49
|
+
- `failed`: ❌
|
|
50
|
+
- `in_progress`: 🔄
|
|
51
|
+
|
|
52
|
+
### Step 4: Generate Header
|
|
53
|
+
|
|
54
|
+
Create formatted markdown header.
|
|
55
|
+
|
|
56
|
+
**Expected Output**:
|
|
57
|
+
```markdown
|
|
58
|
+
# {ReportType} Report: {Version}
|
|
59
|
+
|
|
60
|
+
**Generated**: {Timestamp}
|
|
61
|
+
**Status**: {StatusEmoji} {Status}
|
|
62
|
+
**Version**: {Version}
|
|
63
|
+
**Duration**: {Duration} (if provided)
|
|
64
|
+
**Workflow**: {Workflow} (if provided)
|
|
65
|
+
**Phase**: {Phase} (if provided)
|
|
66
|
+
|
|
67
|
+
---
|
|
68
|
+
|
|
69
|
+
## Executive Summary
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
**Standard Metrics** (include when available):
|
|
73
|
+
- Timestamp (ISO-8601)
|
|
74
|
+
- Duration (human-readable)
|
|
75
|
+
- Workflow (domain: bugs, security, dead-code, dependencies)
|
|
76
|
+
- Phase (detection, fixing, verification)
|
|
77
|
+
- Validation Status (✅ PASSED, ⛔ FAILED, ⚠️ PARTIAL)
|
|
78
|
+
|
|
79
|
+
### Step 5: Add Optional Metadata
|
|
80
|
+
|
|
81
|
+
Include additional metadata fields if provided.
|
|
82
|
+
|
|
83
|
+
**Optional Fields**:
|
|
84
|
+
- Agent name
|
|
85
|
+
- Duration
|
|
86
|
+
- File count
|
|
87
|
+
- Issue count
|
|
88
|
+
- Any custom fields
|
|
89
|
+
|
|
90
|
+
## Error Handling
|
|
91
|
+
|
|
92
|
+
- **Missing Report Type**: Return error requesting report type
|
|
93
|
+
- **Invalid Status**: Return error listing valid statuses
|
|
94
|
+
- **Invalid Timestamp**: Use current time and warn
|
|
95
|
+
|
|
96
|
+
## Examples
|
|
97
|
+
|
|
98
|
+
### Example 1: Bug Hunting Report
|
|
99
|
+
|
|
100
|
+
**Input**:
|
|
101
|
+
```json
|
|
102
|
+
{
|
|
103
|
+
"reportType": "Bug Hunting",
|
|
104
|
+
"version": "2025-10-17",
|
|
105
|
+
"status": "success",
|
|
106
|
+
"additionalMetadata": {
|
|
107
|
+
"agent": "bug-hunter",
|
|
108
|
+
"filesScanned": 147,
|
|
109
|
+
"bugsFound": 23
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
**Output**:
|
|
115
|
+
```markdown
|
|
116
|
+
# Bug Hunting Report: 2025-10-17
|
|
117
|
+
|
|
118
|
+
**Generated**: 2025-10-17 14:30:00 UTC
|
|
119
|
+
**Status**: ✅ success
|
|
120
|
+
**Version**: 2025-10-17
|
|
121
|
+
**Agent**: bug-hunter
|
|
122
|
+
**Files Scanned**: 147
|
|
123
|
+
**Bugs Found**: 23
|
|
124
|
+
|
|
125
|
+
---
|
|
126
|
+
|
|
127
|
+
## Executive Summary
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
### Example 2: Version Update Report
|
|
131
|
+
|
|
132
|
+
**Input**:
|
|
133
|
+
```json
|
|
134
|
+
{
|
|
135
|
+
"reportType": "Version Update",
|
|
136
|
+
"version": "0.7.0 → 0.8.0",
|
|
137
|
+
"status": "success"
|
|
138
|
+
}
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
**Output**:
|
|
142
|
+
```markdown
|
|
143
|
+
# Version Update Report: 0.7.0 → 0.8.0
|
|
144
|
+
|
|
145
|
+
**Generated**: 2025-10-17 14:30:00 UTC
|
|
146
|
+
**Status**: ✅ success
|
|
147
|
+
**Version**: 0.7.0 → 0.8.0
|
|
148
|
+
|
|
149
|
+
---
|
|
150
|
+
|
|
151
|
+
## Executive Summary
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
### Example 3: Security Audit (Partial)
|
|
155
|
+
|
|
156
|
+
**Input**:
|
|
157
|
+
```json
|
|
158
|
+
{
|
|
159
|
+
"reportType": "Security Audit",
|
|
160
|
+
"version": "final",
|
|
161
|
+
"status": "partial",
|
|
162
|
+
"timestamp": "2025-10-17T14:30:00Z",
|
|
163
|
+
"additionalMetadata": {
|
|
164
|
+
"criticalIssues": 2,
|
|
165
|
+
"highIssues": 5,
|
|
166
|
+
"fixedIssues": 5
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
**Output**:
|
|
172
|
+
```markdown
|
|
173
|
+
# Security Audit Report: final
|
|
174
|
+
|
|
175
|
+
**Generated**: 2025-10-17 14:30:00 UTC
|
|
176
|
+
**Status**: ⚠️ partial
|
|
177
|
+
**Version**: final
|
|
178
|
+
**Critical Issues**: 2
|
|
179
|
+
**High Issues**: 5
|
|
180
|
+
**Fixed Issues**: 5
|
|
181
|
+
|
|
182
|
+
---
|
|
183
|
+
|
|
184
|
+
## Executive Summary
|
|
185
|
+
```
|
|
186
|
+
|
|
187
|
+
### Example 4: Failed Dependency Update
|
|
188
|
+
|
|
189
|
+
**Input**:
|
|
190
|
+
```json
|
|
191
|
+
{
|
|
192
|
+
"reportType": "Dependency Update",
|
|
193
|
+
"version": "2025-10-17",
|
|
194
|
+
"status": "failed",
|
|
195
|
+
"additionalMetadata": {
|
|
196
|
+
"error": "npm install failed",
|
|
197
|
+
"failedPackages": ["package-a", "package-b"]
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
```
|
|
201
|
+
|
|
202
|
+
**Output**:
|
|
203
|
+
```markdown
|
|
204
|
+
# Dependency Update Report: 2025-10-17
|
|
205
|
+
|
|
206
|
+
**Generated**: 2025-10-17 14:30:00 UTC
|
|
207
|
+
**Status**: ❌ failed
|
|
208
|
+
**Version**: 2025-10-17
|
|
209
|
+
**Error**: npm install failed
|
|
210
|
+
**Failed Packages**: package-a, package-b
|
|
211
|
+
|
|
212
|
+
---
|
|
213
|
+
|
|
214
|
+
## Executive Summary
|
|
215
|
+
```
|
|
216
|
+
|
|
217
|
+
## Validation
|
|
218
|
+
|
|
219
|
+
- [ ] Generates header with all required fields
|
|
220
|
+
- [ ] Formats timestamp correctly
|
|
221
|
+
- [ ] Maps status to correct emoji
|
|
222
|
+
- [ ] Includes additional metadata when provided
|
|
223
|
+
- [ ] Validates status values
|
|
224
|
+
- [ ] Uses current time if timestamp missing
|
|
225
|
+
|
|
226
|
+
## Supporting Files
|
|
227
|
+
|
|
228
|
+
- `template.md`: Report header template (see Supporting Files section)
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# Report Header Template
|
|
2
|
+
|
|
3
|
+
## Standard Format
|
|
4
|
+
|
|
5
|
+
```markdown
|
|
6
|
+
# {ReportType} Report: {Version}
|
|
7
|
+
|
|
8
|
+
**Generated**: {Timestamp}
|
|
9
|
+
**Status**: {Emoji} {Status}
|
|
10
|
+
**Version**: {Version}
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
## Executive Summary
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
## Status Values
|
|
18
|
+
|
|
19
|
+
- **success** (✅): Operation completed successfully
|
|
20
|
+
- **partial** (⚠️): Operation completed with warnings or partial failures
|
|
21
|
+
- **failed** (❌): Operation failed critically
|
|
22
|
+
- **in_progress** (🔄): Operation is currently running
|
|
23
|
+
|
|
24
|
+
## Timestamp Format
|
|
25
|
+
|
|
26
|
+
ISO-8601 or human-readable: "YYYY-MM-DD HH:mm:ss UTC"
|
|
27
|
+
|
|
28
|
+
## Optional Metadata Fields
|
|
29
|
+
|
|
30
|
+
Common additional fields:
|
|
31
|
+
- **Agent**: Worker agent name
|
|
32
|
+
- **Duration**: Execution time
|
|
33
|
+
- **Files Processed**: Number of files
|
|
34
|
+
- **Issues Found**: Count of issues
|
|
35
|
+
- **Error**: Error message (for failed status)
|
|
36
|
+
|
|
37
|
+
## Report Types
|
|
38
|
+
|
|
39
|
+
- Bug Hunting Report
|
|
40
|
+
- Security Audit Report
|
|
41
|
+
- Dead Code Report
|
|
42
|
+
- Dependency Audit Report
|
|
43
|
+
- Version Update Report
|
|
44
|
+
- Code Health Report
|
|
45
|
+
- Verification Report
|
|
46
|
+
|
|
47
|
+
## Example Complete Header
|
|
48
|
+
|
|
49
|
+
```markdown
|
|
50
|
+
# Bug Hunting Report: 2025-10-17
|
|
51
|
+
|
|
52
|
+
**Generated**: 2025-10-17 14:30:00 UTC
|
|
53
|
+
**Status**: ✅ success
|
|
54
|
+
**Version**: 2025-10-17
|
|
55
|
+
**Agent**: bug-hunter
|
|
56
|
+
**Duration**: 3m 45s
|
|
57
|
+
**Files Scanned**: 147
|
|
58
|
+
**Bugs Found**: 23
|
|
59
|
+
|
|
60
|
+
---
|
|
61
|
+
|
|
62
|
+
## Executive Summary
|
|
63
|
+
|
|
64
|
+
This report documents the results of automated bug detection across the codebase.
|
|
65
|
+
Critical: 3 | High: 8 | Medium: 12
|
|
66
|
+
```
|
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: parse-error-logs
|
|
3
|
+
description: Parse build errors, test failures, type-check output, and validation logs into structured data. Use when processing npm/pnpm output, TypeScript errors, Jest failures, or any validation command results for quality gates.
|
|
4
|
+
allowed-tools: Read
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Parse Error Logs
|
|
8
|
+
|
|
9
|
+
Parse error and validation output from various tools into structured, actionable data.
|
|
10
|
+
|
|
11
|
+
## When to Use
|
|
12
|
+
|
|
13
|
+
- Quality gate validation (type-check, build, tests)
|
|
14
|
+
- Parse TypeScript compiler errors
|
|
15
|
+
- Extract test failure information
|
|
16
|
+
- Process npm/pnpm command output
|
|
17
|
+
- Summarize validation results
|
|
18
|
+
- Feed error data to bug-fixer or other workers
|
|
19
|
+
|
|
20
|
+
## Instructions
|
|
21
|
+
|
|
22
|
+
### Step 1: Receive Raw Output
|
|
23
|
+
|
|
24
|
+
Accept raw command output as input.
|
|
25
|
+
|
|
26
|
+
**Expected Input**:
|
|
27
|
+
- `output`: String (raw stdout/stderr from command)
|
|
28
|
+
- `type`: String (typescript|jest|npm|build|generic)
|
|
29
|
+
|
|
30
|
+
### Step 2: Identify Error Patterns
|
|
31
|
+
|
|
32
|
+
Detect error patterns based on type.
|
|
33
|
+
|
|
34
|
+
**TypeScript Patterns**:
|
|
35
|
+
```
|
|
36
|
+
error TS2322: Type 'string' is not assignable to type 'number'.
|
|
37
|
+
src/file.ts(10,5): error TS2322
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
**Jest Patterns**:
|
|
41
|
+
```
|
|
42
|
+
FAIL src/test.spec.ts
|
|
43
|
+
● Test Suite › test name
|
|
44
|
+
Expected: 5
|
|
45
|
+
Received: 3
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
**npm/pnpm Patterns**:
|
|
49
|
+
```
|
|
50
|
+
ERR! code ENOENT
|
|
51
|
+
ERR! syscall open
|
|
52
|
+
ERR! path /path/to/file
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
**Build Patterns**:
|
|
56
|
+
```
|
|
57
|
+
ERROR in ./src/file.ts
|
|
58
|
+
Module not found: Error: Can't resolve 'module'
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
### Step 3: Extract Error Details
|
|
62
|
+
|
|
63
|
+
Parse each error into structured format.
|
|
64
|
+
|
|
65
|
+
**For Each Error Extract**:
|
|
66
|
+
- `file`: File path (if available)
|
|
67
|
+
- `line`: Line number (if available)
|
|
68
|
+
- `column`: Column number (if available)
|
|
69
|
+
- `code`: Error code (e.g., "TS2322", "ENOENT")
|
|
70
|
+
- `message`: Error message
|
|
71
|
+
- `severity`: error|warning|info
|
|
72
|
+
- `type`: Classification (type-error, test-failure, dependency, etc.)
|
|
73
|
+
|
|
74
|
+
### Step 4: Categorize and Count
|
|
75
|
+
|
|
76
|
+
Group errors by type and count occurrences.
|
|
77
|
+
|
|
78
|
+
**Categories**:
|
|
79
|
+
- Type errors
|
|
80
|
+
- Test failures
|
|
81
|
+
- Dependency issues
|
|
82
|
+
- Build errors
|
|
83
|
+
- Linting errors
|
|
84
|
+
- Runtime errors
|
|
85
|
+
|
|
86
|
+
### Step 5: Return Structured Data
|
|
87
|
+
|
|
88
|
+
Return complete error analysis.
|
|
89
|
+
|
|
90
|
+
**Expected Output**:
|
|
91
|
+
```json
|
|
92
|
+
{
|
|
93
|
+
"success": false,
|
|
94
|
+
"totalErrors": 15,
|
|
95
|
+
"totalWarnings": 3,
|
|
96
|
+
"summary": {
|
|
97
|
+
"typeErrors": 8,
|
|
98
|
+
"testFailures": 5,
|
|
99
|
+
"buildErrors": 2
|
|
100
|
+
},
|
|
101
|
+
"errors": [
|
|
102
|
+
{
|
|
103
|
+
"file": "src/utils.ts",
|
|
104
|
+
"line": 42,
|
|
105
|
+
"column": 10,
|
|
106
|
+
"code": "TS2322",
|
|
107
|
+
"message": "Type 'string' is not assignable to type 'number'",
|
|
108
|
+
"severity": "error",
|
|
109
|
+
"type": "type-error"
|
|
110
|
+
}
|
|
111
|
+
],
|
|
112
|
+
"warnings": [
|
|
113
|
+
{
|
|
114
|
+
"file": "src/deprecated.ts",
|
|
115
|
+
"line": 15,
|
|
116
|
+
"code": "TS6133",
|
|
117
|
+
"message": "'oldFunction' is declared but never used",
|
|
118
|
+
"severity": "warning",
|
|
119
|
+
"type": "unused-variable"
|
|
120
|
+
}
|
|
121
|
+
]
|
|
122
|
+
}
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
## Error Handling
|
|
126
|
+
|
|
127
|
+
- **Empty Output**: Return success with zero errors
|
|
128
|
+
- **Unrecognized Format**: Return generic parse with raw message
|
|
129
|
+
- **Partial Parse**: Include what was parsed, note unparsable lines
|
|
130
|
+
- **Invalid Type**: Warn and default to "generic" parsing
|
|
131
|
+
|
|
132
|
+
## Examples
|
|
133
|
+
|
|
134
|
+
### Example 1: TypeScript Errors
|
|
135
|
+
|
|
136
|
+
**Input**:
|
|
137
|
+
```json
|
|
138
|
+
{
|
|
139
|
+
"output": "src/app.ts(10,5): error TS2322: Type 'string' is not assignable to type 'number'.\nsrc/utils.ts(25,12): error TS2304: Cannot find name 'undefined'.",
|
|
140
|
+
"type": "typescript"
|
|
141
|
+
}
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
**Output**:
|
|
145
|
+
```json
|
|
146
|
+
{
|
|
147
|
+
"success": false,
|
|
148
|
+
"totalErrors": 2,
|
|
149
|
+
"totalWarnings": 0,
|
|
150
|
+
"summary": {
|
|
151
|
+
"typeErrors": 2
|
|
152
|
+
},
|
|
153
|
+
"errors": [
|
|
154
|
+
{
|
|
155
|
+
"file": "src/app.ts",
|
|
156
|
+
"line": 10,
|
|
157
|
+
"column": 5,
|
|
158
|
+
"code": "TS2322",
|
|
159
|
+
"message": "Type 'string' is not assignable to type 'number'",
|
|
160
|
+
"severity": "error",
|
|
161
|
+
"type": "type-error"
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
"file": "src/utils.ts",
|
|
165
|
+
"line": 25,
|
|
166
|
+
"column": 12,
|
|
167
|
+
"code": "TS2304",
|
|
168
|
+
"message": "Cannot find name 'undefined'",
|
|
169
|
+
"severity": "error",
|
|
170
|
+
"type": "type-error"
|
|
171
|
+
}
|
|
172
|
+
],
|
|
173
|
+
"warnings": []
|
|
174
|
+
}
|
|
175
|
+
```
|
|
176
|
+
|
|
177
|
+
### Example 2: Jest Test Failures
|
|
178
|
+
|
|
179
|
+
**Input**:
|
|
180
|
+
```json
|
|
181
|
+
{
|
|
182
|
+
"output": "FAIL src/utils.test.ts\n ● Math › addition\n expect(received).toBe(expected)\n Expected: 5\n Received: 3\n at Object.<anonymous> (src/utils.test.ts:10:15)",
|
|
183
|
+
"type": "jest"
|
|
184
|
+
}
|
|
185
|
+
```
|
|
186
|
+
|
|
187
|
+
**Output**:
|
|
188
|
+
```json
|
|
189
|
+
{
|
|
190
|
+
"success": false,
|
|
191
|
+
"totalErrors": 1,
|
|
192
|
+
"totalWarnings": 0,
|
|
193
|
+
"summary": {
|
|
194
|
+
"testFailures": 1
|
|
195
|
+
},
|
|
196
|
+
"errors": [
|
|
197
|
+
{
|
|
198
|
+
"file": "src/utils.test.ts",
|
|
199
|
+
"line": 10,
|
|
200
|
+
"column": 15,
|
|
201
|
+
"code": null,
|
|
202
|
+
"message": "expect(received).toBe(expected) - Expected: 5, Received: 3",
|
|
203
|
+
"severity": "error",
|
|
204
|
+
"type": "test-failure",
|
|
205
|
+
"testName": "Math › addition"
|
|
206
|
+
}
|
|
207
|
+
],
|
|
208
|
+
"warnings": []
|
|
209
|
+
}
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
### Example 3: Successful Build
|
|
213
|
+
|
|
214
|
+
**Input**:
|
|
215
|
+
```json
|
|
216
|
+
{
|
|
217
|
+
"output": "✓ Built successfully\nCompleted in 2.3s",
|
|
218
|
+
"type": "build"
|
|
219
|
+
}
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
**Output**:
|
|
223
|
+
```json
|
|
224
|
+
{
|
|
225
|
+
"success": true,
|
|
226
|
+
"totalErrors": 0,
|
|
227
|
+
"totalWarnings": 0,
|
|
228
|
+
"summary": {},
|
|
229
|
+
"errors": [],
|
|
230
|
+
"warnings": []
|
|
231
|
+
}
|
|
232
|
+
```
|
|
233
|
+
|
|
234
|
+
### Example 4: Mixed Errors and Warnings
|
|
235
|
+
|
|
236
|
+
**Input**:
|
|
237
|
+
```json
|
|
238
|
+
{
|
|
239
|
+
"output": "Warning: React Hook useEffect has a missing dependency\nerror TS2339: Property 'foo' does not exist on type 'Bar'",
|
|
240
|
+
"type": "typescript"
|
|
241
|
+
}
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
**Output**:
|
|
245
|
+
```json
|
|
246
|
+
{
|
|
247
|
+
"success": false,
|
|
248
|
+
"totalErrors": 1,
|
|
249
|
+
"totalWarnings": 1,
|
|
250
|
+
"summary": {
|
|
251
|
+
"typeErrors": 1,
|
|
252
|
+
"lintWarnings": 1
|
|
253
|
+
},
|
|
254
|
+
"errors": [
|
|
255
|
+
{
|
|
256
|
+
"code": "TS2339",
|
|
257
|
+
"message": "Property 'foo' does not exist on type 'Bar'",
|
|
258
|
+
"severity": "error",
|
|
259
|
+
"type": "type-error"
|
|
260
|
+
}
|
|
261
|
+
],
|
|
262
|
+
"warnings": [
|
|
263
|
+
{
|
|
264
|
+
"message": "React Hook useEffect has a missing dependency",
|
|
265
|
+
"severity": "warning",
|
|
266
|
+
"type": "lint-warning"
|
|
267
|
+
}
|
|
268
|
+
]
|
|
269
|
+
}
|
|
270
|
+
```
|
|
271
|
+
|
|
272
|
+
## Validation
|
|
273
|
+
|
|
274
|
+
- [ ] Parses TypeScript errors correctly
|
|
275
|
+
- [ ] Parses Jest test failures
|
|
276
|
+
- [ ] Parses npm/pnpm errors
|
|
277
|
+
- [ ] Parses build errors
|
|
278
|
+
- [ ] Extracts file, line, column when available
|
|
279
|
+
- [ ] Categorizes errors by type
|
|
280
|
+
- [ ] Returns summary counts
|
|
281
|
+
- [ ] Handles successful output (zero errors)
|
|
282
|
+
- [ ] Handles mixed errors and warnings
|
|
283
|
+
|
|
284
|
+
## Supporting Files
|
|
285
|
+
|
|
286
|
+
- `patterns.json`: Regex patterns for common error formats
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"typescript": {
|
|
3
|
+
"error": "^(.+?)\\((\\d+),(\\d+)\\):\\s*(error|warning)\\s+(TS\\d+):\\s*(.+)$",
|
|
4
|
+
"simple": "^(error|warning)\\s+(TS\\d+):\\s*(.+)$"
|
|
5
|
+
},
|
|
6
|
+
"jest": {
|
|
7
|
+
"fail": "^FAIL\\s+(.+)$",
|
|
8
|
+
"testName": "^\\s*●\\s+(.+)$",
|
|
9
|
+
"expected": "Expected:\\s*(.+)",
|
|
10
|
+
"received": "Received:\\s*(.+)",
|
|
11
|
+
"location": "at\\s+.+?\\((.+?):(\\d+):(\\d+)\\)"
|
|
12
|
+
},
|
|
13
|
+
"npm": {
|
|
14
|
+
"error": "^npm\\s+ERR!\\s+(.+)$",
|
|
15
|
+
"code": "^npm\\s+ERR!\\s+code\\s+(.+)$",
|
|
16
|
+
"path": "^npm\\s+ERR!\\s+path\\s+(.+)$"
|
|
17
|
+
},
|
|
18
|
+
"build": {
|
|
19
|
+
"error": "^ERROR\\s+in\\s+(.+)$",
|
|
20
|
+
"moduleNotFound": "Module not found:\\s*Error:\\s*(.+)"
|
|
21
|
+
},
|
|
22
|
+
"generic": {
|
|
23
|
+
"error": "^(error|ERROR)[:s]+(.+)$",
|
|
24
|
+
"warning": "^(warning|WARNING|WARN)[:s]+(.+)$"
|
|
25
|
+
}
|
|
26
|
+
}
|