Create and configure hookify rules — markdown files with YAML frontmatter that match bash, file, prompt, or stop events by regex or conditions and show warn/…
Pins this version in aipm.package.json and aipm-lock.json.
aipm add @affaan-m/hookify-rules@1.0.0
Without project tracking
Writes the skill files only. Add --no-init to skip aipm.package.json and the lockfile.
aipm add @affaan-m/hookify-rules@1.0.0 --no-init
How to use
Install the skill above, then run this in your AI tool:
/hookify-rules <your description>
About
## Overview
Source
What gets added to your project
Preview every file this package writes on install before you run the command above.
Summary
Create and configure hookify rules — markdown files with YAML frontmatter that match bash, file, prompt, or stop events by regex or conditions and show warn/block messages to the agent. Use when creating a hookify rule, writing hook rule...
Skill instructions
Writing Hookify Rules
Overview
ECC evaluates project-local Hookify rules with its built-in Node runtime. No
separate Hookify plugin or Python installation is required when ECC hooks are
enabled.
Hookify rules are markdown files with YAML frontmatter that define patterns to watch for and messages to show when those patterns match. Rules are stored in .claude/hookify.{rule-name}.local.md files.
Rule File Format
Basic Structure
markdown
---
name: rule-identifier
enabled: true
event: bash|file|stop|prompt|all
pattern: regex-pattern-here
---
Message to show Claude when this rule triggers.
Can include markdown formatting, warnings, suggestions, etc.
Avoid nested quantifiers such as (a+)+. The runtime rejects patterns with
common catastrophic-backtracking shapes because rules run synchronously in the
hook path, and every regex evaluation has a 25 ms hard timeout. Invalid,
symlinked, or oversized local rules fail open and emit a
diagnostic without disabling other Hookify rules.
Git-tracked local rules are disabled by default. Set
ECC_HOOKIFY_ALLOW_TRACKED=1 only after reviewing those files; ordinary
gitignored rules created locally remain active without that override.
Runtime Behavior
warn injects the message as event-specific additional context and does not block.
block denies matching Bash, PowerShell, Write, Edit, or MultiEdit calls before execution.
On prompt, post-tool, and stop events, block uses Claude Code's structured block decision.
Add this badge to a GitHub README so readers can open the package page and install the same version.
[](https://www.aipm-registry.com/skills/affaan-m/hookify-rules/1.0.0?utm_source=github&utm_medium=readme&utm_campaign=package_badge)
This imported publisher has not claimed its AIPM account. A connected account confirms account control, but it does not guarantee that a package is safe.
AI assistant context
What this skill is for
@affaan-m/hookify-rules@1.0.0 is an AIPM skill package for All tools. Use it when a project needs the reusable AI behavior described as: Create and configure hookify rules — markdown files with YAML frontmatter that match bash, file, prompt, or stop events by regex or conditions and show warn/block messages to the agent. Use when creating a hookify rule, writing hook rule...
Run aipm add @affaan-m/hookify-rules@1.0.0 in a project that has AIPM initialized.
Supported tools
@affaan-m/hookify-rules@1.0.0 supports All tools.
Before installing
AIPM skills can add files to your project. Review the package name, target, description, license, and publisher before installing. Use a clean branch when trying a new skill.