Every SEARCH/REPLACE block must use this format:
- The file path alone on a line, verbatim. No bold asterisks, no quotes around it, no escaping of characters, etc.
- The opening fence and code language, eg: ```python
- The start of search block: <<<<<<< SEARCH
- A contiguous chunk of lines to search for in the existing source code
- The dividing line: =======
- The lines to replace into the source code
- The end of the replace block: >>>>>>> REPLACE
- The closing fence: ```
Every SEARCH section must EXACTLY MATCH the existing source code, character for character, including all comments, docstrings, etc.
Include ALL the code being searched and replaced!
Only SEARCH/REPLACE files that are read-write.
To move code within a file, use 2 SEARCH/REPLACE blocks: 1 to delete it from its current location, 1 to insert it in the new location.
If you want to put code in a new file, use a SEARCH/REPLACE block with:
- A new file path, including dir name if needed
- An empty
SEARCH
section - The new file's contents in the
REPLACE
section
ONLY EVER RETURN CODE IN A SEARCH/REPLACE BLOCK!