devflow-kit 0.3.1 → 0.3.3
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/CHANGELOG.md +40 -0
- package/README.md +5 -7
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +90 -132
- package/dist/commands/init.js.map +1 -1
- package/package.json +1 -1
- package/src/claude/CLAUDE.md +76 -8
- package/src/claude/agents/devflow/audit-architecture.md +67 -1
- package/src/claude/agents/devflow/audit-complexity.md +67 -1
- package/src/claude/agents/devflow/audit-database.md +67 -1
- package/src/claude/agents/devflow/audit-dependencies.md +67 -1
- package/src/claude/agents/devflow/audit-documentation.md +66 -0
- package/src/claude/agents/devflow/audit-performance.md +67 -1
- package/src/claude/agents/devflow/audit-security.md +67 -1
- package/src/claude/agents/devflow/audit-tests.md +67 -1
- package/src/claude/agents/devflow/audit-typescript.md +66 -0
- package/src/claude/agents/devflow/release.md +283 -8
- package/src/claude/commands/devflow/{pre-pr.md → code-review.md} +52 -13
- package/src/claude/scripts/statusline.sh +37 -69
- package/src/claude/commands/devflow/pre-commit.md +0 -153
|
@@ -1,153 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: Review uncommitted changes before committing using specialized sub-agents
|
|
3
|
-
allowed-tools: Task, Bash, Read, Write, Grep, Glob
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
## Your Task
|
|
7
|
-
|
|
8
|
-
Perform a comprehensive review of uncommitted changes by orchestrating multiple specialized sub-agents in parallel. This provides quick feedback before committing changes.
|
|
9
|
-
|
|
10
|
-
**Audit Strategy**:
|
|
11
|
-
- **Always Run** (5 core audits): Security, Performance, Architecture, Tests, Complexity
|
|
12
|
-
- **Language-Specific** (conditional): TypeScript (runs only if .ts/.tsx files changed or tsconfig.json exists)
|
|
13
|
-
- **Available on demand**: Documentation, Dependencies, Database (use `/pre-pr` for full audit)
|
|
14
|
-
|
|
15
|
-
This lightweight approach provides fast feedback for individual commits. Use `/pre-pr` for comprehensive branch reviews before creating pull requests.
|
|
16
|
-
|
|
17
|
-
### Step 1: Analyze Current Changes
|
|
18
|
-
|
|
19
|
-
First, check what changes are available for review:
|
|
20
|
-
|
|
21
|
-
```bash
|
|
22
|
-
# Check for uncommitted changes
|
|
23
|
-
git status --porcelain
|
|
24
|
-
|
|
25
|
-
# Get the diff of uncommitted changes
|
|
26
|
-
if git diff --quiet HEAD; then
|
|
27
|
-
echo "No uncommitted changes to review"
|
|
28
|
-
exit 0
|
|
29
|
-
fi
|
|
30
|
-
|
|
31
|
-
# Show summary of changes
|
|
32
|
-
echo "=== CHANGES TO REVIEW ==="
|
|
33
|
-
git diff --stat HEAD
|
|
34
|
-
echo ""
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
### Step 2: Launch Specialized Sub-Agents in Parallel
|
|
38
|
-
|
|
39
|
-
Launch these sub-agents in parallel:
|
|
40
|
-
|
|
41
|
-
1. audit-security sub-agent
|
|
42
|
-
2. audit-typescript sub-agent (automatically skips if not applicable)
|
|
43
|
-
3. audit-performance sub-agent
|
|
44
|
-
4. audit-architecture sub-agent
|
|
45
|
-
5. audit-tests sub-agent
|
|
46
|
-
6. audit-complexity sub-agent
|
|
47
|
-
|
|
48
|
-
**Note**: The audit-typescript agent contains built-in detection logic and will automatically skip if:
|
|
49
|
-
- No .ts/.tsx files were changed AND
|
|
50
|
-
- No tsconfig.json exists in the project
|
|
51
|
-
|
|
52
|
-
### Step 3: Synthesize Review Findings
|
|
53
|
-
|
|
54
|
-
After all sub-agents complete their analysis:
|
|
55
|
-
|
|
56
|
-
1. **Collect Results**: Gather findings from all sub-agents
|
|
57
|
-
2. **Prioritize Issues**: Categorize as Critical/High/Medium/Low
|
|
58
|
-
3. **Create Unified Review**: Synthesize into coherent review document
|
|
59
|
-
4. **Generate Action Items**: Provide specific next steps
|
|
60
|
-
|
|
61
|
-
### Step 4: Save Review Document
|
|
62
|
-
|
|
63
|
-
Create a comprehensive review document at `.docs/reviews/diff-{YYYY-MM-DD_HHMM}.md`:
|
|
64
|
-
|
|
65
|
-
```markdown
|
|
66
|
-
# Code Review - Uncommitted Changes
|
|
67
|
-
**Date**: {current_date}
|
|
68
|
-
**Time**: {current_time}
|
|
69
|
-
**Type**: Differential Review (uncommitted changes)
|
|
70
|
-
**Reviewer**: AI Sub-Agent Orchestra
|
|
71
|
-
|
|
72
|
-
---
|
|
73
|
-
|
|
74
|
-
## 📊 Review Summary
|
|
75
|
-
|
|
76
|
-
**Files Changed**: {number}
|
|
77
|
-
**Lines Added**: {number}
|
|
78
|
-
**Lines Removed**: {number}
|
|
79
|
-
|
|
80
|
-
### Issues Found
|
|
81
|
-
- 🔴 **Critical**: {count} issues requiring immediate attention
|
|
82
|
-
- 🟠 **High**: {count} issues should be addressed before commit
|
|
83
|
-
- 🟡 **Medium**: {count} improvements recommended
|
|
84
|
-
- 🔵 **Low**: {count} minor suggestions
|
|
85
|
-
|
|
86
|
-
---
|
|
87
|
-
|
|
88
|
-
## 🔍 Detailed Analysis
|
|
89
|
-
|
|
90
|
-
### Security Review (audit-security)
|
|
91
|
-
{security findings with file:line references}
|
|
92
|
-
|
|
93
|
-
### TypeScript Review (audit-typescript)
|
|
94
|
-
{type safety findings, or "⏭️ Skipped - not applicable" if no TS files}
|
|
95
|
-
|
|
96
|
-
### Performance Review (audit-performance)
|
|
97
|
-
{performance findings with specific optimizations}
|
|
98
|
-
|
|
99
|
-
### Architecture Review (audit-architecture)
|
|
100
|
-
{design pattern and structure analysis}
|
|
101
|
-
|
|
102
|
-
### Test Coverage Review (audit-tests)
|
|
103
|
-
{test gaps and quality assessment}
|
|
104
|
-
|
|
105
|
-
### Complexity Review (audit-complexity)
|
|
106
|
-
{maintainability and refactoring suggestions}
|
|
107
|
-
|
|
108
|
-
---
|
|
109
|
-
|
|
110
|
-
## 🎯 Action Items
|
|
111
|
-
|
|
112
|
-
### Before Committing (Critical/High)
|
|
113
|
-
- [ ] {action 1} in {file:line}
|
|
114
|
-
- [ ] {action 2} in {file:line}
|
|
115
|
-
|
|
116
|
-
### Future Improvements (Medium/Low)
|
|
117
|
-
- [ ] {improvement 1}
|
|
118
|
-
- [ ] {improvement 2}
|
|
119
|
-
|
|
120
|
-
---
|
|
121
|
-
|
|
122
|
-
## 📈 Code Quality Metrics
|
|
123
|
-
|
|
124
|
-
**Overall Assessment**: {Excellent/Good/Needs Work/Poor}
|
|
125
|
-
**Commit Recommendation**: {✅ Safe to commit / ⚠️ Address issues first / 🚫 Do not commit}
|
|
126
|
-
|
|
127
|
-
---
|
|
128
|
-
|
|
129
|
-
*Review generated by DevFlow sub-agent orchestration*
|
|
130
|
-
```
|
|
131
|
-
|
|
132
|
-
### Step 5: Provide Interactive Summary
|
|
133
|
-
|
|
134
|
-
Give the developer a clear summary and next steps:
|
|
135
|
-
|
|
136
|
-
```
|
|
137
|
-
🔍 UNCOMMITTED CHANGES REVIEW COMPLETE
|
|
138
|
-
|
|
139
|
-
Changes analyzed: {X} files, {Y} lines modified
|
|
140
|
-
Issues found: {Critical} critical, {High} high, {Medium} medium, {Low} low
|
|
141
|
-
|
|
142
|
-
📋 COMMIT READINESS ASSESSMENT:
|
|
143
|
-
{✅ SAFE TO COMMIT | ⚠️ ISSUES TO ADDRESS | 🚫 DO NOT COMMIT}
|
|
144
|
-
|
|
145
|
-
🎯 TOP PRIORITY ACTIONS:
|
|
146
|
-
1. {Most critical issue and fix}
|
|
147
|
-
2. {Second most critical issue and fix}
|
|
148
|
-
3. {Third most critical issue and fix}
|
|
149
|
-
|
|
150
|
-
📄 Full review saved to: .docs/reviews/diff-{timestamp}.md
|
|
151
|
-
|
|
152
|
-
💡 TIP: Run `/review-branch` before creating PR for comprehensive feature review
|
|
153
|
-
```
|