ast-grep is a fast and polyglot tool for code structural search, lint, rewriting at large scale.
10K+
ast-grep is a fast and polyglot tool for code structural search, lint, rewriting at large scale.
| Attribute | Details |
|---|---|
| Docker Image | mcp/ast-grep |
| Author | dgageot |
| Repository | https://github.com/dgageot/mcp-ast-grep |
| Attribute | Details |
|---|---|
| Dockerfile | https://github.com/dgageot/mcp-ast-grep/blob/c0a1edaf9cd6b168f2b59bc5a0161ad49a793099/Dockerfile |
| Commit | c0a1edaf9cd6b168f2b59bc5a0161ad49a793099 |
| Docker Image built by | Docker Inc. |
| Docker Scout Health Score | |
| Verify Signature | COSIGN_REPOSITORY=mcp/signatures cosign verify mcp/ast-grep --key https://raw.githubusercontent.com/docker/keyring/refs/heads/main/public/mcp/latest.pub |
| Licence | Apache License 2.0 |
| Tools provided by this Server | Short Description |
|---|---|
ast-grep | Search codebases using ast-grep patterns |
ast-grepSearch codebases using ast-grep patterns for straightforward structural matches. (returns json)
| Parameters | Type | Description |
|---|---|---|
pattern | string | The ast-grep pattern to search for. Note, the pattern must have valid AST structure. |
dir | string optional | The directory to search in. If not specified, will use the current working directory. |
lang | string optional | The language of the code. If not specified, will be auto-detected based on file extensions. |
This tool is read-only. It does not modify its environment.
This tool may perform destructive updates.
This tool interacts with external entities.
{
"mcpServers": {
"ast-grep": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-v",
"/local-directory:/local-directory",
"mcp/ast-grep"
]
}
}
}
Content type
Image
Digest
sha256:5fc3f2e9d…
Size
9.6 MB
Last updated
4 months ago
Requires Docker Desktop 4.37.1 or later.
Pulls:
1,780
Last week