Hey, thanks for the detailed report - this matches a known issue with auto-modifications on IDE startup (discussion and ticket already exist):
- Thread: Cursor modifying files on startup
- Similar cases: The cursor adds blank lines
We need your help to clarify, it’s important:
- Can you attach a git diff of the affected PHP files: is it just spaces/blank lines or an actual rollback to old code?
- Were there any “unaccepted” changes from the Agent in these files (did you see a banner with Review/Keep/Undo)?
- Check if it reproduces when starting with extensions disabled:
cursor --disable-extensions - Run
git config core.autocrlfand share the value.
Temporary steps that have helped others:
- Open each affected file and click Keep/Undo in the top banner (or “Accept all changes” in Review) for all files with pending changes.
- Then restart Cursor and check if the auto-modifications disappear.
Let me know if the workaround helps - it will speed up the fix.