Repository navigation
v0.3.0
🎯 Highlights
This release marks a significant architectural shift to the Modern Husky approach, using Git's native
core.hooksPathconfiguration for better performance, flexibility, and support for auxiliary scripts.
⚠️ Breaking Changes
- Hook Location: Hooks are now stored directly in
.husky/instead of.husky/hooks/. - Mechanism Shift: Switched from copying/wrapping hooks to using
git config core.hooksPath .husky. - Directory Structure: The
.husky/hooks/subdirectory is no longer used; move your hooks to.husky/. - CLI Feature: The
clifeature has been removed. Thehuskybinary is now included by default without extra configuration.
✨ New Features
- Helper Script Support: Arbitrary files (like
_helpers.sh) can now be stored in.husky/and sourced from hooks. - Runtime Control: Support for
HUSKY=0environment variable to skip hooks at runtime (e.g.,HUSKY=0 git commit). - Runtime Helper: Added
.husky/_/husky.shwhich can be sourced by hooks for standardized behavior. - CLI Enhancements:
husky init: Now configurescore.hooksPathimmediately and creates the_/husky.shhelper.husky uninstall: New command to unsetcore.hooksPath.husky add: Templates updated to include_/husky.shsourcing example.
🚀 Performance & Robustness
- Incremental Builds:
build.rsnow checkscore.hooksPathbefore callinggit config, speeding up builds. - Graceful Degradation: Better handling of environments without
gitcommand or outside git repositories.