moicle 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/README.md +201 -0
- package/assets/agents/developers/flutter-mobile-dev.md +69 -0
- package/assets/agents/developers/go-backend-dev.md +57 -0
- package/assets/agents/developers/laravel-backend-dev.md +123 -0
- package/assets/agents/developers/react-frontend-dev.md +69 -0
- package/assets/agents/developers/remix-fullstack-dev.md +69 -0
- package/assets/agents/utilities/api-designer.md +76 -0
- package/assets/agents/utilities/clean-architect.md +83 -0
- package/assets/agents/utilities/code-reviewer.md +76 -0
- package/assets/agents/utilities/db-designer.md +68 -0
- package/assets/agents/utilities/devops.md +71 -0
- package/assets/agents/utilities/docs-writer.md +75 -0
- package/assets/agents/utilities/perf-optimizer.md +87 -0
- package/assets/agents/utilities/refactor.md +173 -0
- package/assets/agents/utilities/security-audit.md +203 -0
- package/assets/agents/utilities/test-writer.md +139 -0
- package/assets/architecture/clean-architecture.md +143 -0
- package/assets/architecture/flutter-mobile.md +304 -0
- package/assets/architecture/go-backend.md +217 -0
- package/assets/architecture/laravel-backend.md +303 -0
- package/assets/architecture/monorepo.md +162 -0
- package/assets/architecture/react-frontend.md +268 -0
- package/assets/architecture/remix-fullstack.md +272 -0
- package/assets/commands/bootstrap.md +98 -0
- package/assets/commands/brainstorm.md +440 -0
- package/assets/skills/feature-workflow/SKILL.md +298 -0
- package/assets/skills/hotfix-workflow/SKILL.md +368 -0
- package/assets/templates/flutter/CLAUDE.md +454 -0
- package/assets/templates/go-gin/CLAUDE.md +244 -0
- package/assets/templates/monorepo/CLAUDE.md +362 -0
- package/assets/templates/react-vite/CLAUDE.md +304 -0
- package/assets/templates/remix/CLAUDE.md +304 -0
- package/bin/cli.js +76 -0
- package/dist/commands/disable.d.ts +3 -0
- package/dist/commands/disable.d.ts.map +1 -0
- package/dist/commands/disable.js +188 -0
- package/dist/commands/disable.js.map +1 -0
- package/dist/commands/enable.d.ts +3 -0
- package/dist/commands/enable.d.ts.map +1 -0
- package/dist/commands/enable.js +191 -0
- package/dist/commands/enable.js.map +1 -0
- package/dist/commands/install.d.ts +3 -0
- package/dist/commands/install.d.ts.map +1 -0
- package/dist/commands/install.js +290 -0
- package/dist/commands/install.js.map +1 -0
- package/dist/commands/list.d.ts +3 -0
- package/dist/commands/list.d.ts.map +1 -0
- package/dist/commands/list.js +75 -0
- package/dist/commands/list.js.map +1 -0
- package/dist/commands/postinstall.d.ts +2 -0
- package/dist/commands/postinstall.d.ts.map +1 -0
- package/dist/commands/postinstall.js +25 -0
- package/dist/commands/postinstall.js.map +1 -0
- package/dist/commands/status.d.ts +3 -0
- package/dist/commands/status.d.ts.map +1 -0
- package/dist/commands/status.js +118 -0
- package/dist/commands/status.js.map +1 -0
- package/dist/commands/uninstall.d.ts +3 -0
- package/dist/commands/uninstall.d.ts.map +1 -0
- package/dist/commands/uninstall.js +178 -0
- package/dist/commands/uninstall.js.map +1 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +11 -0
- package/dist/index.js.map +1 -0
- package/dist/types.d.ts +47 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +2 -0
- package/dist/types.js.map +1 -0
- package/dist/utils/config.d.ts +13 -0
- package/dist/utils/config.d.ts.map +1 -0
- package/dist/utils/config.js +95 -0
- package/dist/utils/config.js.map +1 -0
- package/dist/utils/symlink.d.ts +24 -0
- package/dist/utils/symlink.d.ts.map +1 -0
- package/dist/utils/symlink.js +313 -0
- package/dist/utils/symlink.js.map +1 -0
- package/package.json +55 -0
|
@@ -0,0 +1,368 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: hotfix-workflow
|
|
3
|
+
description: Quick bug fix workflow with rollback plan. Use when fixing bugs, hotfixes, urgent issues, production bugs, or when user says "fix bug", "hotfix", "urgent fix", "production issue".
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Hotfix Workflow
|
|
7
|
+
|
|
8
|
+
Fast-track workflow for fixing bugs with safety rollback plan.
|
|
9
|
+
|
|
10
|
+
## Recommended Agents
|
|
11
|
+
|
|
12
|
+
| Phase | Agent | Purpose |
|
|
13
|
+
|-------|-------|---------|
|
|
14
|
+
| FIX | `@react-frontend-dev`, `@go-backend-dev`, `@laravel-backend-dev`, `@flutter-mobile-dev`, `@remix-fullstack-dev` | Stack-specific bug fix |
|
|
15
|
+
| FIX | `@security-audit` | Security-related bugs |
|
|
16
|
+
| VERIFY | `@test-writer` | Regression test |
|
|
17
|
+
| VERIFY | `@code-reviewer` | Quick code review |
|
|
18
|
+
| DEPLOY | `@devops` | CI/CD & deployment |
|
|
19
|
+
|
|
20
|
+
## Workflow Overview
|
|
21
|
+
|
|
22
|
+
```
|
|
23
|
+
┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐
|
|
24
|
+
│1. IDENTIFY──▶│2. REPRODUCE──▶│ 3. FIX │──▶│4. VERIFY │──▶│5. DEPLOY │
|
|
25
|
+
└──────────┘ └──────────┘ └──────────┘ └──────────┘ └──────────┘
|
|
26
|
+
│ │
|
|
27
|
+
│ Fail? │
|
|
28
|
+
│ ┌────────────────────┘
|
|
29
|
+
▼ ▼
|
|
30
|
+
┌──────────────────┐
|
|
31
|
+
│ 6. ROLLBACK │
|
|
32
|
+
│ (if needed) │
|
|
33
|
+
└──────────────────┘
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
## Phase 1: IDENTIFY
|
|
39
|
+
|
|
40
|
+
**Goal**: Identify exactly what the bug is
|
|
41
|
+
|
|
42
|
+
**Time**: 5-10 minutes
|
|
43
|
+
|
|
44
|
+
### Actions
|
|
45
|
+
1. Gather information:
|
|
46
|
+
- Error message / stack trace
|
|
47
|
+
- Steps to reproduce
|
|
48
|
+
- Expected vs actual behavior
|
|
49
|
+
- Environment (prod/staging/dev)
|
|
50
|
+
- Affected users/scope
|
|
51
|
+
|
|
52
|
+
2. Assess severity:
|
|
53
|
+
```
|
|
54
|
+
🔴 CRITICAL - Production down, data loss
|
|
55
|
+
🟠 HIGH - Major feature broken, many users affected
|
|
56
|
+
🟡 MEDIUM - Feature degraded, workaround exists
|
|
57
|
+
🟢 LOW - Minor issue, cosmetic
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
3. Document:
|
|
61
|
+
```markdown
|
|
62
|
+
## Bug Report
|
|
63
|
+
**Severity**: [CRITICAL/HIGH/MEDIUM/LOW]
|
|
64
|
+
**Error**: [error message]
|
|
65
|
+
**Steps**:
|
|
66
|
+
1. ...
|
|
67
|
+
2. ...
|
|
68
|
+
**Expected**: [what should happen]
|
|
69
|
+
**Actual**: [what happens]
|
|
70
|
+
**Environment**: [prod/staging/dev]
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
### Gate
|
|
74
|
+
- [ ] Bug clearly described
|
|
75
|
+
- [ ] Severity assessed
|
|
76
|
+
- [ ] Scope understood
|
|
77
|
+
|
|
78
|
+
---
|
|
79
|
+
|
|
80
|
+
## Phase 2: REPRODUCE & ANALYZE
|
|
81
|
+
|
|
82
|
+
**Goal**: Reproduce the bug and find root cause
|
|
83
|
+
|
|
84
|
+
**Time**: 10-20 minutes
|
|
85
|
+
|
|
86
|
+
### Actions
|
|
87
|
+
1. Reproduce locally:
|
|
88
|
+
```bash
|
|
89
|
+
# Setup same environment
|
|
90
|
+
# Follow exact steps
|
|
91
|
+
# Confirm bug occurs
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
2. Find root cause (5 Whys):
|
|
95
|
+
```
|
|
96
|
+
Why did it fail? → [answer]
|
|
97
|
+
Why? → [deeper answer]
|
|
98
|
+
Why? → [even deeper]
|
|
99
|
+
Why? → [root cause emerging]
|
|
100
|
+
Why? → [ROOT CAUSE]
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
3. Identify fix location:
|
|
104
|
+
- Which file(s)?
|
|
105
|
+
- Which function(s)?
|
|
106
|
+
- What's the minimal change?
|
|
107
|
+
|
|
108
|
+
4. Check git blame:
|
|
109
|
+
```bash
|
|
110
|
+
git log --oneline -10 -- [affected_file]
|
|
111
|
+
git blame [affected_file] | grep -A5 -B5 "[problem_area]"
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
### Analysis Output
|
|
115
|
+
```markdown
|
|
116
|
+
## Root Cause Analysis
|
|
117
|
+
**Root Cause**: [description]
|
|
118
|
+
**Introduced**: [commit/PR if known]
|
|
119
|
+
**Affected Files**:
|
|
120
|
+
- file1.ts:123
|
|
121
|
+
- file2.ts:456
|
|
122
|
+
|
|
123
|
+
**Fix Strategy**: [brief description of fix]
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
### Gate
|
|
127
|
+
- [ ] Bug reproduced locally
|
|
128
|
+
- [ ] Root cause identified
|
|
129
|
+
- [ ] Fix location known
|
|
130
|
+
|
|
131
|
+
---
|
|
132
|
+
|
|
133
|
+
## Phase 3: FIX
|
|
134
|
+
|
|
135
|
+
**Goal**: Implement minimal fix
|
|
136
|
+
|
|
137
|
+
**Time**: 15-30 minutes
|
|
138
|
+
|
|
139
|
+
### Principles
|
|
140
|
+
1. **Minimal change** - Fix only what's broken
|
|
141
|
+
2. **No refactoring** - Save for later
|
|
142
|
+
3. **No new features** - Stay focused
|
|
143
|
+
4. **Preserve behavior** - Don't change anything else
|
|
144
|
+
|
|
145
|
+
### Actions
|
|
146
|
+
1. Create hotfix branch:
|
|
147
|
+
```bash
|
|
148
|
+
git checkout -b hotfix/[issue-id]-[short-description]
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
2. Implement fix:
|
|
152
|
+
- Make smallest possible change
|
|
153
|
+
- Add defensive code if needed
|
|
154
|
+
- Add inline comment explaining fix
|
|
155
|
+
|
|
156
|
+
3. Fix template:
|
|
157
|
+
```typescript
|
|
158
|
+
// HOTFIX: [issue-id] - [brief description]
|
|
159
|
+
// Root cause: [why this fixes it]
|
|
160
|
+
[your fix code]
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
### Gate
|
|
164
|
+
- [ ] Fix implemented
|
|
165
|
+
- [ ] Code compiles
|
|
166
|
+
- [ ] No unrelated changes
|
|
167
|
+
|
|
168
|
+
---
|
|
169
|
+
|
|
170
|
+
## Phase 4: VERIFY
|
|
171
|
+
|
|
172
|
+
**Goal**: Confirm fix works without breaking other things
|
|
173
|
+
|
|
174
|
+
**Time**: 10-15 minutes
|
|
175
|
+
|
|
176
|
+
### Actions
|
|
177
|
+
1. Test the fix:
|
|
178
|
+
- [ ] Original bug no longer occurs
|
|
179
|
+
- [ ] Related functionality still works
|
|
180
|
+
- [ ] Edge cases handled
|
|
181
|
+
|
|
182
|
+
2. Run existing tests:
|
|
183
|
+
```bash
|
|
184
|
+
# Run all tests
|
|
185
|
+
pnpm test # JS/TS
|
|
186
|
+
go test ./... # Go
|
|
187
|
+
flutter test # Flutter
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
3. Add regression test:
|
|
191
|
+
```typescript
|
|
192
|
+
// Test to prevent regression
|
|
193
|
+
it('should [expected behavior] - fixes #[issue-id]', () => {
|
|
194
|
+
// Arrange: setup that caused bug
|
|
195
|
+
// Act: trigger the bug scenario
|
|
196
|
+
// Assert: verify correct behavior
|
|
197
|
+
});
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
4. Manual verification:
|
|
201
|
+
- [ ] Reproduce original steps
|
|
202
|
+
- [ ] Confirm bug is fixed
|
|
203
|
+
- [ ] Test happy path
|
|
204
|
+
- [ ] Test edge cases
|
|
205
|
+
|
|
206
|
+
### Gate
|
|
207
|
+
- [ ] Original bug fixed
|
|
208
|
+
- [ ] All tests pass
|
|
209
|
+
- [ ] Regression test added
|
|
210
|
+
- [ ] No new issues introduced
|
|
211
|
+
|
|
212
|
+
### Feedback Loop
|
|
213
|
+
If verification fails:
|
|
214
|
+
1. Note what failed
|
|
215
|
+
2. Return to FIX phase
|
|
216
|
+
3. Adjust fix
|
|
217
|
+
4. Re-verify
|
|
218
|
+
|
|
219
|
+
---
|
|
220
|
+
|
|
221
|
+
## Phase 5: DEPLOY
|
|
222
|
+
|
|
223
|
+
**Goal**: Ship the fix safely
|
|
224
|
+
|
|
225
|
+
**Time**: 5-10 minutes
|
|
226
|
+
|
|
227
|
+
### Actions
|
|
228
|
+
1. Commit with clear message:
|
|
229
|
+
```bash
|
|
230
|
+
git add .
|
|
231
|
+
git commit -m "fix: [short description] (#[issue-id])
|
|
232
|
+
|
|
233
|
+
Root cause: [brief explanation]
|
|
234
|
+
Fix: [what was changed]
|
|
235
|
+
|
|
236
|
+
Fixes #[issue-id]"
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
2. Create PR:
|
|
240
|
+
```bash
|
|
241
|
+
gh pr create --title "fix: [description]" --body "$(cat <<'EOF'
|
|
242
|
+
## Summary
|
|
243
|
+
Fixes #[issue-id]
|
|
244
|
+
|
|
245
|
+
## Root Cause
|
|
246
|
+
[explanation]
|
|
247
|
+
|
|
248
|
+
## Fix
|
|
249
|
+
[what was changed]
|
|
250
|
+
|
|
251
|
+
## Testing
|
|
252
|
+
- [ ] Original bug no longer occurs
|
|
253
|
+
- [ ] Regression test added
|
|
254
|
+
- [ ] All tests pass
|
|
255
|
+
|
|
256
|
+
## Rollback Plan
|
|
257
|
+
Revert commit: `git revert [commit-sha]`
|
|
258
|
+
EOF
|
|
259
|
+
)"
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
3. Deploy (if applicable):
|
|
263
|
+
```bash
|
|
264
|
+
# Follow your deployment process
|
|
265
|
+
# Monitor for issues
|
|
266
|
+
```
|
|
267
|
+
|
|
268
|
+
### Gate
|
|
269
|
+
- [ ] PR created/merged
|
|
270
|
+
- [ ] Deployed (if applicable)
|
|
271
|
+
- [ ] Monitoring in place
|
|
272
|
+
|
|
273
|
+
---
|
|
274
|
+
|
|
275
|
+
## Phase 6: ROLLBACK (If Needed)
|
|
276
|
+
|
|
277
|
+
**Goal**: Quickly revert if fix causes more problems
|
|
278
|
+
|
|
279
|
+
### When to Rollback
|
|
280
|
+
- [ ] Fix introduced new bugs
|
|
281
|
+
- [ ] Performance degraded
|
|
282
|
+
- [ ] Unexpected side effects
|
|
283
|
+
- [ ] Users reporting new issues
|
|
284
|
+
|
|
285
|
+
### Rollback Actions
|
|
286
|
+
|
|
287
|
+
1. **Quick Revert**:
|
|
288
|
+
```bash
|
|
289
|
+
# Find the hotfix commit
|
|
290
|
+
git log --oneline -5
|
|
291
|
+
|
|
292
|
+
# Revert it
|
|
293
|
+
git revert [hotfix-commit-sha]
|
|
294
|
+
git push
|
|
295
|
+
```
|
|
296
|
+
|
|
297
|
+
2. **Feature Flag** (if available):
|
|
298
|
+
```typescript
|
|
299
|
+
// Disable the fix temporarily
|
|
300
|
+
if (!featureFlags.hotfix_123_enabled) {
|
|
301
|
+
// Original behavior
|
|
302
|
+
}
|
|
303
|
+
```
|
|
304
|
+
|
|
305
|
+
3. **Redeploy previous version**:
|
|
306
|
+
```bash
|
|
307
|
+
# Deploy previous known-good version
|
|
308
|
+
git checkout [previous-tag]
|
|
309
|
+
# Run deploy
|
|
310
|
+
```
|
|
311
|
+
|
|
312
|
+
### Post-Rollback
|
|
313
|
+
1. Document what went wrong
|
|
314
|
+
2. Return to REPRODUCE phase
|
|
315
|
+
3. Analyze why fix failed
|
|
316
|
+
4. Create better fix
|
|
317
|
+
|
|
318
|
+
---
|
|
319
|
+
|
|
320
|
+
## Quick Reference
|
|
321
|
+
|
|
322
|
+
### Hotfix vs Feature
|
|
323
|
+
|
|
324
|
+
| Aspect | Hotfix | Feature |
|
|
325
|
+
|--------|--------|---------|
|
|
326
|
+
| Speed | Fast (< 1 hour) | Thorough |
|
|
327
|
+
| Scope | Minimal | Full |
|
|
328
|
+
| Testing | Targeted | Comprehensive |
|
|
329
|
+
| Design | Skip | Required |
|
|
330
|
+
| Risk | Higher, has rollback | Lower |
|
|
331
|
+
|
|
332
|
+
### Severity Response Time
|
|
333
|
+
|
|
334
|
+
| Severity | Response | Fix Target |
|
|
335
|
+
|----------|----------|------------|
|
|
336
|
+
| 🔴 CRITICAL | Immediate | < 1 hour |
|
|
337
|
+
| 🟠 HIGH | Same day | < 4 hours |
|
|
338
|
+
| 🟡 MEDIUM | Next sprint | < 1 week |
|
|
339
|
+
| 🟢 LOW | Backlog | When convenient |
|
|
340
|
+
|
|
341
|
+
### Commit Message Format
|
|
342
|
+
```
|
|
343
|
+
fix: [short description] (#issue-id)
|
|
344
|
+
|
|
345
|
+
Root cause: [why it happened]
|
|
346
|
+
Fix: [what was changed]
|
|
347
|
+
|
|
348
|
+
Fixes #[issue-id]
|
|
349
|
+
```
|
|
350
|
+
|
|
351
|
+
### Rollback Checklist
|
|
352
|
+
- [ ] Identify rollback commit
|
|
353
|
+
- [ ] Test rollback locally
|
|
354
|
+
- [ ] Execute rollback
|
|
355
|
+
- [ ] Verify system stable
|
|
356
|
+
- [ ] Notify stakeholders
|
|
357
|
+
- [ ] Document learnings
|
|
358
|
+
|
|
359
|
+
---
|
|
360
|
+
|
|
361
|
+
## Emergency Contacts
|
|
362
|
+
|
|
363
|
+
Add your team's emergency contacts here:
|
|
364
|
+
```
|
|
365
|
+
On-call: [contact]
|
|
366
|
+
Backend lead: [contact]
|
|
367
|
+
DevOps: [contact]
|
|
368
|
+
```
|