Pipe a diff or logs into the agent

print mode & automation

// what it does

Piping into cursor-agent feeds the piped text to the agent as context and auto-enables print mode (stdin is not a TTY). This is the fast path for one-off reviews and summaries without adding files to a session. Combine with --output-format to make the result machine-readable.

// shell

$ git diff | cursor-agent -p "summarize these changes"
$ tail -200 app.log | cursor-agent -p "identify the errors"

// resources