@codihaus/claude-skills 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 +167 -0
- package/bin/cli.js +58 -0
- package/package.json +46 -0
- package/skills/_quality-attributes.md +392 -0
- package/skills/_registry.md +189 -0
- package/skills/debrief/SKILL.md +647 -0
- package/skills/debrief/references/change-request-template.md +124 -0
- package/skills/debrief/references/file-patterns.md +173 -0
- package/skills/debrief/references/group-codes.md +72 -0
- package/skills/debrief/references/research-queries.md +106 -0
- package/skills/debrief/references/use-case-template.md +141 -0
- package/skills/debrief/scripts/generate_questionnaire.py +195 -0
- package/skills/dev-arch/SKILL.md +747 -0
- package/skills/dev-changelog/SKILL.md +378 -0
- package/skills/dev-coding/SKILL.md +470 -0
- package/skills/dev-coding-backend/SKILL.md +361 -0
- package/skills/dev-coding-frontend/SKILL.md +534 -0
- package/skills/dev-coding-frontend/references/nextjs.md +477 -0
- package/skills/dev-review/SKILL.md +548 -0
- package/skills/dev-scout/SKILL.md +723 -0
- package/skills/dev-scout/references/feature-patterns.md +210 -0
- package/skills/dev-scout/references/file-patterns.md +252 -0
- package/skills/dev-scout/references/tech-detection.md +211 -0
- package/skills/dev-scout/scripts/scout-analyze.sh +280 -0
- package/skills/dev-specs/SKILL.md +577 -0
- package/skills/dev-specs/references/checklist.md +176 -0
- package/skills/dev-specs/references/spec-templates.md +460 -0
- package/skills/dev-test/SKILL.md +364 -0
- package/skills/utils/diagram/SKILL.md +205 -0
- package/skills/utils/diagram/references/common-errors.md +305 -0
- package/skills/utils/diagram/references/diagram-types.md +636 -0
- package/skills/utils/docs-graph/SKILL.md +204 -0
- package/skills/utils/gemini/SKILL.md +292 -0
- package/skills/utils/gemini/scripts/gemini-scan.py +340 -0
- package/skills/utils/gemini/scripts/setup.sh +169 -0
- package/src/commands/add.js +64 -0
- package/src/commands/doctor.js +179 -0
- package/src/commands/init.js +251 -0
- package/src/commands/list.js +88 -0
- package/src/commands/remove.js +60 -0
- package/src/commands/update.js +72 -0
- package/src/index.js +26 -0
- package/src/utils/config.js +272 -0
- package/src/utils/deps.js +599 -0
- package/src/utils/skills.js +253 -0
- package/templates/CLAUDE.md.template +58 -0
|
@@ -0,0 +1,305 @@
|
|
|
1
|
+
# Common Mermaid Errors
|
|
2
|
+
|
|
3
|
+
Error patterns and auto-fix solutions.
|
|
4
|
+
|
|
5
|
+
## Reserved Words
|
|
6
|
+
|
|
7
|
+
**Error**: `Parse error on line X`
|
|
8
|
+
|
|
9
|
+
**Cause**: Using reserved words as node IDs.
|
|
10
|
+
|
|
11
|
+
**Reserved words**:
|
|
12
|
+
- `end`, `End`, `END`
|
|
13
|
+
- `graph`, `subgraph`
|
|
14
|
+
- `style`, `class`
|
|
15
|
+
- `click`, `link`
|
|
16
|
+
|
|
17
|
+
**Fix**: Wrap in quotes.
|
|
18
|
+
|
|
19
|
+
```diff
|
|
20
|
+
- A --> End
|
|
21
|
+
+ A --> "End"
|
|
22
|
+
|
|
23
|
+
- graph --> process
|
|
24
|
+
+ "graph" --> process
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Special Characters in Text
|
|
28
|
+
|
|
29
|
+
**Error**: `Lexical error` or `Parse error`
|
|
30
|
+
|
|
31
|
+
**Cause**: Unquoted special characters.
|
|
32
|
+
|
|
33
|
+
**Problem characters**: `( ) [ ] { } < > | # ; :`
|
|
34
|
+
|
|
35
|
+
**Fix**: Wrap text containing special chars in quotes.
|
|
36
|
+
|
|
37
|
+
```diff
|
|
38
|
+
- A[User (Admin)]
|
|
39
|
+
+ A["User (Admin)"]
|
|
40
|
+
|
|
41
|
+
- B{Is count > 10?}
|
|
42
|
+
+ B{"Is count > 10?"}
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
## Arrow Syntax
|
|
46
|
+
|
|
47
|
+
**Error**: `Parse error` near arrow
|
|
48
|
+
|
|
49
|
+
**Cause**: Wrong arrow format.
|
|
50
|
+
|
|
51
|
+
| Wrong | Correct | Type |
|
|
52
|
+
|-------|---------|------|
|
|
53
|
+
| `->` | `-->` | Flowchart arrow |
|
|
54
|
+
| `—>` | `-->` | Wrong dash character |
|
|
55
|
+
| `>>` | `->>` | Sequence arrow |
|
|
56
|
+
|
|
57
|
+
**Fix**: Use correct arrow syntax per diagram type.
|
|
58
|
+
|
|
59
|
+
```diff
|
|
60
|
+
# Flowchart
|
|
61
|
+
- A -> B
|
|
62
|
+
+ A --> B
|
|
63
|
+
|
|
64
|
+
# Sequence
|
|
65
|
+
- User -> API: Request
|
|
66
|
+
+ User ->> API: Request
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
## Subgraph Not Closed
|
|
70
|
+
|
|
71
|
+
**Error**: `Parse error` at end of diagram
|
|
72
|
+
|
|
73
|
+
**Cause**: Missing `end` for subgraph.
|
|
74
|
+
|
|
75
|
+
**Fix**: Add `end` keyword.
|
|
76
|
+
|
|
77
|
+
```diff
|
|
78
|
+
subgraph Backend
|
|
79
|
+
API --> DB
|
|
80
|
+
+ end
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
## Invalid Node IDs
|
|
84
|
+
|
|
85
|
+
**Error**: `Parse error` on node definition
|
|
86
|
+
|
|
87
|
+
**Cause**: Node ID starts with number or contains invalid chars.
|
|
88
|
+
|
|
89
|
+
**Valid IDs**: Start with letter, contain letters/numbers/underscore.
|
|
90
|
+
|
|
91
|
+
**Fix**: Use valid identifier.
|
|
92
|
+
|
|
93
|
+
```diff
|
|
94
|
+
- 1user --> 2admin
|
|
95
|
+
+ user1 --> admin2
|
|
96
|
+
|
|
97
|
+
- user-login --> dashboard
|
|
98
|
+
+ userLogin --> dashboard
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
## Missing Diagram Type
|
|
102
|
+
|
|
103
|
+
**Error**: First line parse error
|
|
104
|
+
|
|
105
|
+
**Cause**: No diagram type declaration.
|
|
106
|
+
|
|
107
|
+
**Fix**: Add diagram type as first line.
|
|
108
|
+
|
|
109
|
+
```diff
|
|
110
|
+
+ flowchart LR
|
|
111
|
+
A --> B --> C
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
## Duplicate Node IDs with Different Shapes
|
|
115
|
+
|
|
116
|
+
**Error**: Inconsistent rendering
|
|
117
|
+
|
|
118
|
+
**Cause**: Same ID with different shapes.
|
|
119
|
+
|
|
120
|
+
```mermaid
|
|
121
|
+
# Problem
|
|
122
|
+
A[Rectangle] --> B
|
|
123
|
+
A(Rounded) --> C # A already defined as rectangle
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
**Fix**: Use unique IDs.
|
|
127
|
+
|
|
128
|
+
```diff
|
|
129
|
+
- A[User] --> B
|
|
130
|
+
- A(Admin) --> C
|
|
131
|
+
+ User[User] --> B
|
|
132
|
+
+ Admin(Admin) --> C
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
## Comments Breaking Diagrams
|
|
136
|
+
|
|
137
|
+
**Error**: Parse error in comment area
|
|
138
|
+
|
|
139
|
+
**Cause**: Using `//` or `/* */` instead of `%%`.
|
|
140
|
+
|
|
141
|
+
**Fix**: Use mermaid comment syntax.
|
|
142
|
+
|
|
143
|
+
```diff
|
|
144
|
+
- // This is a comment
|
|
145
|
+
+ %% This is a comment
|
|
146
|
+
|
|
147
|
+
- A --> B // inline
|
|
148
|
+
+ A --> B
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
## Curly Braces in Text
|
|
152
|
+
|
|
153
|
+
**Error**: Unexpected token
|
|
154
|
+
|
|
155
|
+
**Cause**: `{}` in node text or comments.
|
|
156
|
+
|
|
157
|
+
**Fix**: Avoid or escape braces.
|
|
158
|
+
|
|
159
|
+
```diff
|
|
160
|
+
- A["Object {key: value}"]
|
|
161
|
+
+ A["Object with key-value"]
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
## Architecture Diagram Errors
|
|
165
|
+
|
|
166
|
+
### Invalid Edge Direction
|
|
167
|
+
|
|
168
|
+
**Error**: `Parse error` on edge definition
|
|
169
|
+
|
|
170
|
+
**Cause**: Missing or invalid direction (L/R/T/B).
|
|
171
|
+
|
|
172
|
+
**Fix**: Add direction on both sides.
|
|
173
|
+
|
|
174
|
+
```diff
|
|
175
|
+
- db --> server
|
|
176
|
+
+ db:R --> L:server
|
|
177
|
+
|
|
178
|
+
- db:R --> server
|
|
179
|
+
+ db:R --> L:server
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
### Missing Group Parent
|
|
183
|
+
|
|
184
|
+
**Error**: Group reference not found
|
|
185
|
+
|
|
186
|
+
**Cause**: Nested group references non-existent parent.
|
|
187
|
+
|
|
188
|
+
**Fix**: Define parent group first.
|
|
189
|
+
|
|
190
|
+
```diff
|
|
191
|
+
+ group api(cloud)[API]
|
|
192
|
+
group db(cloud)[Database] in api
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
### Invalid Service in Group
|
|
196
|
+
|
|
197
|
+
**Error**: Service parent not found
|
|
198
|
+
|
|
199
|
+
**Cause**: Service references non-existent group.
|
|
200
|
+
|
|
201
|
+
**Fix**: Ensure group exists.
|
|
202
|
+
|
|
203
|
+
```diff
|
|
204
|
+
+ group backend(cloud)[Backend]
|
|
205
|
+
service api(server)[API] in backend
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
### Invalid Icon Name
|
|
209
|
+
|
|
210
|
+
**Error**: Icon not recognized
|
|
211
|
+
|
|
212
|
+
**Cause**: Using unsupported icon name.
|
|
213
|
+
|
|
214
|
+
**Default icons**: `cloud`, `database`, `disk`, `internet`, `server`
|
|
215
|
+
|
|
216
|
+
**Fix**: Use valid icon or register custom pack.
|
|
217
|
+
|
|
218
|
+
```diff
|
|
219
|
+
- service lambda(aws-lambda)[Lambda]
|
|
220
|
+
+ service lambda(server)[Lambda]
|
|
221
|
+
%% Or register iconify pack for custom icons
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
## XY Chart Errors
|
|
225
|
+
|
|
226
|
+
### Missing Axis Definition
|
|
227
|
+
|
|
228
|
+
**Error**: Axis not defined
|
|
229
|
+
|
|
230
|
+
**Fix**: Add x-axis and y-axis.
|
|
231
|
+
|
|
232
|
+
```diff
|
|
233
|
+
xychart-beta
|
|
234
|
+
+ x-axis [Jan, Feb, Mar]
|
|
235
|
+
+ y-axis "Value" 0 --> 100
|
|
236
|
+
bar [10, 20, 30]
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
### Mismatched Data Points
|
|
240
|
+
|
|
241
|
+
**Error**: Data length mismatch
|
|
242
|
+
|
|
243
|
+
**Cause**: Bar/line data doesn't match x-axis length.
|
|
244
|
+
|
|
245
|
+
**Fix**: Ensure same number of data points.
|
|
246
|
+
|
|
247
|
+
```diff
|
|
248
|
+
x-axis [Jan, Feb, Mar]
|
|
249
|
+
- bar [10, 20]
|
|
250
|
+
+ bar [10, 20, 30]
|
|
251
|
+
```
|
|
252
|
+
|
|
253
|
+
## Sankey Errors
|
|
254
|
+
|
|
255
|
+
### Invalid CSV Format
|
|
256
|
+
|
|
257
|
+
**Error**: Parse error in data
|
|
258
|
+
|
|
259
|
+
**Cause**: Wrong delimiter or missing values.
|
|
260
|
+
|
|
261
|
+
**Fix**: Use comma-separated format: `source,target,value`
|
|
262
|
+
|
|
263
|
+
```diff
|
|
264
|
+
- Revenue -> Operations: 40
|
|
265
|
+
+ Revenue,Operations,40
|
|
266
|
+
```
|
|
267
|
+
|
|
268
|
+
## Quadrant Errors
|
|
269
|
+
|
|
270
|
+
### Invalid Coordinates
|
|
271
|
+
|
|
272
|
+
**Error**: Point position error
|
|
273
|
+
|
|
274
|
+
**Cause**: Coordinates outside 0.0-1.0 range.
|
|
275
|
+
|
|
276
|
+
**Fix**: Use decimal values between 0 and 1.
|
|
277
|
+
|
|
278
|
+
```diff
|
|
279
|
+
- Feature A: [80, 90]
|
|
280
|
+
+ Feature A: [0.8, 0.9]
|
|
281
|
+
```
|
|
282
|
+
|
|
283
|
+
## Auto-Fix Priority
|
|
284
|
+
|
|
285
|
+
When fixing, apply in this order:
|
|
286
|
+
|
|
287
|
+
1. **Reserved words** → Quote them
|
|
288
|
+
2. **Special chars** → Quote the text
|
|
289
|
+
3. **Arrow syntax** → Replace with correct
|
|
290
|
+
4. **Edge direction** → Add L/R/T/B
|
|
291
|
+
5. **Missing end** → Add `end`
|
|
292
|
+
6. **Invalid IDs** → Rename
|
|
293
|
+
7. **Comments** → Convert to `%%`
|
|
294
|
+
|
|
295
|
+
## Validation Command
|
|
296
|
+
|
|
297
|
+
```bash
|
|
298
|
+
# Validate single diagram
|
|
299
|
+
echo 'flowchart LR
|
|
300
|
+
A --> B' > /tmp/test.mmd
|
|
301
|
+
mmdc -i /tmp/test.mmd -o /tmp/test.svg 2>&1
|
|
302
|
+
|
|
303
|
+
# Check exit code
|
|
304
|
+
echo $? # 0 = valid, non-zero = error
|
|
305
|
+
```
|