If .claude/skills/cursor-cli/SKILL.md.disabled exists, stop before reading a fallback.
Project configuration: If the current project contains .claude/skills/cursor-cli/SKILL.md, read and apply it instead of this bundled default. The project copy is the capability source of truth.
Repository context: Read ../setup/references/task-context.md when resolving a task, project commands, named agent roles, or legacy .claude/ resource paths. Use repository evidence and applicable project instructions; a missing local workflow copy does not require setup. Resolve bundled resources from the installed skill, never from the target cwd.
Cursor CLI
Announcement: Begin with: "I'm using the cursor-cli skill for cross-AI validation with Cursor."
Use this wrapper for a one-shot Cursor review or approach validation. Read the
shared lifecycle in ../codex-cli/references/cross-ai-run.md first.
Provider adapter
Check command -v agent, agent --version, and agent --help. Verify the
binary is Cursor Agent and supports --print, --mode ask, and
--output-format json. cursor-agent may be an installation alias; do not
substitute the Cursor editor executable.
When the caller requests a particular model or an independent model family,
inspect agent models and select an exact listed slug. Otherwise omit the
model override. Cursor supports multiple providers; auto and an unreported
default do not establish model-level independence. Record the requested slug
separately from any model identity actually reported by the provider.
Resolve the loaded skill directory and run the adapter from the target
repository root with Python 3.10+:
CURSOR_SKILL_DIR="/absolute/path/to/loaded/cursor-cli"
python3 "$CURSOR_SKILL_DIR/scripts/review.py" \
--prompt-file /tmp/cursor-prompt.md \
--file path/to/file.py \
--timeout 120 \
--output-dir /tmp/cursor-review-unique
Set CURSOR_SKILL_DIR to the directory containing this loaded skill, not a
path relative to the reviewed repository. --file is repeatable and pre-reads
verified UTF-8 files into the prompt. The combined input limit is 96 KiB;
narrow larger reviews explicitly. Add --model '<exact listed slug>' only
when selected. Each invocation requires a fresh output directory.
Inspect receipt.json, stdout.json, stderr.log, version.stderr.log, and
response.txt on success. A completed JSON result requires exit 0,
type: result, subtype: success, is_error: false, and a non-empty string
result. An error envelope, timeout, malformed output, trust rejection, or
empty answer is incomplete. Also read the answer for blocked reads, omitted
scope, or other visible limitations: a valid envelope alone does not prove
the review was completed. Return the shared receipt and evidence gaps.
The adapter always uses agent -p --mode ask --output-format json. Print mode
alone can use write and shell tools; keep the explicit read-only mode. Workspace
trust is a separate prerequisite: the adapter preserves a trust rejection and
stops. It does not pass --trust, force/yolo, automatic MCP approval, or sandbox
bypass flags, retry, authenticate, update the CLI, or modify settings. Resolve
missing capabilities or trust through a separate user-authorized action.
Prompt requirements
Include the repository root, task/requirements path when task-attached, changed
files or diff scope, and concrete questions. Cursor starts without this
conversation's context. Resolve task evidence through
../setup/references/task-context.md; standalone calls do not create a task.
When not to use
- The caller did not explicitly choose Cursor
- The request needs interactive refinement
- The primary review workflow already answers the request
References
../codex-cli/references/cross-ai-run.md — shared lifecycle
reference.md — native output contract, trust boundary, and official sources
templates.md — prompt shapes; resolve placeholders before execution
1---2name: cursor-cli-43description: Run Cursor CLI for one-shot cross-AI code review when a Cursor perspective is explicitly wanted. Invoke ONLY4 when the user asks ('cursor review', 'ask cursor', 'run cursor'), or another skill explicitly delegates to Cursor. Do not5 invoke it implicitly for a generic review. Not for interactive conversations.6allowed-tools: Bash Read7compatibility: Portable clients may not enforce Claude Code invocation guards or project setup behavior.8metadata:9 source: https://skillmd.com/skills/alexandrbasis/cursor-cli-410---1112<!-- claudops-build: project-config-pointer -->13> If `.claude/skills/cursor-cli/SKILL.md.disabled` exists, stop before reading a fallback.14> **Project configuration:** If the current project contains `.claude/skills/cursor-cli/SKILL.md`, read and apply it instead of this bundled default. The project copy is the capability source of truth.15> **Repository context:** Read `../setup/references/task-context.md` when resolving a task, project commands, named agent roles, or legacy `.claude/` resource paths. Use repository evidence and applicable project instructions; a missing local workflow copy does not require setup. Resolve bundled resources from the installed skill, never from the target cwd.1617# Cursor CLI1819> **Announcement**: Begin with: "I'm using the **cursor-cli** skill for cross-AI validation with Cursor."2021Use this wrapper for a one-shot Cursor review or approach validation. Read the22shared lifecycle in `../codex-cli/references/cross-ai-run.md` first.2324## Provider adapter25261. Check `command -v agent`, `agent --version`, and `agent --help`. Verify the27 binary is Cursor Agent and supports `--print`, `--mode ask`, and28 `--output-format json`. `cursor-agent` may be an installation alias; do not29 substitute the Cursor editor executable.302. When the caller requests a particular model or an independent model family,31 inspect `agent models` and select an exact listed slug. Otherwise omit the32 model override. Cursor supports multiple providers; `auto` and an unreported33 default do not establish model-level independence. Record the requested slug34 separately from any model identity actually reported by the provider.353. Resolve the loaded skill directory and run the adapter from the target36 repository root with Python 3.10+:3738 ```bash39 CURSOR_SKILL_DIR="/absolute/path/to/loaded/cursor-cli"40 python3 "$CURSOR_SKILL_DIR/scripts/review.py" \41 --prompt-file /tmp/cursor-prompt.md \42 --file path/to/file.py \43 --timeout 120 \44 --output-dir /tmp/cursor-review-unique45 ```4647 Set `CURSOR_SKILL_DIR` to the directory containing this loaded skill, not a48 path relative to the reviewed repository. `--file` is repeatable and pre-reads49 verified UTF-8 files into the prompt. The combined input limit is 96 KiB;50 narrow larger reviews explicitly. Add `--model '<exact listed slug>'` only51 when selected. Each invocation requires a fresh output directory.524. Inspect `receipt.json`, `stdout.json`, `stderr.log`, `version.stderr.log`, and53 `response.txt` on success. A completed JSON result requires exit 0,54 `type: result`, `subtype: success`, `is_error: false`, and a non-empty string55 `result`. An error envelope, timeout, malformed output, trust rejection, or56 empty answer is incomplete. Also read the answer for blocked reads, omitted57 scope, or other visible limitations: a valid envelope alone does not prove58 the review was completed. Return the shared receipt and evidence gaps.5960The adapter always uses `agent -p --mode ask --output-format json`. Print mode61alone can use write and shell tools; keep the explicit read-only mode. Workspace62trust is a separate prerequisite: the adapter preserves a trust rejection and63stops. It does not pass `--trust`, force/yolo, automatic MCP approval, or sandbox64bypass flags, retry, authenticate, update the CLI, or modify settings. Resolve65missing capabilities or trust through a separate user-authorized action.6667## Prompt requirements6869Include the repository root, task/requirements path when task-attached, changed70files or diff scope, and concrete questions. Cursor starts without this71conversation's context. Resolve task evidence through72`../setup/references/task-context.md`; standalone calls do not create a task.7374## When not to use7576- The caller did not explicitly choose Cursor77- The request needs interactive refinement78- The primary review workflow already answers the request7980## References8182- `../codex-cli/references/cross-ai-run.md` — shared lifecycle83- `reference.md` — native output contract, trust boundary, and official sources84- `templates.md` — prompt shapes; resolve placeholders before execution