Introduction
Cursor's Agent can run terminal commands: install packages, run tests, start servers, run migrations, call git. Users can let it run commands automatically or require approval for each one, and can maintain allow-lists and deny-lists of commands. The default matters enormously. Auto-run makes agents faster and lets them fix their own errors without waiting. Approval prompts protect against destructive or unsafe commands, such as deleting files, pushing to production, or running a script pulled in through a prompt injection hidden in a README or web page.
The question: should Agent auto-run terminal commands by default, or ask first?
I'll treat this as a speed-versus-safety trade-off, understand where risk actually sits, form a hypothesis, define metrics, run an experiment and set a clear decision rule.
Step 1
Clarifying Questions (3 minutes)
Practice similar questions
Subscribe to access the full answer