Fix edit tool failing on Windows due to CRLF line endings

Normalize line endings to LF before matching, restore original style on write.
Files with CRLF now match when LLMs send LF-only oldText.

Fixes #355
This commit is contained in:
Pratham Dubey 2025-12-30 02:32:16 +05:30
parent 65fb9116fb
commit 8c43a9fbc8
4 changed files with 113 additions and 10 deletions

View file

@ -6,6 +6,10 @@
- **`enabledModels` setting**: Configure whitelisted models in `settings.json` (same format as `--models` CLI flag). CLI `--models` takes precedence over the setting.
### Fixed
- **Edit tool fails on Windows due to CRLF line endings**: Files with CRLF line endings now match correctly when LLMs send LF-only text. Line endings are normalized before matching and restored to original style on write. ([#355](https://github.com/badlogic/pi-mono/issues/355))
## [0.30.2] - 2025-12-26
### Changed