Skip to main content
Glama
ceshine

Git Prompts MCP Server

by ceshine

GitがMCPサーバーにプロンプトを出す

このリポジトリは、Git リポジトリの内容に基づいてプロンプトを生成するためのいくつかのコマンドを提供するモデル コンテキスト プロトコル (MCP) サーバーを提供します。

(このリポジトリは、MarkItDown MCP サーバーとサンプルGit MCP サーバーから多大なインスピレーションを得ています。)

インストール

手動インストール

  1. このリポジトリをクローンする

  2. 依存関係をインストール: uv sync --frozen

Related MCP server: Git MCP Server

使用法

Zed EditorのMCPサーバーとして

次の内容をsettings.jsonに追加します。

"context_servers": {
  "git_prompt_mcp": {
    "command": {
      "path": "uv",
      "args": [
        "--directory",
        "/path/to/local/git_prompts_mcp_server",
        "run",
        "git-prompts-mcp-server",
        "/path/to/repo/", // parent folder of the .git directory
        "--excludes", // exclude files and directories from diff results
        "**/uv.lock",
        "--excludes",
        "**/.gitignore",
        "--format", // format for diff results
        "json"  // options: json, text
      ]
    },
    "settings": {}
  }
}

コマンド

サーバーは次のコマンドに応答します。

  1. /git-diff <ancestor_branch_or_commit> : HEAD と指定された祖先ブランチまたはコミット間の diff 結果を入力します。

  2. /generate-pr-desc <ancestor_branch_or_commit> : HEAD と指定された祖先ブランチまたはコミット間の diff 結果に基づいて、プル リクエストの説明を生成します。

  • 注: これは/git-diffとほぼ同じですが、出力の最後にプル リクエストの説明を生成するための手順が含まれています。

  1. /git-cached-diff : ステージングされた変更と HEAD の diff 結果を入力します。

例:

  1. /generate-pr-desc main

  2. /git-diff dev

  3. /git-cached-diff

ライセンス

MITライセンス。詳細はライセンスを参照してください。

Install Server
A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

Resources

Looking for Admin?

Admins can modify the Dockerfile, update the server description, and track usage metrics. If you are the server author, to access the admin panel.

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/ceshine/git-prompts-mcp-server'

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