Cursor terminal command stuck or waiting forever?
When Cursor agent mode waits on a command, the terminal may be done, blocked on input, or running a server that will never exit. Recover the work before retrying.
Common terminal stuck states.
Command finished, agent still waits
Cursor may not have consumed the terminal completion state. Check for a returned shell prompt and completed output, then inspect the diff. Do not press Enter blindly: it can submit pending input or a command.
Interactive command waits forever
Commands asking for input can block the agent loop. Stop it and rerun with explicit non-interactive flags.
Long-running server command
Dev servers and watchers do not exit. Move them outside the agent turn or use a timeout.
Terminal output is hidden
Trust the shell and repository state over the chat spinner. Verify what reached disk.
Safe recovery path.
Separate command execution from completion detection.
In an April 2026 Cursor support discussion, support identified a shell-integration completion-detection problem: a command could finish while the agent continued waiting. This is evidence for that symptom, not proof that every terminal stall has the same cause.
In a separate terminal, use a harmless command such as git --no-pager diff --stat inside the repository to inspect changed tracked files. Do not repeat a migration, installation, or file-writing command just to test whether the spinner clears. Check untracked files separately with git status --short.
If the shell finished but Cursor did not, preserve the Request ID, Cursor version, exact command, and the Terminal and Shell Integration output logs for support. Redact secrets before sharing. If a terminal-mode setting is available, change only one setting at a time and fully restart Cursor before comparing behavior; the discussion also contains reports where changing modes did not help.
What ShardStitch adds.
ShardStitch packages the command, observed output, changed files, failed terminal state, and next verification step so a fresh Cursor chat can continue without repeating the blocked command.