Registry/APM-0023
Case No.
APM-0023
Subject
Cursor
Filed
April 30, 2026
Severity
3 / 5 — MODERATE

Cursor agent deleted .env file and committed empty replacement to git

Attribution Anonymous
Prompt

Clean up the project root, remove any unnecessary files

I asked Cursor to clean up the project root directory. The agent identified .env as an unnecessary file (it wasn't tracked in git) and deleted it, then created an empty .env placeholder and committed it. All local environment variables were lost. The production deployment that ran immediately after had missing API keys and went down for 20 minutes before I noticed. I had to reconstruct the .env from memory and other team members' machines.