cyanheads_git-mcp-server

cyanheads_git-mcp-server

3.5

A Model Context Protocol server that provides comprehensive Git functionality to Large Language Models, enabling them to perform version control operations through a secure and standardized interface.

The Git MCP Server implements the Model Context Protocol (MCP), created by Anthropic, which provides a standardized communication protocol between LLMs and external systems. The architecture consists of clients (such as Claude Desktop and IDEs) that maintain server connections, servers that provide tools and resources to clients, and LLMs that interact with servers through client applications. This architecture creates a secure boundary between LLMs and external systems while enabling controlled access to Git functionality. Through the MCP protocol, the Git server empowers LLMs to perform version control operations, manage repositories, and handle complex Git workflows — all within a secure and validated environment.

Features

  • {'name': 'Core Git Operations', 'description': 'Repository initialization and cloning, file staging and committing, branch management, remote operations, tag handling, and stash management.'}
  • {'name': 'Bulk Operations', 'description': 'Sequential operation execution, atomic commits, smart defaults, and error resilience.'}
  • {'name': 'Safety Features', 'description': 'Path validation, repository state verification, embedded repository handling, and comprehensive error reporting.'}

MCP Tools

  • init: Initializes a new Git repository.
  • clone: Clones a repository.
  • status: Gets repository status.
  • bulk_action: Executes multiple Git operations in sequence.
  • branch_list, branch_create, branch_delete, checkout: Manage branches and working tree.
  • tag_list, tag_create, tag_delete: Manage repository tags.
  • remote_list, remote_add, remote_remove: Manage remote repositories.
  • stash_list, stash_save, stash_pop: Manage working directory changes.

Usage with Different Platforms

mcp


{
  "mcpServers": {
    "git": {
      "command": "node",
      "args": ["/path/to/git-mcp-server/build/index.js"],
      "env": {
        "GIT_DEFAULT_PATH": "/optional/default/path/for/git/operations"
      }
    }
  }
}