Skip to content

tgrnd/igit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

90 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

igit

Git workflow enforcement and convention guidance for Claude Code.

What It Does

Hooks enforce git command safety — deny dangerous operations, ask for confirmation on writes, allow safe reads.

Skills guide git conventions — commit messages, branching, PRs, file lineage.

Installation

Install at user scope for global git workflow enforcement:

claude plugin add /path/to/igit

Components

Hook: git-policy-hook (PreToolUse)

Evaluates git commands against policy rules before execution:

Decision Meaning Example
deny Blocked by policy git push --force, git reset --hard
ask Requires user confirmation git push, git merge, git rebase
allow Runs without prompts git status, git log, git commit

Convention Skills

Skill Trigger Purpose
/igit:git-workflow Branching, PRs, pushing Lifecycle conventions
/igit:file-lineage Moving/renaming files Preserving git history

Interactive Skills

Skill Trigger Purpose
/igit:commit /igit:commit (user-invoked) Branch selection, file staging, commit message workflow

Development

# Run tests
uv run pytest hooks/ -v

# Run hook directly (reads JSON from stdin)
# --script reads PEP 723 inline metadata for Python version and dependencies
uv run --script hooks/git_policy_hook.py

About

Git workflow enforcement and convention guidance for Claude Code

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors