Back to MCP directory
publicPublicdnsLocal runtime

ast-grep

一个基于ast-grep的实验性MCP实现项目

article

README

🚀 实验性 MCP 项目

这是一个使用 ast-grep CLI 实现的实验性 MCP 项目。该项目借助相关工具,为代码操作和管理提供了新的可能,能帮助用户更高效地处理代码。

🚀 快速开始

✅ 先决条件

  1. 安装 ast-grepuv
  2. 安装 MCP 客户端,建议使用 Cursor。
  3. 克隆此仓库,并通过 uv 进行安装。
  4. 配置 MCP JSON,示例如下:
{
    "mcpServers": {
      "server-name": {
        "command": "uv",
        "args": ["--directory", "/path/to/repo", "run", "main.py"],
        "env": {}
      }
    }
  }
  1. 配置完成后,就可以让 Cursor AI 搜索你的代码库啦!
help

Runtime guide

cloud

Hosted runtime

Hosted servers run from a provider-managed environment. You usually connect the MCP client to the hosted endpoint or follow the provider's authorization flow, without keeping a local process alive

  1. Open provider connection page
  2. Authorize or copy endpoint
  3. Connect from your MCP client
terminal

Local runtime / other methods

Local servers run on your own machine or infrastructure. You normally copy the server_config into your MCP client, install the required package, and provide env variables from env_schema when needed

  1. Copy server_config
  2. Install required package
  3. Fill env variables and restart client