claude-hooks

Community

Automate actions & customize Claude Code with powerful hooks.

Authornera0875
Version1.0.0
Installs0

System Documentation

What problem does it solve?

Users need deterministic control over Claude Code's behavior, ensuring specific actions (like formatting or logging) always occur at certain points in the workflow, rather than relying on the LLM to choose. This skill guides on using hooks.

Core Features & Use Cases

  • Hook Events: Explains various events like PreToolUse, PostToolUse, UserPromptSubmit, Notification, and SessionStart/End.
  • Customization: Allows registering shell commands to execute at these events for tasks like automatic formatting, logging, or custom notifications.
  • File Protection: Provides examples for blocking operations on sensitive files using PreToolUse hooks.
  • Use Case: Implement a PostToolUse hook that automatically runs prettier --write on any .ts file after Claude Code edits or writes it, ensuring consistent code formatting across the project without manual intervention.

Quick Start

Use the claude-hooks skill to set up a PreToolUse hook that logs every Bash command executed by Claude Code to a file.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: claude-hooks
Download link: https://github.com/nera0875/AGI/archive/main.zip#claude-hooks

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.