
Product
Introducing Pull Request Stories to Help Security Teams Track Supply Chain Risks
Socket’s new Pull Request Stories give security teams clear visibility into dependency risks and outcomes across scanned pull requests.
@c-p-b/cc-hooks
Advanced tools
A universal, stable, and user-friendly hook management system for Claude Code
A universal, stable, and user-friendly hook management system for Claude Code.
npm install -g @c-p-b/cc-hooks
# Initialize cc-hooks in your project
cc-hooks init
# Install hooks - three options:
# Option 1: Install a complete bundle (multiple related hooks)
cc-hooks install typescript # Installs all TypeScript hooks (eslint, prettier, tests, etc.)
cc-hooks install python # Installs all Python hooks
# Option 2: Install individual hooks from templates
cc-hooks install templates/typescript/eslint-post.json # Just ESLint
cc-hooks install templates/git/conventional-commits.json # Git commit validation
# Option 3: Install from local files or directories
cc-hooks install ./my-hook.json # Single hook file
cc-hooks install ./hooks-dir # All .json files in directory (treated as bundle)
# Show all configured hooks
cc-hooks show
# Test your hooks locally
cc-hooks init-test # Generate test event files
cc-hooks test # Test all hooks
cc-hooks test Stop.json # Test specific event
cat Stop.json | cc-hooks run # Manual testing (what Claude does)
# View hook execution logs
cc-hooks logs # View recent logs (including test runs)
cc-hooks logs --details # Show detailed output snippets
cc-hooks logs --stats # Show execution statistics
typescript
- ESLint, Prettier, type checking, unit tests, coveragepython
- Ruff lintinggit
- Conventional commit message validationsession
- Context loading, initialization, transcript savinganalysis
- Code quality, compatibility, and pattern scanningautomation
- Script runners and prompt processorsBrowse all available hooks in the templates/
directory, organized by category.
# Install dependencies
npm install
# Build TypeScript
npm run build
# Run tests
npm test
# Watch mode for development
npm run dev
# Run with debug output
node dist/cli.js --debug
When you install from a directory, cc-hooks treats it as a bundle - a collection of related hooks:
.json
files in the directory are installed as individual hookstypescript:lint
)--force
, all hooks in the bundle replace existing ones with the same namesExamples:
# Install all hooks from a local directory
cc-hooks install ./my-hooks # Installs all .json files as a bundle
# Built-in bundles work the same way
cc-hooks install typescript # Installs multiple TypeScript-related hooks
FAQs
A universal, stable, and user-friendly hook management system for Claude Code
We found that @c-p-b/cc-hooks demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket’s new Pull Request Stories give security teams clear visibility into dependency risks and outcomes across scanned pull requests.
Research
/Security News
npm author Qix’s account was compromised, with malicious versions of popular packages like chalk-template, color-convert, and strip-ansi published.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.