An MCP server for performing Git operations.
A Model Context Protocol (MCP) server for Git operations that provides comprehensive Git functionality to MCP clients like Claude Desktop.
npm install -g git-mcp-server
Clone and install:
git clone https://github.com/yourusername/git-mcp-server.git
cd git-mcp-server
npm install
Build the project:
npm run build
Add this server to your Claude Desktop configuration file:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"git": {
"command": "git-mcp-server",
"args": []
}
}
}
For other MCP clients, use the server binary directly:
git-mcp-server
The server will automatically use the current working directory as the Git repository context.
Once configured, you can use Git operations through your MCP client. The server automatically detects the Git repository in your current working directory.
Ask your MCP client (like Claude) to perform Git operations:
You can test the server manually from any Git repository:
cd /path/to/your/git/repo
git-mcp-server
git_status
- Get current git statusgit_current_branch
- Get current branch namegit_staged_changes
- Get staged changesgit_working_directory
- Get current working directory infogit_diff
- Show diff between branches/commitsgit_log
- Get commit historygit_show_file
- Show file contents at specific commitgit_branches
- List all branchesgit_checkout
- Switch to different branch or create new branchgit_add
- Add files to staging areagit_commit
- Create commits with message and filesgit_pull
- Pull changes from remote repositorygit_fetch
- Fetch changes from remote without merginggit_init
- Initialize a new git repositoryMIT License - see LICENSE file for details.
git-mcp-server/
├── package.json # Project dependencies and scripts
├── tsconfig.json # TypeScript configuration
├── src/
│ └── index.ts # Main server implementation
├── build/
│ └── index.js # Compiled JavaScript (generated)
└── README.md # This file
npm run build
- Build the TypeScript codenpm run dev
- Watch mode for developmentnpm start
- Run the built serverAn MCP server for interacting with and automating Git repositories using Large Language Models.
Visualize Git history and commit logs with animations, making Git operations intuitive and easy to understand.
An MCP server that allows AI assistants to create and delete GitHub repositories. Requires a GITHUB_TOKEN for authentication.
Allows AI assistants to interact with the GitHub API for repository management, code collaboration, and other development tasks.
Analyze and query GitHub repositories using the GitHub Chat API.
Explore GitHub repositories, including file content, directory structure, and other metadata.
Manage GitHub projects with requirements traceability and advanced workflows.
Make git commits on behalf of AI to track AI contributions in your codebase.
Interact with Radicle (peer-to-peer code collaboration) and GitHub through a unified interface.
AI-powered GitHub project management with complete requirements traceability.