(path: str, content: str)
| 150 | return f"Error: {e}" |
| 151 | |
| 152 | def run_write(path: str, content: str) -> str: |
| 153 | try: |
| 154 | fp = safe_path(path) |
| 155 | fp.parent.mkdir(parents=True, exist_ok=True) |
| 156 | fp.write_text(content) |
| 157 | return f"Wrote {len(content)} bytes" |
| 158 | except Exception as e: |
| 159 | return f"Error: {e}" |
| 160 | |
| 161 | def run_edit(path: str, old_text: str, new_text: str) -> str: |
| 162 | try: |
no test coverage detected