1. Conduid
  2. Developer Tools
  3. Git MCP Server
MCP server · Developer Tools

Git MCP Server

MCP server for local git operations (commit, branch, push, pull, sync)

Unclaimed MIT last commit 8 months ago devtools
56Fair

Scored 13 days ago · breakdown

About Git MCP Server

Git MCP Server is an MCP server published by rriesco in the Developer Tools category: mCP server for local git operations (commit, branch, push, pull, sync).

Six months or more without a commit doesn't mean the server is broken, but check the open issues before depending on it in production.

Install

From source
git clone https://github.com/rriesco/git-mcp-server

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Tools (6)

git_commitCreate conventional commit with Claude attribution

Parameters not published.

git_create_branchCreate and checkout a new branch with naming conventions

Parameters not published.

git_pullPull commits from remote

Parameters not published.

git_pushPush commits to remote with upstream tracking

Parameters not published.

git_statusGet current branch, tracking info, and file changes

Parameters not published.

git_sync_with_mainSync current branch with main (merge or rebase)

Parameters not published.

Ask AI

✦

Ask AI about Git MCP Server

Powered by Claude · Grounded in docs

I know everything about Git MCP Server. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

  • ✓README presentThe repository ships documentation.
  • ✓License declaredUsable under a stated license.
  • !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.

3 checks have not been run yet.

Releases

v0.1.6v0.1.6 · 1 Feb 2026Changes Remove python-dotenv dependency and .env file loading Environment variables now set via MCP config `env` block Simplify GITHUB_TOKEN logging messages Configuration Set `GITHUB_TOKEN` in your MCP config: { "env": { "GITHUB_TOKEN":…
v0.1.5v0.1.5 · 1 Feb 2026Fixed Fix CI/CD workflow: correct mypy path from `src/github_mcp_server` to `src/git_mcp_server` Remove outdated `github-manager/` script references from documentation
v0.1.3v0.1.3 · 31 Jan 2026Release v0.1.3
v0.1.2v0.1.2 · 31 Jan 2026Initial release
v0.1.1v0.1.1 · 31 Jan 2026Initial release

README

Git MCP Server

Python MCP (Model Context Protocol) server for local git operations, providing native tool integration with Claude Code and other MCP clients.

Features

  • 6 Git Tools: Commit, branch, push, pull, status, and sync operations
  • Native MCP Integration: Works seamlessly with Claude Code
  • Conventional Commits: Enforced commit message format with type prefixes
  • Branch Naming: Enforced conventions (issue-N-description, feature-*, etc.)
  • Token Authentication: Automatic GitHub token injection for remote operations

Installation

From PyPI

pip install git-mcp-server
# or with uv
uvx git-mcp-server

From Source

git clone https://github.com/rriesco/git-mcp-server.git
cd git-mcp-server
uv sync

Configuration

Environment Variables

Variable Required Description
GITHUB_TOKEN For push/pull GitHub Personal Access Token for authenticated git operations

Claude Code Configuration

Add to your MCP configuration (~/.config/claude-code/mcp-config.json):

{
  "mcpServers": {
    "git-manager": {
      "type": "stdio",
      "command": "uvx",
      "args": ["git-mcp-server"],
      "env": {
        "GITHUB_TOKEN": "${GITHUB_TOKEN}"
      }
    }
  }
}

Available Tools

Tool Description
git_create_branch Create and checkout a new branch with naming conventions
git_commit Create conventional commit with Claude attribution
git_push Push commits to remote with upstream tracking
git_pull Pull commits from remote
git_status Get current branch, tracking info, and file changes
git_sync_with_main Sync current branch with main (merge or rebase)

Usage Examples

Create a Branch

result = git_create_branch(
    issue_number=42,
    description="add-feature-x"
)
# Creates: issue-42-add-feature-x

Commit Changes

result = git_commit(
    type="feat",
    message="implement user authentication"
)
# Creates: feat: implement user authentication
#
# Co-Authored-By: Claude <noreply@anthropic.com>

Check Status

result = git_status()
# Returns: {branch, tracking, ahead, behind, staged, modified, untracked, clean}

Sync with Main

result = git_sync_with_main(
    main_branch="main",
    strategy="merge"  # or "rebase"
)

Commit Types

The git_commit tool enforces conventional commit types:

Type Description
feat New feature
fix Bug fix
docs Documentation only
style Code style (formatting, semicolons, etc.)
refactor Code refactoring
perf Performance improvement
test Adding or fixing tests
build Build system or dependencies
ci CI/CD configuration
chore Maintenance tasks
revert Revert previous commit

Branch Naming

The git_create_branch tool enforces naming conventions:

  • issue-<N>-<description> - For GitHub issues
  • feature-<description> - For features without issues
  • fix-<description> - For bug fixes
  • refactor-<description> - For refactoring

Development

Prerequisites

  • Python >= 3.10
  • uv (recommended) or pip
  • Git

Setup

git clone https://github.com/rriesco/git-mcp-server.git
cd git-mcp-server
uv sync

Running Tests

# Unit tests only (fast)
uv run pytest -m "not integration" -v

# Integration tests (creates real git repos in temp directories)
uv run pytest -m integration -v

# All tests with coverage
uv run pytest --cov=git_mcp_server --cov-report=term-missing

Type Checking

uv run mypy src/git_mcp_server --strict

Architecture

Claude Code / MCP Client
      |
      | MCP Protocol (stdio)
      v
┌─────────────────────────────┐
│  Python FastMCP Server      │
│  - Tool Registry            │
│  - GitPython Client         │
│  - Error Handling           │
│  - Type Validation          │
└─────────────┬───────────────┘
              |
              | GitPython
              v
        Local Git Repo

Project Structure

git-mcp-server/
├── src/git_mcp_server/
│   ├── server.py              # Server entry point
│   ├── tools/
│   │   ├── branch.py          # Branch operations
│   │   ├── commit.py          # Commit operations
│   │   ├── remote.py          # Push/pull operations
│   │   ├── status.py          # Status queries
│   │   └── sync.py            # Sync with main
│   └── utils/
│       ├── git_client.py      # Singleton Repo instance
│       └── errors.py          # Structured error handling
└── tests/
    ├── test_*.py              # Unit tests
    └── integration/           # Integration tests

License

MIT License - see LICENSE for details.

Contributing

Contributions are welcome! Please read the contributing guidelines before submitting PRs.

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes with tests
  4. Submit a pull request

Links

README copy captured when this server was indexed; it may lag the repository. The original is authoritative.

Questions

About Git MCP Server

How do I install Git MCP Server?

No package has been published for this server, so install it from source: clone the repository and follow its README.

Is Git MCP Server safe to use with an AI agent?

Its trust score is 56 out of 100 (fair). It passes 2 of the 3 static security checks run so far; the failures are listed above. It has no ConduID identity yet, so agent calls to it are not receipted.

Is Git MCP Server still maintained?

The last commit was 8 months ago. That's long enough that you should check whether the maintainer is responding to issues before depending on it.