local-only server
The server can only run on the client’s local machine because it depends on local resources.
Integrations
Exposes the system grep binary functionality through MCP, allowing for searching patterns in files using regular expressions, with support for case-insensitive matching, context lines, maximum match count, fixed string matching, and recursive directory searching.
Mentioned as part of the development workflow, but not as a primary integration target for the MCP server.
Used for implementation and client access, but not as a primary integration target for the MCP server.
MCP-Grep
A grep server implementation that exposes grep functionality through the Model Context Protocol (MCP).
Installation
Usage
MCP-Grep runs as a server that can be used by MCP-compatible clients:
The server exposes the following MCP functionality:
- Resource:
grep://info
- Returns information about the system grep binary - Tool:
grep
- Searches for patterns in files using the system grep binary
Features
- Information about the system grep binary (path, version, supported features)
- Search for patterns in files using regular expressions
- Support for common grep options:
- Case-insensitive matching
- Context lines (before and after matches)
- Maximum match count
- Fixed string matching (non-regex)
- Recursive directory searching
- Natural language prompt understanding for easier use with LLMs
- Interactive debugging and testing through MCP Inspector
Example API Usage
Using the MCP Python client:
Natural Language Prompts
MCP-Grep understands natural language prompts, making it easier to use with LLMs. Examples:
MCP Inspector Integration
MCP-Grep includes an MCP Inspector integration for interactive debugging and testing:
This opens a web-based UI where you can:
- Explore available resources and tools
- Test grep operations with different parameters
- View formatted results
- Debug issues with your grep queries
Development
License
MIT
This server cannot be installed
A server implementation that exposes grep functionality through the Model Context Protocol, allowing MCP-compatible clients to search for patterns in files using regular expressions.