search_content
Search for text patterns across local files using regex, automatically skipping common directories like node_modules and .git for efficient results.
Instructions
Search for text pattern in files (grep-like functionality). Returns list of unique file paths containing the pattern. Recursively searches all subdirectories by default. Automatically skips node_modules, .git, dist, build directories and binary files for performance.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Relative path to search in. Use "." for root directory. | |
| pattern | Yes | Text pattern or regex to search for. | |
| file_pattern | No | Optional: Regex pattern to filter files by name. IMPORTANT: Use regex syntax, not glob. Examples: ".*\.txt$" for .txt files, ".*\.xlsx?$" for Excel files, ".*\.(js|ts)$" for JS/TS files. To search ALL files, OMIT this parameter entirely (do not use "*" or ".*"). | |
| case_sensitive | No | Whether search should be case sensitive. Default: false. | |
| max_results | No | Optional: Maximum number of results to return. Default: 1000. Use lower values for faster searches in large codebases. |