Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ claude-code-plugins/
│ ├── mcp-neo4j/ # Neo4j MCP server
│ ├── chrome-devtools-mcp/ # Chrome DevTools automation
│ └── context7/ # Up-to-date library documentation
├── plugins/ # Built-in plugins (maintained in this repo)
│ ├── gatekeeper/ # Auto-approve safe commands
│ ├── plugin-dev/ # Plugin development tools
│ └── ... # Framework-specific plugins (antfu, nuxt, vue, etc.)
├── apps/web/ # Marketplace website
├── .claude-plugin/ # Marketplace configuration
└── hooks/ # Session hooks
Expand Down Expand Up @@ -169,7 +173,6 @@ When integrating an existing MCP server or tool as a Claude Code plugin:
"repository": "https://github.com/org/tool-repo",
"license": "MIT",
"keywords": ["keyword1", "keyword2"],
"hooks": "./hooks/hooks.json",
"mcpServers": {
"server-name": {
"command": "npx",
Expand Down Expand Up @@ -322,6 +325,10 @@ When integrating an existing MCP server or tool as a Claude Code plugin:
- `hooks/`, `commands/`, `agents/` directories at plugin root
- Use `${CLAUDE_PLUGIN_ROOT}` for all path references

**Hooks Auto-Loading:**
- `hooks/hooks.json` is auto-loaded by Claude Code — do NOT reference it in `plugin.json`'s `hooks` field

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

This is a helpful clarification. To make it even more impactful, you could briefly mention the consequence of not following this practice. This helps developers understand the importance of the rule.

Here's a suggested rephrasing. Please remember to wrap file paths and field names (like hooks/hooks.json and plugin.json) in backticks for proper markdown formatting.

Suggested change
- `hooks/hooks.json` is auto-loaded by Claude Code — do NOT reference it in `plugin.json`'s `hooks` field
- hooks/hooks.json is auto-loaded by Claude Code. Avoid referencing it in plugin.json's hooks field to prevent duplicate hook warnings.

- `plugin.json`'s `hooks` field should only reference ADDITIONAL hook files beyond the standard path

**Documentation:**
- Include Claude Code installation in plugin README
- Explain automatic features (SessionStart hooks)
Expand Down
3 changes: 1 addition & 2 deletions plugins/gatekeeper/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,5 @@
},
"repository": "https://github.com/pleaseai/claude-code-plugins",
"license": "MIT",
"keywords": ["security", "permissions", "gatekeeper", "hook"],
"hooks": "./hooks/hooks.json"
"keywords": ["security", "permissions", "gatekeeper", "hook"]
}