@amsterdamdatalabs/enact-extensions 0.1.0 → 0.1.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.
Files changed (152) hide show
  1. package/README.md +94 -20
  2. package/dist/index.d.ts +3 -3
  3. package/dist/index.d.ts.map +1 -1
  4. package/dist/index.js +2 -2
  5. package/dist/index.js.map +1 -1
  6. package/dist/install.d.ts +89 -0
  7. package/dist/install.d.ts.map +1 -1
  8. package/dist/install.js +219 -18
  9. package/dist/install.js.map +1 -1
  10. package/dist/validate/index.d.ts +21 -0
  11. package/dist/validate/index.d.ts.map +1 -1
  12. package/dist/validate/index.js +77 -0
  13. package/dist/validate/index.js.map +1 -1
  14. package/extensions/cmux/.agents/plugin.json +37 -0
  15. package/extensions/cmux/skills/cmux/SKILL.md +82 -0
  16. package/extensions/cmux/skills/cmux/agents/openai.yaml +4 -0
  17. package/extensions/cmux/skills/cmux/references/handles-and-identify.md +35 -0
  18. package/extensions/cmux/skills/cmux/references/panes-surfaces.md +37 -0
  19. package/extensions/cmux/skills/cmux/references/trigger-flash-and-health.md +23 -0
  20. package/extensions/cmux/skills/cmux/references/windows-workspaces.md +31 -0
  21. package/extensions/cmux/skills/cmux-vm-monitor/SKILL.md +122 -0
  22. package/extensions/cmux/skills/cmux-vm-monitor/agents/openai.yaml +4 -0
  23. package/extensions/cmux/skills/cmux-vm-monitor/references/cmux-commands.md +66 -0
  24. package/extensions/cmux/skills/cmux-vm-monitor/scripts/codex_vm_monitor.sh +45 -0
  25. package/extensions/cmux/skills/cmux-workspace/SKILL.md +93 -0
  26. package/extensions/dev-state/.agents/plugin.json +35 -0
  27. package/extensions/dev-state/skills/dev-state-plan-graduation/SKILL.md +194 -0
  28. package/extensions/dev-state/skills/dev-state-plan-graduation/agents/openai.yaml +4 -0
  29. package/extensions/dev-state/skills/dev-state-plan-graduation/references/reference.md +130 -0
  30. package/extensions/devops/.agents/plugin.json +36 -0
  31. package/extensions/devops/skills/azure-devops-cli/SKILL.md +431 -0
  32. package/extensions/devops/skills/azure-devops-cli/agents/openai.yaml +4 -0
  33. package/extensions/devops/skills/ci-pipeline-strategy/SKILL.md +217 -0
  34. package/extensions/devops/skills/ci-pipeline-strategy/agents/openai.yaml +4 -0
  35. package/{plugins/net-revenue-management/.codex-plugin → extensions/net-revenue-management/.agents}/plugin.json +10 -6
  36. package/extensions/plugin-dev/.agents/plugin.json +42 -0
  37. package/extensions/plugin-dev/.mcp.json +3 -0
  38. package/extensions/plugin-dev/agents/agent-creator.md +199 -0
  39. package/extensions/plugin-dev/agents/plugin-validator.md +91 -0
  40. package/extensions/plugin-dev/agents/skill-reviewer.md +212 -0
  41. package/extensions/plugin-dev/commands/_archive/create-marketplace.md +427 -0
  42. package/extensions/plugin-dev/commands/_archive/plugin-dev-guide.md +12 -0
  43. package/extensions/plugin-dev/commands/create-plugin.md +498 -0
  44. package/extensions/plugin-dev/commands/start.md +81 -0
  45. package/extensions/plugin-dev/hooks/hooks.json +3 -0
  46. package/extensions/plugin-dev/skills/agent-development/SKILL.md +641 -0
  47. package/extensions/plugin-dev/skills/agent-development/examples/agent-creation-prompt.md +250 -0
  48. package/extensions/plugin-dev/skills/agent-development/examples/complete-agent-examples.md +461 -0
  49. package/extensions/plugin-dev/skills/agent-development/references/advanced-agent-fields.md +246 -0
  50. package/extensions/plugin-dev/skills/agent-development/references/agent-creation-system-prompt.md +216 -0
  51. package/extensions/plugin-dev/skills/agent-development/references/permission-modes-rules.md +226 -0
  52. package/extensions/plugin-dev/skills/agent-development/references/system-prompt-design.md +464 -0
  53. package/extensions/plugin-dev/skills/agent-development/references/triggering-examples.md +474 -0
  54. package/extensions/plugin-dev/skills/agent-development/scripts/create-agent-skeleton.sh +176 -0
  55. package/extensions/plugin-dev/skills/agent-development/scripts/test-agent-trigger.sh +227 -0
  56. package/extensions/plugin-dev/skills/agent-development/scripts/validate-agent.sh +227 -0
  57. package/extensions/plugin-dev/skills/command-development/SKILL.md +763 -0
  58. package/extensions/plugin-dev/skills/command-development/examples/plugin-commands.md +612 -0
  59. package/extensions/plugin-dev/skills/command-development/examples/simple-commands.md +527 -0
  60. package/extensions/plugin-dev/skills/command-development/references/advanced-workflows.md +762 -0
  61. package/extensions/plugin-dev/skills/command-development/references/documentation-patterns.md +769 -0
  62. package/extensions/plugin-dev/skills/command-development/references/frontmatter-reference.md +508 -0
  63. package/extensions/plugin-dev/skills/command-development/references/interactive-commands.md +966 -0
  64. package/extensions/plugin-dev/skills/command-development/references/marketplace-considerations.md +943 -0
  65. package/extensions/plugin-dev/skills/command-development/references/plugin-features-reference.md +637 -0
  66. package/extensions/plugin-dev/skills/command-development/references/plugin-integration.md +191 -0
  67. package/extensions/plugin-dev/skills/command-development/references/skill-tool.md +447 -0
  68. package/extensions/plugin-dev/skills/command-development/references/testing-strategies.md +723 -0
  69. package/extensions/plugin-dev/skills/command-development/scripts/check-frontmatter.sh +234 -0
  70. package/extensions/plugin-dev/skills/command-development/scripts/validate-command.sh +160 -0
  71. package/extensions/plugin-dev/skills/hook-development/SKILL.md +861 -0
  72. package/extensions/plugin-dev/skills/hook-development/examples/load-context.sh +55 -0
  73. package/extensions/plugin-dev/skills/hook-development/examples/validate-bash.sh +57 -0
  74. package/extensions/plugin-dev/skills/hook-development/examples/validate-write.sh +48 -0
  75. package/extensions/plugin-dev/skills/hook-development/references/advanced.md +871 -0
  76. package/extensions/plugin-dev/skills/hook-development/references/hook-input-schemas.md +145 -0
  77. package/extensions/plugin-dev/skills/hook-development/references/migration.md +392 -0
  78. package/extensions/plugin-dev/skills/hook-development/references/patterns.md +430 -0
  79. package/extensions/plugin-dev/skills/hook-development/scripts/README.md +181 -0
  80. package/extensions/plugin-dev/skills/hook-development/scripts/hook-linter.sh +153 -0
  81. package/extensions/plugin-dev/skills/hook-development/scripts/test-hook.sh +276 -0
  82. package/extensions/plugin-dev/skills/hook-development/scripts/validate-hook-schema.sh +159 -0
  83. package/extensions/plugin-dev/skills/mcp-integration/SKILL.md +775 -0
  84. package/extensions/plugin-dev/skills/mcp-integration/examples/http-server.json +20 -0
  85. package/extensions/plugin-dev/skills/mcp-integration/examples/sse-server.json +19 -0
  86. package/extensions/plugin-dev/skills/mcp-integration/examples/stdio-server.json +38 -0
  87. package/extensions/plugin-dev/skills/mcp-integration/examples/ws-server.json +26 -0
  88. package/extensions/plugin-dev/skills/mcp-integration/references/authentication.md +601 -0
  89. package/extensions/plugin-dev/skills/mcp-integration/references/server-discovery.md +190 -0
  90. package/extensions/plugin-dev/skills/mcp-integration/references/server-types.md +572 -0
  91. package/extensions/plugin-dev/skills/mcp-integration/references/tool-usage.md +623 -0
  92. package/extensions/plugin-dev/skills/plugin-dev-guide/SKILL.md +222 -0
  93. package/extensions/plugin-dev/skills/plugin-structure/SKILL.md +705 -0
  94. package/extensions/plugin-dev/skills/plugin-structure/examples/advanced-plugin.md +774 -0
  95. package/extensions/plugin-dev/skills/plugin-structure/examples/minimal-plugin.md +83 -0
  96. package/extensions/plugin-dev/skills/plugin-structure/examples/standard-plugin.md +611 -0
  97. package/extensions/plugin-dev/skills/plugin-structure/references/advanced-topics.md +289 -0
  98. package/extensions/plugin-dev/skills/plugin-structure/references/component-patterns.md +592 -0
  99. package/extensions/plugin-dev/skills/plugin-structure/references/github-actions.md +233 -0
  100. package/extensions/plugin-dev/skills/plugin-structure/references/headless-ci-mode.md +193 -0
  101. package/extensions/plugin-dev/skills/plugin-structure/references/manifest-reference.md +625 -0
  102. package/extensions/plugin-dev/skills/plugin-structure/references/output-styles.md +116 -0
  103. package/extensions/plugin-dev/skills/skill-development/SKILL.md +564 -0
  104. package/extensions/plugin-dev/skills/skill-development/examples/complete-skill.md +465 -0
  105. package/extensions/plugin-dev/skills/skill-development/examples/frontmatter-templates.md +167 -0
  106. package/extensions/plugin-dev/skills/skill-development/examples/minimal-skill.md +111 -0
  107. package/extensions/plugin-dev/skills/skill-development/references/advanced-frontmatter.md +225 -0
  108. package/extensions/plugin-dev/skills/skill-development/references/commands-vs-skills.md +39 -0
  109. package/extensions/plugin-dev/skills/skill-development/references/skill-creation-workflow.md +379 -0
  110. package/extensions/plugin-dev/skills/skill-development/references/skill-creator-original.md +210 -0
  111. package/package.json +8 -11
  112. package/scripts/enact-extensions.mjs +751 -16
  113. package/scripts/hooks/session-start-drift-check.mjs +58 -0
  114. package/scripts/lib/build-index.mjs +50 -0
  115. package/scripts/lib/bundle-hash.mjs +137 -0
  116. package/scripts/lib/hooks.mjs +389 -0
  117. package/scripts/lib/ledger.mjs +162 -0
  118. package/scripts/lib/list-bundles.mjs +70 -0
  119. package/scripts/lib/outdated.mjs +144 -0
  120. package/scripts/lib/provision-mcp.mjs +369 -0
  121. package/scripts/lib/resolve-bundle.mjs +121 -0
  122. package/scripts/lib/run-install.mjs +321 -39
  123. package/scripts/lib/run-uninstall.mjs +220 -0
  124. package/scripts/lib/run-update.mjs +152 -0
  125. package/scripts/lib/run-validate.mjs +12 -18
  126. package/scripts/lib/serve.mjs +454 -0
  127. package/scripts/postinstall.mjs +63 -0
  128. package/scripts/setup-enact-context.sh +2 -2
  129. package/spec/index.json +59 -0
  130. package/web/assets/README.md +111 -0
  131. package/web/assets/logo-full.png +0 -0
  132. package/web/assets/logo-slim.png +0 -0
  133. package/web/assets/tokens/base.css +45 -0
  134. package/web/assets/tokens/colors.css +248 -0
  135. package/web/assets/tokens/effects.css +24 -0
  136. package/web/assets/tokens/fonts.css +8 -0
  137. package/web/assets/tokens/index.css +18 -0
  138. package/web/assets/tokens/spacing.css +50 -0
  139. package/web/index.html +1188 -0
  140. package/.agents/plugins/marketplace.json +0 -20
  141. package/catalog/enact-context.json +0 -9
  142. package/catalog/enact-factory.json +0 -7
  143. package/catalog/enact-operator.json +0 -7
  144. package/catalog/enact-wiki.json +0 -7
  145. package/catalog/net-revenue-management.json +0 -8
  146. package/scripts/rename-supervisor-to-operator.pl +0 -66
  147. package/scripts/sync-manifests.mjs +0 -23
  148. package/scripts/validate-catalog.mjs +0 -37
  149. package/scripts/validate-plugin.mjs +0 -10
  150. /package/{plugins → extensions}/net-revenue-management/.mcp.json +0 -0
  151. /package/{plugins → extensions}/net-revenue-management/skills/net-revenue-risks/SKILL.md +0 -0
  152. /package/{plugins → extensions}/net-revenue-management/skills/net-revenue-scenario/SKILL.md +0 -0
@@ -0,0 +1,625 @@
1
+ # Plugin Manifest Reference
2
+
3
+ Complete reference for `plugin.json` configuration.
4
+
5
+ ## File Location
6
+
7
+ **Required path**: `.claude-plugin/plugin.json`
8
+
9
+ The manifest MUST be in the `.claude-plugin/` directory at the plugin root. Claude Code will not recognize plugins without this file in the correct location.
10
+
11
+ ## Complete Field Reference
12
+
13
+ ### Core Fields
14
+
15
+ #### name (required)
16
+
17
+ **Type**: String
18
+ **Format**: kebab-case
19
+ **Example**: `"test-automation-suite"`
20
+
21
+ The unique identifier for the plugin. Used for:
22
+
23
+ - Plugin identification in Claude Code
24
+ - Conflict detection with other plugins
25
+ - Command namespacing (optional)
26
+
27
+ **Requirements**:
28
+
29
+ - Must be unique across all installed plugins
30
+ - Use only lowercase letters, numbers, and hyphens
31
+ - No spaces or special characters
32
+ - Start with a letter
33
+ - End with a letter or number
34
+
35
+ **Validation**:
36
+
37
+ ```javascript
38
+ /^[a-z][a-z0-9]*(-[a-z0-9]+)*$/;
39
+ ```
40
+
41
+ **Examples**:
42
+
43
+ - ✅ Good: `api-tester`, `code-review`, `git-workflow-automation`
44
+ - ❌ Bad: `API Tester`, `code_review`, `-git-workflow`, `test-`
45
+
46
+ #### version
47
+
48
+ **Type**: String
49
+ **Format**: Semantic versioning (MAJOR.MINOR.PATCH)
50
+ **Example**: `"2.1.0"`
51
+ **Default**: `"0.1.0"` if not specified
52
+
53
+ Semantic versioning guidelines:
54
+
55
+ - **MAJOR**: Incompatible API changes, breaking changes
56
+ - **MINOR**: New functionality, backward-compatible
57
+ - **PATCH**: Bug fixes, backward-compatible
58
+
59
+ **Pre-release versions**:
60
+
61
+ - `"1.0.0-alpha.1"` - Alpha release
62
+ - `"1.0.0-beta.2"` - Beta release
63
+ - `"1.0.0-rc.1"` - Release candidate
64
+
65
+ **Examples**:
66
+
67
+ - `"0.1.0"` - Initial development
68
+ - `"1.0.0"` - First stable release
69
+ - `"1.2.3"` - Patch update to 1.2
70
+ - `"2.0.0"` - Major version with breaking changes
71
+
72
+ #### description
73
+
74
+ **Type**: String
75
+ **Length**: 50-200 characters recommended
76
+ **Example**: `"Automates code review workflows with style checks and automated feedback"`
77
+
78
+ Brief explanation of plugin purpose and functionality.
79
+
80
+ **Best practices**:
81
+
82
+ - Focus on what the plugin does, not how
83
+ - Use active voice
84
+ - Mention key features or benefits
85
+ - Keep under 200 characters for marketplace display
86
+
87
+ **Examples**:
88
+
89
+ - ✅ "Generates comprehensive test suites from code analysis and coverage reports"
90
+ - ✅ "Integrates with Jira for automatic issue tracking and sprint management"
91
+ - ❌ "A plugin that helps you do testing stuff"
92
+ - ❌ "This is a very long description that goes on and on about every single feature..."
93
+
94
+ ### Metadata Fields
95
+
96
+ #### author
97
+
98
+ **Type**: Object
99
+ **Fields**: name (required), email (optional), url (optional)
100
+
101
+ ```json
102
+ {
103
+ "author": {
104
+ "name": "Jane Developer",
105
+ "email": "jane@example.com",
106
+ "url": "https://janedeveloper.com"
107
+ }
108
+ }
109
+ ```
110
+
111
+ **Alternative format** (string only):
112
+
113
+ ```json
114
+ {
115
+ "author": "Jane Developer <jane@example.com> (https://janedeveloper.com)"
116
+ }
117
+ ```
118
+
119
+ **Use cases**:
120
+
121
+ - Credit and attribution
122
+ - Contact for support or questions
123
+ - Marketplace display
124
+ - Community recognition
125
+
126
+ #### homepage
127
+
128
+ **Type**: String (URL)
129
+ **Example**: `"https://docs.example.com/plugins/my-plugin"`
130
+
131
+ Link to plugin documentation or landing page.
132
+
133
+ **Should point to**:
134
+
135
+ - Plugin documentation site
136
+ - Project homepage
137
+ - Detailed usage guide
138
+ - Installation instructions
139
+
140
+ **Not for**:
141
+
142
+ - Source code (use `repository` field)
143
+ - Issue tracker (include in documentation)
144
+ - Personal websites (use `author.url`)
145
+
146
+ #### repository
147
+
148
+ **Type**: String (URL) or Object
149
+ **Example**: `"https://github.com/user/plugin-name"`
150
+
151
+ Source code repository location.
152
+
153
+ **String format**:
154
+
155
+ ```json
156
+ {
157
+ "repository": "https://github.com/user/plugin-name"
158
+ }
159
+ ```
160
+
161
+ **Object format** (detailed):
162
+
163
+ ```json
164
+ {
165
+ "repository": {
166
+ "type": "git",
167
+ "url": "https://github.com/user/plugin-name.git",
168
+ "directory": "packages/plugin-name"
169
+ }
170
+ }
171
+ ```
172
+
173
+ **Use cases**:
174
+
175
+ - Source code access
176
+ - Issue reporting
177
+ - Community contributions
178
+ - Transparency and trust
179
+
180
+ #### license
181
+
182
+ **Type**: String
183
+ **Format**: SPDX identifier
184
+ **Example**: `"MIT"`
185
+
186
+ Software license identifier.
187
+
188
+ **Common licenses**:
189
+
190
+ - `"MIT"` - Permissive, popular choice
191
+ - `"Apache-2.0"` - Permissive with patent grant
192
+ - `"GPL-3.0"` - Copyleft
193
+ - `"BSD-3-Clause"` - Permissive
194
+ - `"ISC"` - Permissive, similar to MIT
195
+ - `"UNLICENSED"` - Proprietary, not open source
196
+
197
+ **Full list**: <https://spdx.org/licenses/>
198
+
199
+ **Multiple licenses**:
200
+
201
+ ```json
202
+ {
203
+ "license": "(MIT OR Apache-2.0)"
204
+ }
205
+ ```
206
+
207
+ #### keywords
208
+
209
+ **Type**: Array of strings
210
+ **Example**: `["testing", "automation", "ci-cd", "quality-assurance"]`
211
+
212
+ Tags for plugin discovery and categorization.
213
+
214
+ **Best practices**:
215
+
216
+ - Use 5-10 keywords
217
+ - Include functionality categories
218
+ - Add technology names
219
+ - Use common search terms
220
+ - Avoid duplicating plugin name
221
+
222
+ **Categories to consider**:
223
+
224
+ - Functionality: `testing`, `debugging`, `documentation`, `deployment`
225
+ - Technologies: `typescript`, `python`, `docker`, `aws`
226
+ - Workflows: `ci-cd`, `code-review`, `git-workflow`
227
+ - Domains: `web-development`, `data-science`, `devops`
228
+
229
+ ### Component Path Fields
230
+
231
+ #### commands
232
+
233
+ **Type**: String or Array of strings
234
+ **Default**: `["./commands"]`
235
+ **Example**: `"./cli-commands"`
236
+
237
+ Additional directories or files containing command definitions.
238
+
239
+ **Single path**:
240
+
241
+ ```json
242
+ {
243
+ "commands": "./custom-commands"
244
+ }
245
+ ```
246
+
247
+ **Multiple paths**:
248
+
249
+ ```json
250
+ {
251
+ "commands": ["./commands", "./admin-commands", "./experimental-commands"]
252
+ }
253
+ ```
254
+
255
+ **Behavior**: Supplements default `commands/` directory (does not replace)
256
+
257
+ **Use cases**:
258
+
259
+ - Organizing commands by category
260
+ - Separating stable from experimental commands
261
+ - Loading commands from shared locations
262
+
263
+ #### agents
264
+
265
+ **Type**: String or Array of strings
266
+ **Default**: `["./agents"]`
267
+ **Example**: `"./specialized-agents"`
268
+
269
+ Additional directories or files containing agent definitions.
270
+
271
+ **Format**: Same as `commands` field
272
+
273
+ **Use cases**:
274
+
275
+ - Grouping agents by specialization
276
+ - Separating general-purpose from task-specific agents
277
+ - Loading agents from plugin dependencies
278
+
279
+ #### hooks
280
+
281
+ **Type**: String (path to JSON file) or Object (inline configuration)
282
+ **Default**: `"./hooks/hooks.json"`
283
+
284
+ Hook configuration location or inline definition.
285
+
286
+ **File path**:
287
+
288
+ ```json
289
+ {
290
+ "hooks": "./config/hooks.json"
291
+ }
292
+ ```
293
+
294
+ **Inline configuration**:
295
+
296
+ ```json
297
+ {
298
+ "hooks": {
299
+ "PreToolUse": [
300
+ {
301
+ "matcher": "Write",
302
+ "hooks": [
303
+ {
304
+ "type": "command",
305
+ "command": "bash ${CLAUDE_PLUGIN_ROOT}/scripts/validate.sh",
306
+ "timeout": 30
307
+ }
308
+ ]
309
+ }
310
+ ]
311
+ }
312
+ }
313
+ ```
314
+
315
+ **Use cases**:
316
+
317
+ - Simple plugins: Inline configuration (< 50 lines)
318
+ - Complex plugins: External JSON file
319
+ - Multiple hook sets: Separate files for different contexts
320
+
321
+ #### mcpServers
322
+
323
+ **Type**: String (path to JSON file) or Object (inline configuration)
324
+ **Default**: `./.mcp.json`
325
+
326
+ MCP server configuration location or inline definition.
327
+
328
+ **File path**:
329
+
330
+ ```json
331
+ {
332
+ "mcpServers": "./.mcp.json"
333
+ }
334
+ ```
335
+
336
+ **Inline configuration**:
337
+
338
+ ```json
339
+ {
340
+ "mcpServers": {
341
+ "github": {
342
+ "command": "node",
343
+ "args": ["${CLAUDE_PLUGIN_ROOT}/servers/github-mcp.js"],
344
+ "env": {
345
+ "GITHUB_TOKEN": "${GITHUB_TOKEN}"
346
+ }
347
+ }
348
+ }
349
+ }
350
+ ```
351
+
352
+ **Use cases**:
353
+
354
+ - Simple plugins: Single inline server (< 20 lines)
355
+ - Complex plugins: External `.mcp.json` file
356
+ - Multiple servers: Always use external file
357
+
358
+ #### outputStyles
359
+
360
+ **Type**: String or Array of strings
361
+ **Default**: `["./output-styles"]`
362
+ **Example**: `"./styles"`
363
+
364
+ Path(s) to output style definition files or directories.
365
+
366
+ **Single path**:
367
+
368
+ ```json
369
+ {
370
+ "outputStyles": "./styles"
371
+ }
372
+ ```
373
+
374
+ **Multiple paths**:
375
+
376
+ ```json
377
+ {
378
+ "outputStyles": ["./styles/default.md", "./styles/compact.md"]
379
+ }
380
+ ```
381
+
382
+ **Behavior**: Supplements default `output-styles/` directory (does not replace)
383
+
384
+ Output style files are markdown with YAML frontmatter (`name`, `description`, `keep-coding-instructions`). See the plugin-structure skill's `references/output-styles.md` for the complete frontmatter schema.
385
+
386
+ **Use cases**:
387
+
388
+ - Providing domain-specific formatting (e.g., concise code review output)
389
+ - Bundling multiple style options for users to choose from
390
+ - Offering specialized output modes for different workflows
391
+
392
+ ## Path Resolution
393
+
394
+ ### Relative Path Rules
395
+
396
+ All paths in component fields must follow these rules:
397
+
398
+ 1. **Must be relative**: No absolute paths
399
+ 2. **Must start with `./`**: Indicates relative to plugin root
400
+ 3. **Cannot use `../`**: No parent directory navigation
401
+ 4. **Forward slashes only**: Even on Windows
402
+
403
+ **Examples**:
404
+
405
+ - ✅ `"./commands"`
406
+ - ✅ `"./src/commands"`
407
+ - ✅ `"./configs/hooks.json"`
408
+ - ❌ `"/Users/name/plugin/commands"`
409
+ - ❌ `"commands"` (missing `./`)
410
+ - ❌ `"../shared/commands"`
411
+ - ❌ `".\\commands"` (backslash)
412
+
413
+ ### Resolution Order
414
+
415
+ When Claude Code loads components:
416
+
417
+ 1. **Default directories**: Scans standard locations first
418
+ - `./commands/`
419
+ - `./agents/`
420
+ - `./skills/`
421
+ - `./hooks/hooks.json`
422
+ - `./.mcp.json`
423
+
424
+ 2. **Custom paths**: Scans paths specified in manifest
425
+ - Paths from `commands` field
426
+ - Paths from `agents` field
427
+ - Files from `hooks` and `mcpServers` fields
428
+
429
+ 3. **Merge behavior**: Components from all locations load
430
+ - No overwriting
431
+ - All discovered components register
432
+ - Name conflicts cause errors
433
+
434
+ ## Validation
435
+
436
+ ### Manifest Validation
437
+
438
+ Claude Code validates the manifest on plugin load:
439
+
440
+ **Syntax validation**:
441
+
442
+ - Valid JSON format
443
+ - No syntax errors
444
+ - Correct field types
445
+
446
+ **Field validation**:
447
+
448
+ - `name` field present and valid format
449
+ - `version` follows semantic versioning (if present)
450
+ - Paths are relative with `./` prefix
451
+ - URLs are valid (if present)
452
+
453
+ **Component validation**:
454
+
455
+ - Referenced paths exist
456
+ - Hook and MCP configurations are valid
457
+ - No circular dependencies
458
+
459
+ ### Common Validation Errors
460
+
461
+ **Invalid name format**:
462
+
463
+ ```json
464
+ {
465
+ "name": "My Plugin" // ❌ Contains spaces
466
+ }
467
+ ```
468
+
469
+ Fix: Use kebab-case
470
+
471
+ ```json
472
+ {
473
+ "name": "my-plugin" // ✅
474
+ }
475
+ ```
476
+
477
+ **Absolute path**:
478
+
479
+ ```json
480
+ {
481
+ "commands": "/Users/name/commands" // ❌ Absolute path
482
+ }
483
+ ```
484
+
485
+ Fix: Use relative path
486
+
487
+ ```json
488
+ {
489
+ "commands": "./commands" // ✅
490
+ }
491
+ ```
492
+
493
+ **Missing ./ prefix**:
494
+
495
+ ```json
496
+ {
497
+ "hooks": "hooks/hooks.json" // ❌ No ./
498
+ }
499
+ ```
500
+
501
+ Fix: Add ./ prefix
502
+
503
+ ```json
504
+ {
505
+ "hooks": "./hooks/hooks.json" // ✅
506
+ }
507
+ ```
508
+
509
+ **Invalid version**:
510
+
511
+ ```json
512
+ {
513
+ "version": "1.0" // ❌ Not semantic versioning
514
+ }
515
+ ```
516
+
517
+ Fix: Use MAJOR.MINOR.PATCH
518
+
519
+ ```json
520
+ {
521
+ "version": "1.0.0" // ✅
522
+ }
523
+ ```
524
+
525
+ ## Minimal vs. Complete Examples
526
+
527
+ ### Minimal Plugin
528
+
529
+ Bare minimum for a working plugin:
530
+
531
+ ```json
532
+ {
533
+ "name": "hello-world"
534
+ }
535
+ ```
536
+
537
+ Relies entirely on default directory discovery.
538
+
539
+ ### Recommended Plugin
540
+
541
+ Good metadata for distribution:
542
+
543
+ ```json
544
+ {
545
+ "name": "code-review-assistant",
546
+ "version": "1.0.0",
547
+ "description": "Automates code review with style checks and suggestions",
548
+ "author": {
549
+ "name": "Jane Developer",
550
+ "email": "jane@example.com"
551
+ },
552
+ "homepage": "https://docs.example.com/code-review",
553
+ "repository": "https://github.com/janedev/code-review-assistant",
554
+ "license": "MIT",
555
+ "keywords": ["code-review", "automation", "quality", "ci-cd"]
556
+ }
557
+ ```
558
+
559
+ ### Complete Plugin
560
+
561
+ Full configuration with all features:
562
+
563
+ ```json
564
+ {
565
+ "name": "enterprise-devops",
566
+ "version": "2.3.1",
567
+ "description": "Comprehensive DevOps automation for enterprise CI/CD pipelines",
568
+ "author": {
569
+ "name": "DevOps Team",
570
+ "email": "devops@company.com",
571
+ "url": "https://company.com/devops"
572
+ },
573
+ "homepage": "https://docs.company.com/plugins/devops",
574
+ "repository": {
575
+ "type": "git",
576
+ "url": "https://github.com/company/devops-plugin.git"
577
+ },
578
+ "license": "Apache-2.0",
579
+ "keywords": [
580
+ "devops",
581
+ "ci-cd",
582
+ "automation",
583
+ "kubernetes",
584
+ "docker",
585
+ "deployment"
586
+ ],
587
+ "commands": ["./commands", "./admin-commands"],
588
+ "agents": "./specialized-agents",
589
+ "hooks": "./config/hooks.json",
590
+ "mcpServers": "./.mcp.json"
591
+ }
592
+ ```
593
+
594
+ ## Best Practices
595
+
596
+ ### Metadata
597
+
598
+ 1. **Always include version**: Track changes and updates
599
+ 2. **Write clear descriptions**: Help users understand plugin purpose
600
+ 3. **Provide contact information**: Enable user support
601
+ 4. **Link to documentation**: Reduce support burden
602
+ 5. **Choose appropriate license**: Match project goals
603
+
604
+ ### Paths
605
+
606
+ 1. **Use defaults when possible**: Minimize configuration
607
+ 2. **Organize logically**: Group related components
608
+ 3. **Document custom paths**: Explain why non-standard layout used
609
+ 4. **Test path resolution**: Verify on multiple systems
610
+
611
+ ### Maintenance
612
+
613
+ 1. **Bump version on changes**: Follow semantic versioning
614
+ 2. **Update keywords**: Reflect new functionality
615
+ 3. **Keep description current**: Match actual capabilities
616
+ 4. **Maintain changelog**: Track version history
617
+ 5. **Update repository links**: Keep URLs current
618
+
619
+ ### Distribution
620
+
621
+ 1. **Complete metadata before publishing**: All fields filled
622
+ 2. **Test on clean install**: Verify plugin works without dev environment
623
+ 3. **Validate manifest**: Use validation tools
624
+ 4. **Include README**: Document installation and usage
625
+ 5. **Specify license file**: Include LICENSE file in plugin root