Git Stuff Server
The Git Stuff Server is a Node.js application that provides Git-related functionalities via a Model Context Protocol (MCP) server. You can:
Generate Git Merge Diffs: Create text diffs for Git merge commits against their first parent using the
get_git_merge_difftool (requirescommitHashandrepoPathinputs)Fetch Azure DevOps PR Changed Files: Retrieve a list of changed files from the latest iteration of an Azure DevOps Pull Request using the
get_ado_pr_changed_filestool (requirespullRequestIdandorganizationIdinputs)
Provides Git-related functionality, specifically a tool to generate the diff for a Git merge commit against its first parent by running 'git show -m --first-parent' on a specified commit hash.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Git Stuff Server show me the diff for merge commit abc123def"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Git Stuff Server
This repository contains a Node.js application that acts as an MCP (Model Context Protocol) server to provide Git-related functionalities. Currently, it offers a tool to generate the diff for a Git merge commit against its first parent.
Features
MCP Server: Runs as a standard MCP server using stdio for communication.
get_git_merge_diffTool:Accepts a Git merge commit hash.
Executes the
GenerateMergeDiff.ps1PowerShell script.Returns the textual diff content generated by
git show -m --first-parent <commitHash>.
Related MCP server: agent-services-mcp
Prerequisites
Node.js (Version supporting ES Modules, check
enginesin package.json if specified, otherwise checktsconfig.jsontarget - ES2022)npm (usually comes with Node.js)
Git installed and accessible in the system's PATH.
PowerShell (Windows) or
pwsh(Linux/macOS) installed and accessible in the system's PATH.
Installation
Clone the repository:
git clone <your-repo-url> cd GitStuffServerInstall dependencies:
npm install
Usage
Build the TypeScript code:
npm run buildThis compiles the TypeScript code from
src/to JavaScript inbuild/.Run the server:
To run the compiled code:
npm startTo build and run in development mode:
npm run dev
The server will start and listen for MCP requests on standard input/output.
Using the get_git_merge_diff Tool
When connected via an MCP client, you can call the get_git_merge_diff tool with the following input:
commitHash(string): The Git commit hash (SHA) of the merge commit you want to diff.
The tool will return the diff content as text.
How it Works
The MCP server (
src/index.ts) receives a request for theget_git_merge_difftool.It validates the
commitHashinput.It executes the
GenerateMergeDiff.ps1PowerShell script, passing thecommitHash.The PowerShell script runs
git show -m --first-parent <commitHash>and saves the output (including any errors) to a temporary file namedmerge_changes.diffin the server's current working directory.The Node.js server reads the content of
merge_changes.diff.The server deletes the temporary
merge_changes.difffile.The server returns the diff content (or an error message) to the MCP client.
Configuration
Key configuration points are defined as constants within src/index.ts:
SERVER_NAME: The name registered by the MCP server.SCRIPT_NAME: The filename of the PowerShell script to execute.OUTPUT_DIFF_FILE: The name of the temporary diff file created by the script.
License
This project is licensed under the MIT License - see the package.json file for details.
Available Tools
4 toolsado_pr_changesC
Fetches changes from an Azure DevOps Pull Request with full diff content using the Azure DevOps Node API.
Inputs: organizationId (required), pullRequestId (required).
ado_pr_commentB
Posts a comment to an Azure DevOps Pull Request. Can reply to existing threads or create new ones.
Inputs: commentsToPost (required), pullRequestId (required), organizationId.
ado_pr_threadsC
Fetches all active comment threads from an Azure DevOps Pull Request.
Inputs: pullRequestId (required), organizationId.
git_merge_diffB
Generates the text diff for a Git merge commit against its first parent within a specified local repository.
Inputs: commitHash (required), repoPath (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 4 tools
Three tools (ado_pr_changes, ado_pr_comment, ado_pr_threads) are clearly distinct and focused on Azure DevOps pull request operations, with no overlap in their purposes. The fourth tool (git_merge_diff) is unrelated to Azure DevOps and operates on local Git repositories, creating a minor domain mismatch but no functional ambiguity.
The naming is inconsistent across the tool set. The first three tools use a consistent 'ado_pr_' prefix with descriptive suffixes (changes, comment, threads), but the fourth tool uses a different 'git_' prefix with a different structure (merge_diff). This mixed convention reduces predictability and coherence.
With only 4 tools, the count feels thin for a server named 'Git Stuff Server', which implies broader Git-related functionality. The tools are split between Azure DevOps PR operations and a local Git diff tool, making the scope appear fragmented rather than comprehensive.
For Azure DevOps pull requests, the tools cover fetching changes, commenting, and fetching threads, but lack core operations like creating, updating, or merging pull requests. For local Git operations, only one diff tool is provided, missing basic commands like clone, commit, or push. This results in significant gaps that will hinder agent workflows.
Maintenance
Related MCP Connectors
A MCP server built for developers enabling Git based project management with project and personal…
MCP server for siGit (sigit.si): browse repos, search code, manage PRs/issues, web search.
Create, deploy, and operate MCP servers directly from your GitHub repositories.
Related MCP Servers
- AlicenseBqualityDmaintenanceA specialized MCP server for in-depth analysis of git repositories, offering tools for branch overview, time period analysis, file changes, and merge recommendations.47Apache 2.0
- AlicenseBqualityDmaintenanceMCP Server for Git operations, agent templates, and project utilities.952 npmMIT
- AlicenseAqualityDmaintenanceA local MCP server that provides a safe, explicit set of Git operations for version control tasks like status, diff, branching, staging, committing, fetching, merging, and pushing.134 npmMIT
- AlicenseAqualityCmaintenanceMCP server for git archaeology — churn hotspots, blame summaries, bus factor, commit forensics and file history over any local repository.113MIT