Hooks
Scripts that automatically run at specific git events, such as before a commit or after a push.
Git hooks are a foundational automation primitive: lightweight scripts that trigger before or after operations like commit, push, merge, or rebase. A pre-commit hook can enforce linting or run tests before code is accepted; a post-receive hook on the server can kick off a CI/CD pipeline. Hooks live in .git/hooks and can be written in any language. While the concept exists in all VCS systems, Git's hook system is particularly mature. Frameworks like Husky have made pre-commit hooks nearly universal in JavaScript projects, turning them into the de facto standard for preventing broken code from entering the repository.