Universal Claude Code hooks collection with cross-platform installer
🤖 Interested in AI Multi-Agent workflows? Join the Swarm Community to discuss agentic development, share tools, and collaborate on building better AI workflows!
Works universally across all devices and operating systems:
- ✅ Windows (10, 11) - Native PowerShell integration
- ✅ macOS (Intel & Apple Silicon) - Native osascript notifications
- ✅ Linux (Ubuntu, CentOS, Arch) - Native notify-send support
- ✅ Node.js 16+ - Tested on LTS versions
Install globally with npm:
Install hooks interactively:
Or install specific hooks:
Automatically commits file changes with contextual messages after every Claude Code file modification.
Features:
- Smart commit messages with tool context
- File path and change type detection
- Configurable exclusion patterns
- Branch-aware behavior
Automatically formats code after file modifications using popular formatters.
Features:
- Support for multiple languages (JS/TS, Python, Go, Rust, Java, C/C++)
- Project configuration detection
- Configurable formatters per file type
- Graceful error handling
Enhanced notifications for Claude Code events with multiple delivery methods.
Features:
- Cross-platform desktop notifications
- Slack/Discord/Teams integration
- Custom notification commands
- Configurable notification types
Install for all Claude Code projects:
Install for current project only:
Install locally (not committed to git):
The auto-commit hook can be customized through its configuration:
Configure formatters for different file types:
Set up notifications and integrations:
- Node.js: >= 16.0.0
- Claude Code: Latest version
- Git: For auto-commit functionality
- Formatters: Optional, based on enabled hooks
Run the built-in diagnostics to check your setup:
This will check:
- ✅ Node.js version compatibility
- ✅ Claude Code installation
- ✅ Git availability and repository status
- ✅ Settings directory permissions
- ✅ Configuration file validity
- Hooks execute with your user permissions
- Review hook configurations before installation
- Use project-level installation for team settings
- Keep sensitive configurations in local settings
- Regularly update to latest versions
Hook not executing:
Permission errors:
- Ensure Claude Code settings directory is writable
- Check file permissions on hook scripts
- Verify git repository permissions for auto-commit
Formatter not found:
- Install required formatters globally
- Check PATH configuration
- Use rins_hooks doctor to verify dependencies
We welcome contributions! Here's how to get started:
- Fork the repository
- Create a feature branch
- Add your hook or improvement
- Test thoroughly across platforms
- Submit a pull request
Extend the HookBase class:
MIT License - see LICENSE file for details.
- Anthropic for Claude Code
- Open source community for formatter tools
- Contributors and testers
Made with ❤️ for the Claude Code community