Git Hooks Integration

Implements Git hooks to automate pre-commit checks, commit validation, and pre-push tests.

4|1|Updated Dec 30, 2025
One-click install
npx skills add https://github.com/doanchienthangdev/omgkit --skill git-hooks-integration
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Git Hooks Integration
Source: https://github.com/doanchienthangdev/omgkit/tree/main/plugin/skills/devops/git-hooks
Command: npx skills add https://github.com/doanchienthangdev/omgkit --skill git-hooks-integration

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill automates the enforcement of code quality, commit standards, and testing directly within your Git workflow, preventing issues before they are committed or pushed.

Core Features & Use Cases

  • Automated Checks: Integrates pre-commit, commit-msg, and pre-push hooks to run linters, formatters, type checkers, and tests automatically.
  • Configurable Rules: Define specific actions and validation rules in .omgkit/workflow.yaml for consistent team practices.
  • Use Case: Ensure all code is linted and formatted before committing, validate that commit messages follow the Conventional Commits standard, and run all tests before allowing a push to the repository.

Quick Start

Run /hooks:setup to install Git hooks based on your workflow configuration.

Frequently Asked Questions about Git Hooks Integration

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate code quality checks with Git hooks before committing?

Git hooks automate code quality checks by integrating pre-commit, commit-msg, and pre-push hooks to run linters, formatters, type checkers, and tests automatically before code is committed or pushed.

How do I enforce Conventional Commits validation in a Git workflow?

Conventional Commits validation is enforced using a commit-msg Git hook configured via a workflow.yaml file, ensuring commit messages follow team standards before they are accepted into the repository.

Can I run tests automatically before pushing code to a remote repository?

Yes, a pre-push Git hook can run all tests automatically before allowing a push to the repository, preventing untested or broken code from reaching the remote branch.

How do I configure custom Git hook actions for a development team?

Custom Git hook actions are configured by defining specific validation rules and actions in a `.omgkit/workflow.yaml` file, ensuring consistent team practices across pre-commit, commit-msg, and pre-push stages.

What is the best way to prevent poorly formatted code from being committed in Git?

The best way to prevent poorly formatted code from being committed is using a pre-commit Git hook to automatically run linters and formatters, blocking the commit if quality standards are not met.

Do I need a configuration file to set up automated Git hooks?

Yes, setting up automated Git hooks requires a `.omgkit/workflow.yaml` configuration file to define hook setup and actions, which is then installed via a dedicated setup command.