pr_reviewer
This project implements an MCP (Model Context Protocol) server integrated with Claude Desktop. The server automatically analyzes your Pull Requests, reviews your changes, and adds comments directly to the modified files. It can also approve and merge your PRs. Additionally, the review is saved to a Google Doc in your Google Drive.
MCP Server
This project implements an MCP (Model Context Protocol) server integrated with Claude Desktop. The server automatically analyzes your Pull Requests, reviews your changes, and adds comments directly to the modified files. It can also approve and merge your PRs. Additionally, the review is saved to a Google Doc in your Google Drive.
Prerequisites
Before running the MCP server, ensure you have the following libraries installed:
requestspython-dotenvmcp[cli]pydrive
If additional libraries are required, install them using pip or uv as needed.
How to Run the MCP Server
Follow these steps to set up and run the MCP server:
Claude Desktop Configuration
After cloning the repository, you'll need to configure Claude Desktop to run the MCP server.
- Download Claude Desktop
- Open Settings → Developer.
- Click Edit Config, then paste the following code:
{
"mcpServers": {
"pr_reviewer": {
"command": "uv",
"args": [
"--directory",
"/path/to/mcp/project",
"run",
"pr-analyzer.py"
]
}
}
}
Note:
If you don't have uv installed, you can modify the config to usepythoninstead ofuvto run the MCP.
GitHub Setup
To generate a GitHub token:
- Log in to your GitHub account and navigate to Settings → Developer Settings → Personal Access Tokens.
- Click Generate New Token (choose the classic version).
- Provide a name for the token and enable the following permissions:
read:orgread:repo_hookrepo
- Click Generate to create the token.
- Save the token, you will need it in the
.envfile later.
Google Drive Setup
To enable Google Drive access, make sure you set up authentication.
Follow this guide to obtain your credentials.
Creating the .env File
Create a .env file in the project directory and add the following:
GITHUB_TOKEN=""
GOOGLE_PARENT_FOLDER_ID="" # optional
GOOGLE_PARENT_FOLDER_ID is the ID of the Google Drive folder where your generated reviews will be organized.
You can find it as the last part of the URL in a link like:
https://drive.google.com/drive/folders/<folder_id>
Demo
Recommend MCP Servers 💡
MacOS Resource Monitor
A Model Context Protocol (MCP) server that identifies resource-intensive processes on macOS across CPU, memory, and network usage.
risken-mcp-server
An MCP server providing seamless integration with RISKEN APIs for security operations automation
JetBrains/mcp-jetbrains
A Model Context Protocol (MCP) server that acts as a proxy to integrate JetBrains IDEs (IntelliJ, PyCharm, WebStorm, Android Studio) with MCP clients, enabling AI tools to interact with the IDE's context.
cve-search_mcp
A Model Context Protocol (MCP) server for querying the CVE-Search API
cbi-mcp-server
Provides an interface for developers to interact with CB Insights ChatCBI LLM through AI Agents.
dank-mcp
An MCP server that provides tools and data for cannabis datasets, enabling Large Language Models (LLMs) to answer questions about cannabis products and related information.