Crush Configuration
charmbracelet/crush
Explains how to configure the Crush coding agent with crushrc or crush.json, covering providers, models, LSPs, MCP servers, hooks, permissions and config precedence.
Official agent skill
Explains how to write Claude Code plugin hooks, both prompt-based checks and bash commands, for events such as PreToolUse, Stop and SessionStart.
$ npx skills add anthropics/claude-plugins-official --skill hook-development -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install anthropics/claude-plugins-official hook-development --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/anthropics/claude-plugins-official.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/plugin-dev/skills/hook-development .claude/skills/hook-development && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "hook-development" agent skill from https://github.com/anthropics/claude-plugins-official/tree/main/plugins/plugin-dev/skills/hook-development into .claude/skills/hook-development/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hook-development", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/anthropics/claude-plugins-official/tree/main/plugins/plugin-dev/skills/hook-developmentType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add anthropics/claude-plugins-official --skill hook-development -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install anthropics/claude-plugins-official hook-development --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/anthropics/claude-plugins-official.git skills-src && mkdir -p .agents/skills && cp -r skills-src/plugins/plugin-dev/skills/hook-development .agents/skills/hook-development && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "hook-development" agent skill from https://github.com/anthropics/claude-plugins-official/tree/main/plugins/plugin-dev/skills/hook-development into .agents/skills/hook-development/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hook-development", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add anthropics/claude-plugins-official --skill hook-development -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install anthropics/claude-plugins-official hook-development --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/anthropics/claude-plugins-official.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/plugins/plugin-dev/skills/hook-development .cursor/skills/hook-development && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "hook-development" agent skill from https://github.com/anthropics/claude-plugins-official/tree/main/plugins/plugin-dev/skills/hook-development into .cursor/skills/hook-development/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hook-development", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/anthropics/claude-plugins-official.git --path plugins/plugin-dev/skills/hook-development--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add anthropics/claude-plugins-official --skill hook-development -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install anthropics/claude-plugins-official hook-development --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/anthropics/claude-plugins-official.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/plugins/plugin-dev/skills/hook-development .gemini/skills/hook-development && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "hook-development" agent skill from https://github.com/anthropics/claude-plugins-official/tree/main/plugins/plugin-dev/skills/hook-development into .gemini/skills/hook-development/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hook-development", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install anthropics/claude-plugins-official hook-developmentInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add anthropics/claude-plugins-official --skill hook-development -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/anthropics/claude-plugins-official.git skills-src && mkdir -p .github/skills && cp -r skills-src/plugins/plugin-dev/skills/hook-development .github/skills/hook-development && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "hook-development" agent skill from https://github.com/anthropics/claude-plugins-official/tree/main/plugins/plugin-dev/skills/hook-development into .github/skills/hook-development/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hook-development", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add anthropics/claude-plugins-official --skill hook-development -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install anthropics/claude-plugins-official hook-development --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/anthropics/claude-plugins-official.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/plugins/plugin-dev/skills/hook-development .opencode/skills/hook-development && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "hook-development" agent skill from https://github.com/anthropics/claude-plugins-official/tree/main/plugins/plugin-dev/skills/hook-development into .opencode/skills/hook-development/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "hook-development", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
hook-developmentExplains how to write Claude Code plugin hooks, both prompt-based checks and bash commands, for events such as PreToolUse, Stop and SessionStart.
Hooks are scripts or prompts that Claude Code runs when an event fires. This skill describes the event types (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification) and what each is good for: approving or denying tool calls, reacting to results, enforcing completion standards or loading project context when a session starts.
It recommends prompt-based hooks, where a model judges the situation in natural language, and keeps command hooks for fast deterministic checks. It spells out the two configuration formats, the wrapped hooks/hooks.json used by plugins and the direct format in .claude/settings.json, and the CLAUDE_PLUGIN_ROOT variable. Example scripts validate bash commands and file writes, and helper scripts lint hooks, test them and check their schema.
4 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit b78ac49. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Ships 4 files in scripts/ (Shell), which the agent can run.
Shell commands in SKILL.md call:
jqclaudebashFrom the folder's file list and the shell code blocks in SKILL.md.
Links to these hosts (documentation or services it may open):
docs.claude.comFrom URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Hook Development for Claude Code Plugins loads about 4.1k tokens when it runs, and up to ~10k if it reads all its reference files. Until then it costs about 136 tokens; SKILL.md has 1,146 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check noted patterns worth knowing about, such as sudo or a known installer.
if [[ "$file_path" == *".env"* ]]; thenAutomated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.
The full file from anthropics/claude-plugins-official at commit b78ac49, republished under its Apache-2.0 licence (© anthropics). 1,146 words, ~4,055 tokens.
.claude/skills/hook-development/SKILL.md (or your agent's skills folder). This skill also uses 10 other files; get the full folder from GitHub.Hooks are event-driven automation scripts that execute in response to Claude Code events. Use hooks to validate operations, enforce policies, add context, and integrate external tools into workflows.
Key capabilities:
Use LLM-driven decision making for context-aware validation:
{
"type": "prompt",
"prompt": "Evaluate if this tool use is appropriate: $TOOL_INPUT",
"timeout": 30
}Supported events: Stop, SubagentStop, UserPromptSubmit, PreToolUse
Benefits:
Execute bash commands for deterministic checks:
{
"type": "command",
"command": "bash ${CLAUDE_PLUGIN_ROOT}/scripts/validate.sh",
"timeout": 60
}Use for:
For plugin hooks in hooks/hooks.json, use wrapper format:
{
"description": "Brief explanation of hooks (optional)",
"hooks": {
"PreToolUse": [...],
"Stop": [...],
"SessionStart": [...]
}
}Key points:
description field is optionalhooks field is required wrapper containing actual hook eventsExample:
{
"description": "Validation hooks for code quality",
"hooks": {
"PreToolUse": [
{
"matcher": "Write",
"hooks": [
{
"type": "command",
"command": "${CLAUDE_PLUGIN_ROOT}/hooks/validate.sh"
}
]
}
]
}
}For user settings in .claude/settings.json, use direct format:
{
"PreToolUse": [...],
"Stop": [...],
"SessionStart": [...]
}Key points:
Important: The examples below show the hook event structure that goes inside either format. For plugin hooks.json, wrap these in {"hooks": {...}}.
Execute before any tool runs. Use to approve, deny, or modify tool calls.
Example (prompt-based):
{
"PreToolUse": [
{
"matcher": "Write|Edit",
"hooks": [
{
"type": "prompt",
"prompt": "Validate file write safety. Check: system paths, credentials, path traversal, sensitive content. Return 'approve' or 'deny'."
}
]
}
]
}Output for PreToolUse:
{
"hookSpecificOutput": {
"permissionDecision": "allow|deny|ask",
"updatedInput": {"field": "modified_value"}
},
"systemMessage": "Explanation for Claude"
}Execute after tool completes. Use to react to results, provide feedback, or log.
Example:
{
"PostToolUse": [
{
"matcher": "Edit",
"hooks": [
{
"type": "prompt",
"prompt": "Analyze edit result for potential issues: syntax errors, security vulnerabilities, breaking changes. Provide feedback."
}
]
}
]
}Output behavior:
Execute when main agent considers stopping. Use to validate completeness.
Example:
{
"Stop": [
{
"matcher": "*",
"hooks": [
{
"type": "prompt",
"prompt": "Verify task completion: tests run, build succeeded, questions answered. Return 'approve' to stop or 'block' with reason to continue."
}
]
}
]
}Decision output:
{
"decision": "approve|block",
"reason": "Explanation",
"systemMessage": "Additional context"
}Execute when subagent considers stopping. Use to ensure subagent completed its task.
Similar to Stop hook, but for subagents.
Execute when user submits a prompt. Use to add context, validate, or block prompts.
Example:
{
"UserPromptSubmit": [
{
"matcher": "*",
"hooks": [
{
"type": "prompt",
"prompt": "Check if prompt requires security guidance. If discussing auth, permissions, or API security, return relevant warnings."
}
]
}
]
}Execute when Claude Code session begins. Use to load context and set environment.
Example:
{
"SessionStart": [
{
"matcher": "*",
"hooks": [
{
"type": "command",
"command": "bash ${CLAUDE_PLUGIN_ROOT}/scripts/load-context.sh"
}
]
}
]
}Special capability: Persist environment variables using $CLAUDE_ENV_FILE:
echo "export PROJECT_TYPE=nodejs" >> "$CLAUDE_ENV_FILE"See examples/load-context.sh for complete example.
Execute when session ends. Use for cleanup, logging, and state preservation.
Execute before context compaction. Use to add critical information to preserve.
Execute when Claude sends notifications. Use to react to user notifications.
{
"continue": true,
"suppressOutput": false,
"systemMessage": "Message for Claude"
}continue: If false, halt processing (default true)suppressOutput: Hide output from transcript (default false)systemMessage: Message shown to Claude0 - Success (stdout shown in transcript)2 - Blocking error (stderr fed back to Claude)All hooks receive JSON via stdin with common fields:
{
"session_id": "abc123",
"transcript_path": "/path/to/transcript.txt",
"cwd": "/current/working/dir",
"permission_mode": "ask|allow",
"hook_event_name": "PreToolUse"
}Event-specific fields:
tool_name, tool_input, tool_resultuser_promptreasonAccess fields in prompts using $TOOL_INPUT, $TOOL_RESULT, $USER_PROMPT, etc.
Available in all command hooks:
$CLAUDE_PROJECT_DIR - Project root path$CLAUDE_PLUGIN_ROOT - Plugin directory (use for portable paths)$CLAUDE_ENV_FILE - SessionStart only: persist env vars here$CLAUDE_CODE_REMOTE - Set if running in remote contextAlways use ${CLAUDE_PLUGIN_ROOT} in hook commands for portability:
{
"type": "command",
"command": "bash ${CLAUDE_PLUGIN_ROOT}/scripts/validate.sh"
}In plugins, define hooks in hooks/hooks.json:
{
"PreToolUse": [
{
"matcher": "Write|Edit",
"hooks": [
{
"type": "prompt",
"prompt": "Validate file write safety"
}
]
}
],
"Stop": [
{
"matcher": "*",
"hooks": [
{
"type": "prompt",
"prompt": "Verify task completion"
}
]
}
],
"SessionStart": [
{
"matcher": "*",
"hooks": [
{
"type": "command",
"command": "bash ${CLAUDE_PLUGIN_ROOT}/scripts/load-context.sh",
"timeout": 10
}
]
}
]
}Plugin hooks merge with user's hooks and run in parallel.
Exact match:
"matcher": "Write"Multiple tools:
"matcher": "Read|Write|Edit"Wildcard (all tools):
"matcher": "*"Regex patterns:
"matcher": "mcp__.*__delete.*" // All MCP delete toolsNote: Matchers are case-sensitive.
// All MCP tools
"matcher": "mcp__.*"
// Specific plugin's MCP tools
"matcher": "mcp__plugin_asana_.*"
// All file operations
"matcher": "Read|Write|Edit"
// Bash commands only
"matcher": "Bash"Always validate inputs in command hooks:
#!/bin/bash
set -euo pipefail
input=$(cat)
tool_name=$(echo "$input" | jq -r '.tool_name')
# Validate tool name format
if [[ ! "$tool_name" =~ ^[a-zA-Z0-9_]+$ ]]; then
echo '{"decision": "deny", "reason": "Invalid tool name"}' >&2
exit 2
fiCheck for path traversal and sensitive files:
file_path=$(echo "$input" | jq -r '.tool_input.file_path')
# Deny path traversal
if [[ "$file_path" == *".."* ]]; then
echo '{"decision": "deny", "reason": "Path traversal detected"}' >&2
exit 2
fi
# Deny sensitive files
if [[ "$file_path" == *".env"* ]]; then
echo '{"decision": "deny", "reason": "Sensitive file"}' >&2
exit 2
fiSee examples/validate-write.sh and examples/validate-bash.sh for complete examples.
# GOOD: Quoted
echo "$file_path"
cd "$CLAUDE_PROJECT_DIR"
# BAD: Unquoted (injection risk)
echo $file_path
cd $CLAUDE_PROJECT_DIR{
"type": "command",
"command": "bash script.sh",
"timeout": 10
}Defaults: Command hooks (60s), Prompt hooks (30s)
All matching hooks run in parallel:
{
"PreToolUse": [
{
"matcher": "Write",
"hooks": [
{"type": "command", "command": "check1.sh"}, // Parallel
{"type": "command", "command": "check2.sh"}, // Parallel
{"type": "prompt", "prompt": "Validate..."} // Parallel
]
}
]
}Design implications:
Create hooks that activate conditionally by checking for a flag file or configuration:
Pattern: Flag file activation
#!/bin/bash
# Only active when flag file exists
FLAG_FILE="$CLAUDE_PROJECT_DIR/.enable-strict-validation"
if [ ! -f "$FLAG_FILE" ]; then
# Flag not present, skip validation
exit 0
fi
# Flag present, run validation
input=$(cat)
# ... validation logic ...Pattern: Configuration-based activation
#!/bin/bash
# Check configuration for activation
CONFIG_FILE="$CLAUDE_PROJECT_DIR/.claude/plugin-config.json"
if [ -f "$CONFIG_FILE" ]; then
enabled=$(jq -r '.strictMode // false' "$CONFIG_FILE")
if [ "$enabled" != "true" ]; then
exit 0 # Not enabled, skip
fi
fi
# Enabled, run hook logic
input=$(cat)
# ... hook logic ...Use cases:
Best practice: Document activation mechanism in plugin README so users know how to enable/disable temporary hooks.
Important: Hooks are loaded when Claude Code session starts. Changes to hook configuration require restarting Claude Code.
Cannot hot-swap hooks:
hooks/hooks.json won't affect current sessionclaude againTo test hook changes:
claude or ccclaude --debugHooks are validated when Claude Code starts:
Use /hooks command to review loaded hooks in current session.
claude --debugLook for hook registration, execution logs, input/output JSON, and timing information.
Test command hooks directly:
echo '{"tool_name": "Write", "tool_input": {"file_path": "/test"}}' | \
bash ${CLAUDE_PLUGIN_ROOT}/scripts/validate.sh
echo "Exit code: $?"Ensure hooks output valid JSON:
output=$(./your-hook.sh < test-input.json)
echo "$output" | jq .| Event | When | Use For |
|---|---|---|
| PreToolUse | Before tool | Validation, modification |
| PostToolUse | After tool | Feedback, logging |
| UserPromptSubmit | User input | Context, validation |
| Stop | Agent stopping | Completeness check |
| SubagentStop | Subagent done | Task validation |
| SessionStart | Session begins | Context loading |
| SessionEnd | Session ends | Cleanup, logging |
| PreCompact | Before compact | Preserve context |
| Notification | User notified | Logging, reactions |
DO:
DON'T:
For detailed patterns and advanced techniques, consult:
references/patterns.md - Common hook patterns (8+ proven patterns)references/migration.md - Migrating from basic to advanced hooksreferences/advanced.md - Advanced use cases and techniquesWorking examples in examples/:
validate-write.sh - File write validation examplevalidate-bash.sh - Bash command validation exampleload-context.sh - SessionStart context loading exampleDevelopment tools in scripts/:
validate-hook-schema.sh - Validate hooks.json structure and syntaxtest-hook.sh - Test hooks with sample input before deploymenthook-linter.sh - Check hook scripts for common issues and best practicesclaude --debug for detailed logsjq to validate hook JSON outputTo implement hooks in a plugin:
hooks/hooks.jsonscripts/validate-hook-schema.sh hooks/hooks.jsonscripts/test-hook.sh before deploymentclaude --debugFocus on prompt-based hooks for most use cases. Reserve command hooks for performance-critical or deterministic checks.
© anthropics, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 10 other files (scripts, references) in plugins/plugin-dev/skills/hook-development of anthropics/claude-plugins-official.
Open the folder on GitHubat commit b78ac49
We found 31 copies of this SKILL.md (exact, near-identical or edited) in other folders, from 11 other GitHub owners. This page covers the copy in anthropics/claude-plugins-official, which our catalogue first saw on October 7, 2026.
Hook Development for Claude Code Plugins next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Hook Development for Claude Code Plugins this skillanthropics/claude-plugins-official | 38k | 11 repos | ~4.1k | Automated safety check: Notes | Apache-2.0 | |
| Crush Configurationcharmbracelet/crush | 29k | — | ~3.7k | Automated safety check: Pass | Custom licence | |
| Verify Setup Health Checkdiet103/claude-code-infrastructure-showcase | 10k | — | ~363 | Automated safety check: Pass | MIT | |
| Claude SmartReflexioAI/claude-smart | 783 | — | ~439 | Automated safety check: Pass | Apache-2.0 | |
| Hook CreatorgreatSumini/cc-system | 438 | — | ~662 | Automated safety check: Notes | MIT | |
| Creating An Agented3dai/ed3d-plugins | 250 | — | ~2k | Automated safety check: Pass | None |
charmbracelet/crush
Explains how to configure the Crush coding agent with crushrc or crush.json, covering providers, models, LSPs, MCP servers, hooks, permissions and config precedence.
diet103/claude-code-infrastructure-showcase
Run the infrastructure health check and fix anything that fails
ReflexioAI/claude-smart
Codex-only — use when the user asks to run claude-smart commands in Codex, including claude-smart show, learn, restart, dashboard, clear-all, or slash-like requests such as /claude-smart:learn.
greatSumini/cc-system
Create and configure Claude Code hooks for customizing agent behavior.
ed3dai/ed3d-plugins
A skill your agent uses when creating specialized subagents for Claude Code plugins or the Task tool - covers description writing for auto-delegation, tool selection, prompt structure, and testing…
alirezarezvani/claude-code-skill-factory
Generate custom Claude Code slash commands through intelligent 5-7 question flow.
anthropics/claude-plugins-official
Explains how to write agents for Claude Code plugins: the markdown file with YAML frontmatter, trigger descriptions, model and color settings, and system prompt design.
anthropics/claude-plugins-official
Shows how Claude Code plugins keep per-project settings and state in .claude/plugin-name.local.md files with YAML frontmatter and a markdown body.
anthropics/claude-plugins-official
Explains how to bundle Model Context Protocol servers in a Claude Code plugin, covering config files, stdio, SSE, HTTP and WebSocket server types, and authentication.
anthropics/claude-plugins-official
Explains how to write Claude Code slash commands: Markdown files with YAML frontmatter, arguments, file references, bash context and interactive prompts.
anthropics/claude-plugins-official
Explains the directory layout, plugin.json manifest and component organization of a Claude Code plugin, including auto-discovery and portable paths.
anthropics/claude-plugins-official
Finds every CLAUDE.md file in a repository, scores each against quality criteria, shows a report, then makes targeted updates after you approve.
Works with
Categories
Explains how to write Claude Code plugin hooks, both prompt-based checks and bash commands, for events such as PreToolUse, Stop and SessionStart. Hooks are scripts or prompts that Claude Code runs when an event fires. This skill describes the event types (PreToolUse, PostToolUse, Stop, SubagentStop, SessionStart, SessionEnd, UserPromptSubmit, PreCompact, Notification) and what each is good for: approving or denying tool calls, reacting to results, enforcing completion standards or loading project context when a session starts.
Hook Development for Claude Code Plugins fits situations like: blocking dangerous shell commands before they run; adding a check that runs when the agent says it is done; loading project context automatically at session start; converting a hook between plugin and settings formats.
Run `npx skills add anthropics/claude-plugins-official --skill hook-development -a claude-code`. Or copy the skill folder (plugins/plugin-dev/skills/hook-development in anthropics/claude-plugins-official) into .claude/skills/hook-development in your project. Claude Code loads it when a task matches its description.
Run `npx skills add anthropics/claude-plugins-official --skill hook-development -a codex`. Or copy the skill folder (plugins/plugin-dev/skills/hook-development in anthropics/claude-plugins-official) into .agents/skills/hook-development in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add anthropics/claude-plugins-official --skill hook-development -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/hook-development, .gemini/skills/hook-development, .github/skills/hook-development and .opencode/skills/hook-development in your project.
Going by SKILL.md and its folder, Hook Development for Claude Code Plugins needs a shell for the scripts in its folder and the command-line tools its instructions call (jq, claude and bash). Our summary lists: Claude Code with plugin support; Bash for command hooks.
SKILL.md names 1 domain. As links in the text: docs.claude.com. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found notes only (mentions a .env file), nothing it rates as a warning. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.
Hook Development for Claude Code Plugins is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 4.1k tokens (SKILL.md is roughly 16k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 6.4k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Hook Development for Claude Code Plugins: Crush Configuration (charmbracelet/crush, 29k stars), Verify Setup Health Check (diet103/claude-code-infrastructure-showcase, 10k stars), Claude Smart (ReflexioAI/claude-smart, 783 stars) and Hook Creator (greatSumini/cc-system, 438 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
anthropics (a GitHub organization, an official publisher) maintains it in anthropics/claude-plugins-official, which has 37,509 GitHub stars. The repository holds 29 skills in this directory. The repository was last updated on October 8, 2026.
Source: anthropics/claude-plugins-official on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.