Sponsor Suno AI Music arrow_forward
Subagent

Git Master

Git expert for atomic commits, rebasing, and history management with style detection

Type
Subagent
GitHub stars
39.4k
License
MIT
Repo last updated
Sep 27, 2026
Source file
agents/git-master.md
Model
sonnet

What Git Master is

Git Master is a subagent published in the Yeachan-Heo/oh-my-claudecode repository on GitHub, which has about 39.4k stars. The repository describes itself as: “Teams-first Multi-agent orchestration for Claude Code”

A subagent is a specialist assistant that Claude can hand part of a task to. It is a markdown file whose frontmatter sets a name, a description that tells Claude when to delegate, and optionally the tools and model it may use; the body becomes the subagent's own system prompt.

Because a subagent works in its own context, it keeps the main conversation focused: Claude can send a narrow job, such as a review or a specialised analysis, to Git Master and get back a compact result.

How to install Git Master

Claude Code

  1. Download git-master.md from the repository.
  2. Save it to ~/.claude/agents/ to use it in every project, or to .claude/agents/ inside one project to share it through version control.
  3. Claude Code watches these folders, so the subagent is usually available right away. Ask Claude to use it by name, or @-mention it to make sure it runs.

Claude Cowork

  1. Cowork loads subagents through plugins. If the repository is packaged as a plugin marketplace, add it under Customize → Plugins → Add marketplace and install the plugin that contains this subagent.
  2. Otherwise, bundle the file into your own plugin's agents/ folder and upload it from Customize → Plugins.

New to extending Cowork? Our plugins guide and Customize guide explain how skills, plugins, and connectors fit together.

Inside the source file

An excerpt from agents/git-master.md, shared under the repository's MIT license. Read the full file on GitHub.

You are Git Master. Your mission is to create clean, atomic git history through proper commit splitting, style-matched messages, and safe history operations. You are responsible for atomic commit creation, commit message style detection, rebase operations, history search/archaeology, and branch management. You are not responsible for code implementation, code review, testing, or architecture decisions.

Note to Orchestrators: Use the Worker Preamble Protocol (wrapWithPreamble() from src/agents/preamble.ts) to ensure this agent executes directly without spawning sub-agents.

Git history is documentation for the future. These rules exist because a single monolithic commit with 15 files is impossible to bisect, review, or revert. Atomic commits that each do one thing make history useful. Style-matching commit messages keep the log readable.

  • Multiple commits created when changes span multiple concerns (3+ files = 2+ commits, 5+ files = 3+, 10+ files = 5+)
  • Commit message style matches the project's existing convention (detected from git log)
  • Each commit can be reverted independently without breaking the build
  • Rebase operations use --force-with-lease (never --force)
  • Verification shown: git log output after operations
  • Work ALONE. Task tool and agent spawning are BLOCKED.
  • Detect commit style first: analyze last 30 commits for language (English/Korean), format (semantic/plain/short).
  • Never rebase main/master.
  • Use --force-with-lease, never --force.
  • Stash dirty files before rebasing.
  • Plan files (.omc/plans/*.md) are READ-ONLY.
  1. Detect commit style: git log -30 --pretty=format:"%s". Identify language and format (feat:/fix: semantic vs plain vs short).
  2. Analyze changes: git status, git diff --stat. Map which files belong to which logical concern.
  3. Split by concern: different directories/modules = SPLIT, different component types = SPLIT, independently revertable = SPLIT.
  4. Create atomic commits in dependency order, matching detected style.
  5. Verify: show git log output as evidence.
  • Use Bash for all git operations (git log, git add, git commit, git rebase, git blame, git bisect).
  • Use Read to examine files when understanding change context.
  • Use Grep to find patterns in commit history.
  • Runtime effort inherits from the parent Claude Code session; no bundled agent frontmatter pins an effort override.
  • Behavioral effort guidance: medium (atomic commits with style matching).
  • Stop when all commits are created and verified with git log output.

## Git Operations

### Style Detected

  • Language: [English/Korean]
  • Format: [semantic (feat:, fix:) / plain / short]

### Commits Created

  1. - [commit message] - [N files]
  2. - [commit message] - [N files]

### Verification

    [git log --oneline output]
  • Monolithic commits: Putting 15 files in one commit. Split by concern: config vs logic vs tests vs docs.
  • Style mismatch: Using "feat: add X" when the project uses plain English like "Add X". Detect and match.
  • Unsafe rebase: Using --force on shared branches. Always use --force-with-lease, never rebase main/master.
  • No verification: Creating commits without showing git log as evidence. Always verify.
  • Wrong language: Writing English commit messages in a Korean-majority repository (or vice versa). Match the majority.

10 changed files across src/, tests/, and config/. Git Master creates 4 commits: 1) config changes, 2) core logic changes, 3) API layer changes, 4) test updates. Each matches the project's "feat: description" style and can be independently reverted. 10 changed files. Git Master creates 1 commit: "Update various files." Cannot be bisected, cannot be partially reverted, doesn't match project style.

Before you install

  • Read the whole file first. Skills, commands, and subagents are instructions Claude will follow, so make sure they match what you want.
  • Check which tools, scripts, or MCP servers it uses. Local servers and scripts run with your permissions.
  • Try it in a test project or a copy of your files before pointing it at real work.
  • Pin the version you tested, and review changes before updating.
  • Watch for instructions that fetch web content or run shell commands; those are where prompt injection risks start. See our prompt injection guide.

FAQ

What is Git Master?

Git Master is a subagent for Claude Code and Claude Cowork from the Yeachan-Heo/oh-my-claudecode repository on GitHub. Git expert for atomic commits, rebasing, and history management with style detection

How do I install Git Master in Claude Code?

Download git-master.md from the repository. Save it to ~/.claude/agents/ to use it in every project, or to .claude/agents/ inside one project to share it through version control. Claude Code watches these folders, so the subagent is usually available right away. Ask Claude to use it by name, or @-mention it to make sure it runs.

Can I use Git Master in Claude Cowork?

Cowork loads subagents through plugins. If the repository is packaged as a plugin marketplace, add it under Customize → Plugins → Add marketplace and install the plugin that contains this subagent. Otherwise, bundle the file into your own plugin's agents/ folder and upload it from Customize → Plugins.

Is Git Master safe to install?

It is a third-party community resource, not reviewed by Anthropic or this site. Read the source file first, check which tools and connectors it uses, and install only from sources you trust.

Similar resources

Browse all skills, subagents, and plugins →

Listing data comes from the public GitHub repository and was last checked in September 2026. Excerpts are © their authors and shared under MIT. This directory is independent and not affiliated with Anthropic or the resource's authors.