Git Code Review MCP

Git Code Review MCP

Enables AI assistants to perform code reviews by providing access to staged files, git diffs, and repository file content. It allows users to evaluate changes and context within any local git repository before committing or pushing.

Category
Visit Server

README

Git Code Review MCP

An MCP (Model Context Protocol) server that allows AI to review your changes before pushing. This tool provides AI assistants with access to git repository information, staged files, and diffs to help with code review workflows.

Features

  • Get Staged Files: List all files currently staged for commit
  • View Diffs: Show the diff of staged changes with space-change filtering
  • File Content Access: Retrieve the content of any file from the repository
  • Repository Agnostic: Works with any git repository by specifying the path

Example MCP Client Configuration

If you're using this with an MCP client, add it to your configuration:

{
  "mcpServers": {
    "git-codereview": {
      "command": "npx",
      "args": ["git-codereview"]
    }
  }
}

Installation

The easiest way to use this MCP server is with npx:

npx git-codereview

This will run the MCP server directly without needing to install it globally.

Alternative Installation Methods

Global Installation

npm install -g git-codereview
git-codereview

Local Development

git clone https://github.com/AyoubTRD/git-codereview-mcp.git
cd git-codereview-mcp
npm install
npm run build
node build/index.js

Usage

This MCP server runs over stdio and is designed to be used with MCP-compatible AI tools. The server provides three main tools:

Available Tools

  1. get_staged_files

    • Lists all files currently staged for commit
    • Requires: repoPath (full path to git repository)
  2. get_diff

    • Shows the diff of staged files with added/modified filter
    • Ignores whitespace changes for cleaner output
    • Requires: repoPath (full path to git repository)
  3. get_file_content

    • Retrieves the content of any file from the repository
    • Useful when diff doesn't provide enough context
    • Requires: repoPath (full path to git repository) and filePath (relative path to file)

Requirements

  • Node.js (version 16 or higher)
  • Git repository (the target repository must be git-initialized)
  • MCP-compatible AI tool or client

License

ISC

Contributing

Issues and pull requests are welcome at GitHub.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured