Skip to main content

MCP server for analyzing Git repositories - extracts code structure, patterns, and documentation

Project description

MCP Git Analyzer

Git 저장소를 분석하여 코드 구조, 알고리즘 패턴, 문서를 추출하고 DB에 저장하는 MCP 서버입니다.

Features

  • 저장소 클론 및 관리: Git URL로 저장소 클론, 브랜치 지정 가능
  • 코드 분석: 함수, 클래스, import, docstring 추출
  • 패턴 감지: 알고리즘 패턴 (재귀, DP, 정렬 등) 식별
  • 전문 검색: SQLite FTS5 기반 키워드 검색
  • LLM 친화적: 구조화된 JSON 응답

Installation

uv pip install -e .

Configuration

환경변수로 저장 경로를 설정합니다:

환경변수 설명 기본값
GIT_ANALYZER_REPOS_PATH 클론된 저장소 저장 경로 ~/.mcp-git-analyzer/repos
GIT_ANALYZER_DB_PATH SQLite DB 파일 경로 ~/.mcp-git-analyzer/analysis.db

Claude Desktop 설정

claude_desktop_config.json:

{
  "mcpServers": {
    "git-analyzer": {
      "command": "uv",
      "args": ["run", "mcp-git-analyzer"],
      "env": {
        "GIT_ANALYZER_REPOS_PATH": "C:/repos",
        "GIT_ANALYZER_DB_PATH": "C:/repos/analysis.db"
      }
    }
  }
}

Available Tools

Git 관리

  • clone_repo(url, branch?) - 저장소 클론
  • list_repos() - 등록된 저장소 목록
  • get_repo_tree(repo_id) - 저장소 파일 구조

분석

  • analyze_repo(repo_id) - 전체 저장소 분석
  • get_symbol_details(name) - 심볼 상세 정보

검색

  • search_code(query, type?) - 코드 검색
  • find_patterns(pattern_type) - 패턴 검색

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mcp_git_analyzer-0.1.0.tar.gz (47.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mcp_git_analyzer-0.1.0-py3-none-any.whl (55.6 kB view details)

Uploaded Python 3

File details

Details for the file mcp_git_analyzer-0.1.0.tar.gz.

File metadata

  • Download URL: mcp_git_analyzer-0.1.0.tar.gz
  • Upload date:
  • Size: 47.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.12

File hashes

Hashes for mcp_git_analyzer-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6f050dbb04d6ea229842abeb8d8d7e5479df3560301fe9a38988e3520898ea17
MD5 fbd0862cb1e449d20c8d51c5d90d9469
BLAKE2b-256 b7aebca2e5567f3d79e0a8dd3d83c9def8739ef464fef3e1891e497ba0ef6d9f

See more details on using hashes here.

File details

Details for the file mcp_git_analyzer-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for mcp_git_analyzer-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 8f8c48e52daebee32141b1cf07b017a70b894987fa430dd99bc35d32a82ff206
MD5 a1e0111192e645e071afb0228ebe2535
BLAKE2b-256 8e850af315da3109ac63079a09ffc0c6ea2e787fd1f492f5a9bb8e5b1519d5e0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page