ssh_sed_replace
Find and replace text in a remote file over SSH using sed, with optional backup creation before modification.
Instructions
Find and replace text in a file using sed.
Args: file_path: Path to the file find: Text pattern to find replace: Replacement text session_name: SSH session to use backup: Create a .bak backup before modifying (default: True)
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": {
"file_path": "<file_path>",
"find": "<find>",
"replace": "<replace>"
},
"name": "ssh_sed_replace"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| find | Yes | ||
| backup | No | ||
| replace | Yes | ||
| file_path | Yes | ||
| session_name | No | default |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |