MCP.so
登录

MCP Git Explorer

@jmiedzinski

关于 MCP Git Explorer

Simple MCP server for fetching the remote git repository content as a structured text file

配置

使用下面的配置,将此服务器添加到你的 MCP 客户端。

{
  "mcpServers": {
    "mcp-git-explorer": {
      "command": "uv",
      "args": [
        "pip",
        "install",
        "mcp-git-explorer"
      ]
    }
  }
}

工具

未检测到工具

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is MCP Git Explorer?

MCP Git Explorer is a Model Context Protocol (MCP) server that clones remote Git repositories and returns their contents as a structured text file. It is designed for AI assistants like Claude, allowing them to explore repository structure, estimate codebase size and token count, and access file contents without manual downloading.

How to use MCP Git Explorer?

Install via pip install mcp-git-explorer or uv pip install mcp-git-explorer. Run directly with mcp-git-explorer (or uvx mcp-git-explorer). Optionally pass --transport sse for SSE transport or --gitlab-token YOUR_TOKEN for private GitLab repositories. In Claude, the server provides three tools: get_codebase, estimate_codebase, and check_gitlab_token_status.

Key features of MCP Git Explorer

  • Clones and analyzes Git repositories from remote URLs.
  • Generates a structured text representation of all file contents.
  • Estimates codebase size and token count without full download.
  • Supports public repositories and private GitLab repositories via token authentication.
  • Token counting using OpenAI’s tiktoken library.
  • Respects .gitignore and .repomixignore patterns; skips binary and empty text files.

Use cases of MCP Git Explorer

  • Quickly assess repository size before deciding to retrieve full content.
  • Enable Claude to browse and analyze code from any public Git repository.
  • Access private GitLab repositories with a personal access token.
  • Automatically generate a token-aware summary of a codebase.
  • Integrate repository exploration into AI‑powered coding workflows.

FAQ from MCP Git Explorer

What types of Git repositories are supported?

Public repositories on any Git hosting service, plus private GitLab repositories when a personal access token is provided via --gitlab-token or the GIT_EXPLORER_GITLAB_TOKEN environment variable.

How do I authenticate to private GitLab repositories?

Provide a GitLab personal access token either as the --gitlab-token CLI argument or set the GIT_EXPLORER_GITLAB_TOKEN environment variable. Use the check_gitlab_token_status tool to confirm it is configured.

What does the estimate_codebase tool return?

It returns repository statistics: file count, directory structure, and a token estimation (using OpenAI’s tiktoken) without downloading all file contents.

Can I control whether file contents are included when using get_codebase?

Yes. The use_token parameter (default True) controls token counting behavior. When True, the response includes token counts; set to False to skip token estimation.

Is there any file filtering or size limit?

The server respects .gitignore and .repomixignore patterns, skips binary files and empty text files to keep the output concise and relevant.

常见问题

What types of Git repositories are supported?

Public repositories on any Git hosting service, plus private GitLab repositories when a personal access token is provided via `--gitlab-token` or the `GIT_EXPLORER_GITLAB_TOKEN` environment variable.

How do I authenticate to private GitLab repositories?

Provide a GitLab personal access token either as the `--gitlab-token` CLI argument or set the `GIT_EXPLORER_GITLAB_TOKEN` environment variable. Use the `check_gitlab_token_status` tool to confirm it is configured.

What does the `estimate_codebase` tool return?

It returns repository statistics: file count, directory structure, and a token estimation (using OpenAI’s tiktoken) without downloading all file contents.

Can I control whether file contents are included when using `get_codebase`?

Yes. The `use_token` parameter (default `True`) controls token counting behavior. When `True`, the response includes token counts; set to `False` to skip token estimation.

Is there any file filtering or size limit?

The server respects `.gitignore` and `.repomixignore` patterns, skips binary files and empty text files to keep the output concise and relevant.

评论

版本控制 分类下的更多 MCP 服务器