Skip to main content
Glama
modelcontextprotocol

git MCP server

Official

mcp-server-git: Ein git MCP-Server

Übersicht

Ein Model Context Protocol-Server für die Interaktion mit und Automatisierung von Git-Repositories. Dieser Server stellt Werkzeuge bereit, um Git-Repositories über Large Language Models zu lesen, zu durchsuchen und zu bearbeiten.

Bitte beachten Sie, dass sich mcp-server-git derzeit in einem frühen Entwicklungsstadium befindet. Die Funktionalität und die verfügbaren Werkzeuge können sich ändern und erweitern, während wir den Server weiterentwickeln und verbessern.

Werkzeuge

  1. git_status

    • Zeigt den Status des Arbeitsverzeichnisses an

    • Eingabe:

      • repo_path (string): Pfad zum Git-Repository

    • Rückgabe: Aktueller Status des Arbeitsverzeichnisses als Textausgabe

  2. git_diff_unstaged

    • Zeigt Änderungen im Arbeitsverzeichnis an, die noch nicht für den Commit vorgemerkt (staged) sind

    • Eingaben:

      • repo_path (string): Pfad zum Git-Repository

      • context_lines (number, optional): Anzahl der Kontextzeilen, die angezeigt werden sollen (Standard: 3)

    • Rückgabe: Diff-Ausgabe der nicht vorgemerkten Änderungen

  3. git_diff_staged

    • Zeigt Änderungen an, die für den Commit vorgemerkt sind

    • Eingaben:

      • repo_path (string): Pfad zum Git-Repository

      • context_lines (number, optional): Anzahl der Kontextzeilen, die angezeigt werden sollen (Standard: 3)

    • Rückgabe: Diff-Ausgabe der vorgemerkten Änderungen

  4. git_diff

    • Zeigt Unterschiede zwischen Branches oder Commits an

    • Eingaben:

      • repo_path (string): Pfad zum Git-Repository

      • target (string): Ziel-Branch oder Commit für den Vergleich

      • context_lines (number, optional): Anzahl der Kontextzeilen, die angezeigt werden sollen (Standard: 3)

    • Rückgabe: Diff-Ausgabe des Vergleichs zwischen aktuellem Zustand und Ziel

  5. git_commit

    • Speichert Änderungen im Repository

    • Eingaben:

      • repo_path (string): Pfad zum Git-Repository

      • message (string): Commit-Nachricht

    • Rückgabe: Bestätigung mit dem neuen Commit-Hash

  6. git_add

    • Fügt Dateiinhalte zum Staging-Bereich hinzu

    • Eingaben:

      • repo_path (string): Pfad zum Git-Repository

      • files (string[]): Array von Dateipfaden zum Vormerken

    • Rückgabe: Bestätigung der vorgemerkten Dateien

  7. git_reset

    • Hebt die Vormerkung aller vorgemerkten Änderungen auf

    • Eingabe:

      • repo_path (string): Pfad zum Git-Repository

    • Rückgabe: Bestätigung des Reset-Vorgangs

  8. git_log

    • Zeigt die Commit-Logs mit optionaler Datumsfilterung an

    • Eingaben:

      • repo_path (string): Pfad zum Git-Repository

      • max_count (number, optional): Maximale Anzahl der anzuzeigenden Commits (Standard: 10)

      • start_timestamp (string, optional): Start-Zeitstempel für die Filterung von Commits. Akzeptiert ISO 8601-Format (z. B. '2024-01-15T14:30:25'), relative Daten (z. B. '2 weeks ago', 'yesterday') oder absolute Daten (z. B. '2024-01-15', 'Jan 15 2024')

      • end_timestamp (string, optional): End-Zeitstempel für die Filterung von Commits. Akzeptiert ISO 8601-Format (z. B. '2024-01-15T14:30:25'), relative Daten (z. B. '2 weeks ago', 'yesterday') oder absolute Daten (z. B. '2024-01-15', 'Jan 15 2024')

    • Rückgabe: Array von Commit-Einträgen mit Hash, Autor, Datum und Nachricht

  9. git_create_branch

    • Erstellt einen neuen Branch

    • Eingaben:

      • repo_path (string): Pfad zum Git-Repository

      • branch_name (string): Name des neuen Branches

      • base_branch (string, optional): Basis-Branch, von dem aus erstellt werden soll (Standard ist der aktuelle Branch)

    • Rückgabe: Bestätigung der Branch-Erstellung

  10. git_checkout

  • Wechselt Branches

  • Eingaben:

    • repo_path (string): Pfad zum Git-Repository

    • branch_name (string): Name des Branches, zu dem gewechselt werden soll

  • Rückgabe: Bestätigung des Branch-Wechsels

  1. git_show

  • Zeigt den Inhalt eines Commits an

  • Eingaben:

    • repo_path (string): Pfad zum Git-Repository

    • revision (string): Die Revision (Commit-Hash, Branch-Name, Tag), die angezeigt werden soll

  • Rückgabe: Inhalt des angegebenen Commits

  1. git_branch

  • Listet Git-Branches auf

  • Eingaben:

    • repo_path (string): Pfad zum Git-Repository.

    • branch_type (string): Ob lokale Branches ('local'), Remote-Branches ('remote') oder alle Branches ('all') aufgelistet werden sollen.

    • contains (string, optional): Der Commit-SHA, den der Branch enthalten sollte. Übergeben Sie nichts an diesen Parameter, wenn kein Commit-SHA angegeben ist

    • not_contains (string, optional): Der Commit-SHA, den der Branch NICHT enthalten sollte. Übergeben Sie nichts an diesen Parameter, wenn kein Commit-SHA angegeben ist

  • Rückgabe: Liste der Branches

Related MCP server: GitHub Tools MCP Server

Installation

Verwendung von uv (empfohlen)

Bei der Verwendung von uv ist keine spezielle Installation erforderlich. Wir verwenden uvx, um mcp-server-git direkt auszuführen.

Verwendung von PIP

Alternativ können Sie mcp-server-git über pip installieren:

pip install mcp-server-git

Nach der Installation können Sie es als Skript ausführen mit:

python -m mcp_server_git

Konfiguration

Verwendung mit Claude Desktop

Fügen Sie dies zu Ihrer claude_desktop_config.json hinzu:

"mcpServers": {
  "git": {
    "command": "uvx",
    "args": ["mcp-server-git", "--repository", "path/to/git/repo"]
  }
}
  • Hinweis: Ersetzen Sie '/Users/username' durch einen Pfad, auf den dieses Werkzeug zugreifen können soll

"mcpServers": {
  "git": {
    "command": "docker",
    "args": ["run", "--rm", "-i", "--mount", "type=bind,src=/Users/username,dst=/Users/username", "mcp/git"]
  }
}
"mcpServers": {
  "git": {
    "command": "python",
    "args": ["-m", "mcp_server_git", "--repository", "path/to/git/repo"]
  }
}

Verwendung mit VS Code

Für eine schnelle Installation verwenden Sie eine der untenstehenden Ein-Klick-Installationsschaltflächen...

Install with UV in VS Code Install with UV in VS Code Insiders

Install with Docker in VS Code Install with Docker in VS Code Insiders

Für eine manuelle Installation können Sie den MCP-Server mit einer dieser Methoden konfigurieren:

Methode 1: Benutzerkonfiguration (Empfohlen) Fügen Sie die Konfiguration zu Ihrer MCP-Konfigurationsdatei auf Benutzerebene hinzu. Öffnen Sie die Befehlspalette (Strg + Umschalt + P) und führen Sie MCP: Open User Configuration aus. Dies öffnet Ihre mcp.json-Datei auf Benutzerebene, in der Sie die Serverkonfiguration hinzufügen können.

Methode 2: Arbeitsbereichskonfiguration Alternativ können Sie die Konfiguration zu einer Datei namens .vscode/mcp.json in Ihrem Arbeitsbereich hinzufügen. Dies ermöglicht es Ihnen, die Konfiguration mit anderen zu teilen.

Weitere Details zur MCP-Konfiguration in VS Code finden Sie in der offiziellen VS Code MCP-Dokumentation.

{
  "servers": {
    "git": {
      "command": "uvx",
      "args": ["mcp-server-git"]
    }
  }
}

Für die Docker-Installation:

{
  "mcp": {
    "servers": {
      "git": {
        "command": "docker",
        "args": [
          "run",
          "--rm",
          "-i",
          "--mount", "type=bind,src=${workspaceFolder},dst=/workspace",
          "mcp/git"
        ]
      }
    }
  }
}

Verwendung mit Zed

Fügen Sie dies zu Ihrer Zed settings.json hinzu:

"context_servers": [
  "mcp-server-git": {
    "command": {
      "path": "uvx",
      "args": ["mcp-server-git"]
    }
  }
],
"context_servers": {
  "mcp-server-git": {
    "command": {
      "path": "python",
      "args": ["-m", "mcp_server_git"]
    }
  }
},

Verwendung mit Zencoder

  1. Gehen Sie zum Zencoder-Menü (...)

  2. Wählen Sie aus dem Dropdown-Menü Agent Tools aus

  3. Klicken Sie auf Add Custom MCP

  4. Fügen Sie den Namen (z. B. git) und die Serverkonfiguration von unten hinzu und stellen Sie sicher, dass Sie auf die Schaltfläche Install klicken

{
    "command": "uvx",
    "args": ["mcp-server-git", "--repository", "path/to/git/repo"]
}

Debugging

Sie können den MCP-Inspektor verwenden, um den Server zu debuggen. Für uvx-Installationen:

npx @modelcontextprotocol/inspector uvx mcp-server-git

Oder wenn Sie das Paket in einem bestimmten Verzeichnis installiert haben oder daran entwickeln:

cd path/to/servers/src/git
npx @modelcontextprotocol/inspector uv run mcp-server-git

Das Ausführen von tail -n 20 -f ~/Library/Logs/Claude/mcp*.log zeigt die Logs des Servers an und kann Ihnen helfen, Probleme zu debuggen.

Entwicklung

Wenn Sie lokal entwickeln, gibt es zwei Möglichkeiten, Ihre Änderungen zu testen:

  1. Führen Sie den MCP-Inspektor aus, um Ihre Änderungen zu testen. Siehe Debugging für Anweisungen zur Ausführung.

  2. Testen Sie mit der Claude Desktop-App. Fügen Sie Folgendes zu Ihrer claude_desktop_config.json hinzu:

Docker

{
  "mcpServers": {
    "git": {
      "command": "docker",
      "args": [
        "run",
        "--rm",
        "-i",
        "--mount", "type=bind,src=/Users/username/Desktop,dst=/projects/Desktop",
        "--mount", "type=bind,src=/path/to/other/allowed/dir,dst=/projects/other/allowed/dir,ro",
        "--mount", "type=bind,src=/path/to/file.txt,dst=/projects/path/to/file.txt",
        "mcp/git"
      ]
    }
  }
}

UVX

{
"mcpServers": {
  "git": {
    "command": "uv",
    "args": [
      "--directory",
      "/<path to mcp-servers>/mcp-servers/src/git",
      "run",
      "mcp-server-git"
    ]
    }
  }
}

Build

Docker-Build:

cd src/git
docker build -t mcp/git .

Lizenz

Dieser MCP-Server ist unter der MIT-Lizenz lizenziert. Dies bedeutet, dass Sie die Software frei verwenden, ändern und verbreiten dürfen, vorbehaltlich der Bedingungen der MIT-Lizenz. Weitere Details finden Sie in der LICENSE-Datei im Projekt-Repository.

Available Tools

12 tools
git_addB
Idempotent

Adds file contents to the staging area

ParametersJSON Schema
NameRequiredDescriptionDefault
filesYes
repo_pathYes

TDQS

B3/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare idempotentHint=true and destructiveHint=false, covering safety. The description adds no extra behavioral context beyond what annotations provide, such as behavior with non-existent files or overwriting staging.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence, making it very concise. However, it lacks structure; integrating parameter explanations or usage context would improve it without sacrificing brevity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity, the description is incomplete: no info on output, error handling, or parameter details. Context signals show no output schema, so the description shoulders more responsibility, which it fails to meet.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, yet the description does not explain the two required parameters (repo_path, files). The agent has no context on file path formats, glob patterns, or required directory specifications.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Adds file contents to the staging area' uses a specific verb and resource, clearly distinguishing it from sibling tools like git_commit (which commits staged changes) or git_branch (branch management).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives, such as using it before git_commit or how to add specific files. The description does not mention prerequisites, typical workflow, or when not to use it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_branchB
Read-onlyIdempotent

List Git branches

ParametersJSON Schema
NameRequiredDescriptionDefault
containsNoThe commit sha that branch should contain. Do not pass anything to this param if no commit sha is specified
repo_pathYesThe path to the Git repository.
branch_typeYesWhether to list local branches ('local'), remote branches ('remote') or all branches('all').
not_containsNoThe commit sha that branch should NOT contain. Do not pass anything to this param if no commit sha is specified

TDQS

B3.4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=true, covering the safety profile. The description adds no extra behavioral details (e.g., output format, ordering). Adequate but not enhanced.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Extremely concise (one sentence) and front-loaded. Efficient for a simple list operation, though slightly under-specified.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema and a simple list operation, the description is adequate but doesn't specify return format. Annotations cover safety, and sibling context helps, but completeness is minimal.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema fully documents all four parameters. The description does not add any additional meaning beyond what's in the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'List Git branches' uses a specific verb and resource, clearly indicating the tool's function. It distinguishes itself from siblings like git_create_branch (create) and git_checkout (switch).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives (e.g., git_create_branch for creation, git_checkout for switching). The description lacks context on scenarios or exclusions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_checkoutC

Switches branches

ParametersJSON Schema
NameRequiredDescriptionDefault
repo_pathYes
branch_nameYes

TDQS

C2.4/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations provide readOnlyHint=false, destructiveHint=false, idempotentHint=false, openWorldHint=false. Description adds no behavioral context beyond annotation, such as effects of uncommitted changes or merge conflicts. For a branching operation, this is a gap.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Extremely brief (two words), which could be considered concise, but lacks structure and substance. It is front-loaded but arguably under-specified.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness1/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's context (2 params, no output schema, simple but with side effects), the description is incomplete. It does not address what happens when switching branches (e.g., uncommitted changes, conflicts) or return value.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, and description does not explain parameters. Despite 'repo_path' and 'branch_name' being somewhat self-explanatory, the description fails to add meaning beyond the schema, which itself lacks descriptions. Baseline for low coverage requires compensation; here it is absent.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states 'Switches branches', a specific verb and resource. However, it does not differentiate from sibling tools like 'git_branch' (which likely lists/create/delete branches) or 'git_create_branch', but the action is distinct enough. Score 4 for clarity but lacking sibling differentiation.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives like 'git_create_branch' or 'git_branch'. No exclusions, prerequisites, or context provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_commitD

Records changes to the repository

ParametersJSON Schema
NameRequiredDescriptionDefault
messageYes
repo_pathYes

TDQS

D1.8/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description implies mutation (records changes) but offers no further behavioral details such as requiring staged changes, side effects, or commit creation. With no annotations providing behavioral info, the description is insufficient.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The single sentence is concise but lacks structure. It could be improved by adding a brief explanation of parameters and usage context without becoming verbose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple tool with two parameters and no output schema, the description omits critical details like parameter meanings and prerequisites (e.g., staged changes). It is incomplete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, yet the description does not explain either parameter (repo_path, message). It adds no meaning beyond the schema field names.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose2/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Records changes to the repository' is vague and does not differentiate git_commit from siblings like git_add, which also records changes. It fails to specify that it creates a permanent snapshot with a message, and the verb 'records' is too generic.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines1/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives (e.g., git_add for staging, git_reset for undoing). The description provides no context for selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_create_branchC

Creates a new branch from an optional base branch

ParametersJSON Schema
NameRequiredDescriptionDefault
repo_pathYes
base_branchNo
branch_nameYes

TDQS

C2.7/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already indicate not read-only and not destructive. The description adds no extra behavioral context, such as error behavior if branch already exists or default base branch behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Single sentence is very concise with no wasted words. Could benefit from a slightly more structured format, but remains efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple tool, the description covers the basic purpose but lacks details on default behavior (e.g., what branch is created from if base_branch is null) and error handling. Without an output schema, more explanation of return values would help.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0%, but description only clarifies the optional base_branch parameter. repo_path and branch_name are not elaborated beyond their names. The description adds minimal value over the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it creates a new branch from an optional base branch, which distinguishes it from siblings like git_branch (listing) and git_checkout (switching). However, it could be more specific about what 'from' means, e.g., 'based on current HEAD if base_branch is omitted'.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus alternatives like git_branch or git_checkout. No when-not or prerequisites provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_diffC
Read-onlyIdempotent

Shows differences between branches or commits

ParametersJSON Schema
NameRequiredDescriptionDefault
targetYes
repo_pathYes
context_linesNo

TDQS

C2.7/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description does not add behavioral context beyond what annotations already provide (readOnly, non-destructive, idempotent). It is acceptable but offers no extra transparency about edge cases or performance.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is only one sentence, making it concise. However, it lacks essential details, so the brevity harms completeness rather than being a virtue.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the presence of sibling tools and three parameters, the description is too minimal. It omits parameter explanations, usage context, and output expectations, making it incomplete for effective tool selection.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, and the description does not explain any parameter (repo_path, target, context_lines). The agent gets no help understanding the meaning or format of parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it shows differences between branches or commits, matching the tool's name. However, it does not differentiate from the sibling tools git_diff_staged and git_diff_unstaged, which are more specific variants.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool over its siblings (e.g., git_diff_staged, git_diff_unstaged). The agent is left to infer usage without explicit when-to or when-not-to directions.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_diff_stagedB
Read-onlyIdempotent

Shows changes that are staged for commit

ParametersJSON Schema
NameRequiredDescriptionDefault
repo_pathYes
context_linesNo

TDQS

B3.2/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations provide readOnlyHint: true and destructiveHint: false, so the safety profile is clear. The description adds no behavioral context beyond 'shows changes', omitting details like requirement of repo_path or default context_lines behavior. With annotations covering safety, the bar is lower, but the description still fails to add useful behavioral context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single concise sentence with no unnecessary wording. However, it could include additional relevant details (e.g., parameter explanations) without becoming overly verbose, so it is appropriately sized but not optimally informative.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a tool with no output schema and 0% schema description coverage, the description is incomplete. It does not specify that the output is a diff format, nor does it explain the context_lines parameter's effect. While the tool is simple, the lack of completeness could lead to agent confusion without additional context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, yet the description does not explain any parameter meaning. The parameter names (repo_path, context_lines) are somewhat self-explanatory, but the description adds no additional semantics, such as the purpose of context_lines or how repo_path is used. The description should compensate for the schema coverage gap but fails.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states 'Shows changes that are staged for commit', using specific verb 'Shows' and resource 'changes that are staged'. This effectively distinguishes it from siblings like 'git_diff_unstaged' (for unstaged changes) and 'git_diff' (likely for all changes).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No explicit when-to-use or when-not-to-use guidance is provided. However, the tool name and description imply it is for reviewing staged changes before commit, and the sibling tool names suggest alternatives. Usage context is implied but not elaborated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_diff_unstagedA
Read-onlyIdempotent

Shows changes in the working directory that are not yet staged

ParametersJSON Schema
NameRequiredDescriptionDefault
repo_pathYes
context_linesNo

TDQS

A3.5/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=true, so the safety profile is clear. The description adds no further behavioral context, but is consistent with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single concise sentence that communicates the primary purpose. It is front-loaded but could incorporate more information without becoming verbose.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the simplicity of the tool and existing annotations, the description is minimally adequate. However, it lacks parameter explanations and usage guidance, which would improve completeness for an agent.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description should explain the parameters. It does not mention repo_path or context_lines, relying solely on parameter names and titles. This is insufficient for correct invocation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Shows changes in the working directory that are not yet staged' uses a specific verb ('Shows') and resource ('changes') and clearly distinguishes from siblings like git_diff_staged.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description does not explicitly state when to use this tool vs alternatives like git_diff or git_diff_staged. The purpose is implied by the tool name, but no explicit guidance is provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_logC
Read-onlyIdempotent

Shows the commit logs

ParametersJSON Schema
NameRequiredDescriptionDefault
max_countNo
repo_pathYes
end_timestampNoEnd timestamp for filtering commits. Accepts: ISO 8601 format (e.g., '2024-01-15T14:30:25'), relative dates (e.g., '2 weeks ago', 'yesterday'), or absolute dates (e.g., '2024-01-15', 'Jan 15 2024')
start_timestampNoStart timestamp for filtering commits. Accepts: ISO 8601 format (e.g., '2024-01-15T14:30:25'), relative dates (e.g., '2 weeks ago', 'yesterday'), or absolute dates (e.g., '2024-01-15', 'Jan 15 2024')

TDQS

C2.6/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=true. The description adds no behavioral information beyond the tool's basic purpose, such as whether it returns a list or respects truncation.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single short sentence, which is concise but omits necessary details. It is not verbose, but could be more informative without losing conciseness.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a log tool with four parameters and no output schema, the description should explain return values (e.g., list of commits with hash, message). It does not mention output format or the effect of timestamp filters, making it incomplete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 50% (two of four parameters have descriptions). The tool description does not add meaning to the parameters, e.g., that repo_path is required or that max_count limits output. It relies solely on the schema for parameter details.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Shows the commit logs' clearly states the verb and resource, and it distinguishes from siblings like git_diff or git_show by focusing on the log. However, it is very brief and does not mention filtering or scope.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool vs alternatives such as git_show for individual commits or git_diff for changes. The description lacks context for appropriate usage.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_resetB
DestructiveIdempotent

Unstages all staged changes

ParametersJSON Schema
NameRequiredDescriptionDefault
repo_pathYes

TDQS

B3.3/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations indicate destructiveHint=true and readOnlyHint=false, which already signal mutation and potential data loss. The description confirms it unstages all changes but adds no further behavioral context, such as working directory being unaffected.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, straightforward sentence with no extraneous information, which is appropriate for a simple tool. However, it might be too brief to be fully useful.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity and single parameter, the description is moderately complete. It covers the core action but misses parameter details and fails to mention that only staged changes are affected, not working tree modifications.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description does not explain the required 'repo_path' parameter. The agent receives no guidance on how to specify the repository path or any expected format.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the specific verb 'unstages' and the resource 'all staged changes', which distinguishes it from sibling tools like git_add (stages) or git_diff_staged (shows staged diffs).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives, nor any context about prerequisites or post-conditions. It simply states the basic action.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_showC
Read-onlyIdempotent

Shows the contents of a commit

ParametersJSON Schema
NameRequiredDescriptionDefault
revisionYes
repo_pathYes

TDQS

C2.6/5.0
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint, destructiveHint, idempotentHint, and openWorldHint. The description adds minimal behavioral context beyond 'shows', not elaborating on what 'contents' entails (e.g., diff, metadata).

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, concise sentence of 6 words with no filler. It is front-loaded but may sacrifice detail for brevity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite the tool's simplicity, the description omits parameter explanations, return format (no output schema), and usage context. It provides the core purpose but is insufficient for correct invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, with no parameter descriptions in the schema. The description does not mention repo_path or revision, leaving their purpose and format entirely unexplained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Shows the contents of a commit' clearly states a specific verb and resource (contents of a commit). It differentiates from siblings like git_log (list commits) and git_diff (differences), though it doesn't explicitly contrast them.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus siblings such as git_diff or git_log. The description does not mention prerequisites or exclusions, leaving the agent without context for selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

git_statusB
Read-onlyIdempotent

Shows the working tree status

ParametersJSON Schema
NameRequiredDescriptionDefault
repo_pathYes

TDQS

B3.2/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, destructiveHint=false, and idempotentHint=true, fully covering safety and idempotency. The description adds no behavioral context beyond this, such as what specific information is shown or how it handles edge cases. It neither contradicts nor significantly extends the annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, front-loaded sentence with no wasted words. It conveys the core purpose efficiently, though it sacrifices detail for brevity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the lack of an output schema, the description should explain what the tool returns (e.g., list of changes, file states). It does not, leaving the agent to infer the output format. The description is insufficient for a tool that likely produces structured output, even with helpful annotations.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters1/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The single parameter 'repo_path' lacks a description in both the schema (0% coverage) and the tool description. The description does not explain what repo_path is, its format, or how to specify it (e.g., absolute vs relative path). This is a significant gap given the parameter is required.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description 'Shows the working tree status' uses a specific verb ('Shows') and resource ('working tree status'), clearly distinguishing it from sibling tools like git_diff (which show diffs) or git_log (which shows history).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies that the tool is used to inspect the current state of the working tree, but it provides no explicit guidance on when to use this tool versus alternatives (e.g., git_diff, git_log) or when not to use it. The usage context is implied by the tool name and description but not elaborated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. 12 tool updatesv1.0.0
    • Addedgit_add
    • Addedgit_branch
    • Addedgit_checkout
    • Addedgit_commit
    • Addedgit_create_branch
    • Addedgit_diff
    • Addedgit_diff_staged
    • Addedgit_diff_unstaged
    • Addedgit_log
    • Addedgit_reset
    • Addedgit_show
    • Addedgit_status

TDQS

B3.1/5.0
Disambiguation5/5

Each tool targets a distinct Git operation: staging, committing, branching, diffing, logging, etc. The three diff variants are clearly separated by scope (general, staged, unstaged). No two tools have overlapping purposes.

Naming Consistency5/5

All tools follow the 'git_<action>' pattern with lowercase snake_case. Verbs are clear and consistent (add, branch, checkout, commit, create_branch, diff, etc.), with no mixing of conventions.

Tool Count5/5

12 tools cover the core local Git workflow without being excessive. The number is well-scoped for a focused Git assistant, allowing agents to perform common tasks without overwhelming options.

Completeness3/5

The set covers staging, committing, branching, and diffing, but lacks essential operations like merge, rebase, remote actions (push/pull/fetch), branch deletion, and repository initialization. These gaps limit the workflow to basic local operations.

Maintenance

ActivityActive
ResponsivenessSlow

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    A
    quality
    C
    maintenance
    A Model Context Protocol server that enables Large Language Models to interact with Git repositories through a robust API, supporting operations like repository initialization, cloning, file staging, committing, and branch management.
    28
    7,389
    239
    Apache 2.0
  • A
    license
    B
    quality
    D
    maintenance
    A Model Context Protocol server that enables LLMs to interact with Git repositories, providing tools to read, search, and manipulate Git repositories through commands like status, diff, commit, and branch management.
    12
    MIT
  • A
    license
    C
    quality
    B
    maintenance
    A Model Context Protocol server that enables LLMs to interact with Git repositories, providing tools to read, search, and manipulate Git repositories through commands like status, diff, commit, and branch operations.
    22
    4
    MIT

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/modelcontextprotocol/git'

If you have feedback or need assistance with the MCP directory API, please join our Discord server