Skip to main content
Glama

MCP Smart Filesystem Server

by lofcz

search_in_file

Find text patterns in specific files using regex search with context lines and case sensitivity options to locate code sections and content efficiently.

Instructions

Search for patterns within a specific file using ripgrep. Like Ctrl+F but with regex support. Useful for finding specific sections in a known file.

Input Schema

NameRequiredDescriptionDefault
pathYesFile path to search within
patternYesRegex pattern to search for
caseInsensitiveNoIgnore case in search. Default: true
contextLinesNoLines of context before/after match
literalStringNoTreat pattern as literal string, not regex
wordBoundaryNoMatch whole words only

Input Schema (JSON Schema)

{ "properties": { "caseInsensitive": { "default": true, "description": "Ignore case in search. Default: true", "type": "boolean" }, "contextLines": { "default": 3, "description": "Lines of context before/after match", "type": "number" }, "literalString": { "default": false, "description": "Treat pattern as literal string, not regex", "type": "boolean" }, "path": { "description": "File path to search within", "type": "string" }, "pattern": { "description": "Regex pattern to search for", "type": "string" }, "wordBoundary": { "default": false, "description": "Match whole words only", "type": "boolean" } }, "required": [ "path", "pattern" ], "type": "object" }

Other Tools from MCP Smart Filesystem Server

Related Tools

    MCP directory API

    We provide all the information about MCP servers via our MCP API.

    curl -X GET 'https://glama.ai/api/mcp/v1/servers/lofcz/mcp-filesystem-smart'

    If you have feedback or need assistance with the MCP directory API, please join our Discord server