Where does the bug appear (feature/product)?
Cursor CLI
Describe the Bug
running cursor agent -p --trust --plan creates and modifies files instead of just outputting a plan. in headless mode with -p (print), the agent executes the plan and writes to disk even with --plan set.
this matters for anyone using plan mode in CI/CD pipelines or automation scripts expecting dry-run behavior.
Steps to Reproduce
- create a directory with a
.cursor/rules/.mdc rule (alwaysApply: true) - run:
cursor agent -p --trust --plan "Create a simple hello.js file with a hello world function" - check the directory after execution
hello.jsexists on disk (102 bytes), even though--planshould only produce a plan
Expected Behavior
--plan should output the plan without executing it. no files should be created or modified.
Operating System
Linux
Version Information
CLI Version 2026.02.13-41ac335
Does this stop you from using Cursor
No - Cursor works, but with this issue