On Cursor launch, files become modified in git

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

Every time I open Cursor, various files are in modified status in git with old changes. I have to revert them to get back to my clean branch checkout with no changes.

Steps to Reproduce

Open Cursor on a project that has git tracking.

Expected Behavior

No files should have changes since they didn’t when Cursor was closed.

Operating System

Windows 10/11

Current Cursor Version (Menu → About Cursor → Copy)

Version: 2.1.50 (user setup)
VSCode Version: 1.105.1
Commit: 56f0a83df8e9eb48585fcc4858a9440db4cc7770
Date: 2025-12-06T23:39:52.834Z
Electron: 37.7.0
Chromium: 138.0.7204.251
Node.js: 22.20.0
V8: 13.8.258.32-electron.0
OS: Windows_NT x64 10.0.26200

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey, thanks for the report. This matches a known issue we’re already tracking: Cursor modifying files on startup.

Please try these temporary workarounds:

  • Open files marked as changed and, in the Review banner, click Keep/Accept for all related Agent edits. Also check older Agent chats: Review → Accept all changes.
  • Start without extensions: cursor --disable-extensions
  • Temporarily disable Auto Save and Format On Save, then see if it reproduces.

To help us capture your case precisely, please share:

  • A couple of example file paths and a git diff screenshot
  • Whether these are files previously edited by the Agent
  • git status before launch and right after opening the project
  • Logs: View > Output > Git and Log (File Watcher), and Help > Toggle Developer Tools > Console

I’ll link your thread to the current issue. Thanks, and let me know if any workaround helps.

1 Like

Seems to be the same set of files each time. All files were edited by the agent.

Before opening:
nothing to commit, working tree clean

After opening, I see 7 files. They all seem to be system line break related:

image

This topic was automatically closed 22 days after the last reply. New replies are no longer allowed.