fs_replace
Perform regex find and replace across multiple files using glob patterns, with optional dry-run to preview changes.
Instructions
Perform find and replace across multiple files.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"directory": "<directory>",
"pattern": "<pattern>",
"find": "<find>",
"replace": "<replace>"
},
"name": "fs_replace"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| find | Yes | Regex pattern to find. | |
| dryRun | No | If true, only returns what would be changed. | |
| pattern | Yes | Glob pattern for files to modify. | |
| replace | Yes | Replacement string. | |
| directory | Yes | The root directory. |