insert_into_file
Insert content into a file at a specified line position using the MCP File Editor Server. Choose to insert before or after a target line, or append to the end, with content verification for precise file modifications.
Instructions
Insert content into a file at a specific line position.
Input Schema
Name | Required | Description | Default |
---|---|---|---|
contents | Yes | Content to insert | |
file_path | Yes | Absolute path to the file | |
line_contents | Yes | Expected content of the target line (used for verification) | |
line_number | Yes | Line number to insert at (1-based). Use 0 to append to end. | |
where | Yes | Whether to insert before or after the target line |