cursor-do

Delegate a single write task to Cursor Composer in an isolated git worktree, then review and cherry-pick the diff.

3.1k|302|Updated Dec 12, 2025
One-click install
npx skills add https://github.com/Chachamaru127/claude-code-harness --skill cursor-do
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cursor-do
Source: https://github.com/Chachamaru127/claude-code-harness/tree/main/codex/.codex/skills/cursor-do
Command: npx skills add https://github.com/Chachamaru127/claude-code-harness --skill cursor-do

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Delegating code changes to Cursor Composer is risky because cursor-agent has no real sandbox: file writes are not confined to the workspace and its allowlists are bypassable. This Skill wraps the delegation in a containment pipeline so untrusted Cursor output never reaches your main branch unreviewed.

Core Features & Use Cases

  • Isolated execution: Creates a dedicated git worktree (.claude/worktrees/cursor-do-<id>) and runs cursor-companion.sh task --write inside it, keeping the main tree untouched.
  • Lead diff review gate: Auto-commits Composer's dirty changeset, then requires a full diff review plus contract-grep checks (support-claim wording, consistency, plugin validation) before anything merges.
  • Safe merge path: Cherry-picks exactly one commit by SHA into the base branch, updates the cc:done [<sha>] marker in Plans.md, and cleans up the worktree.
  • Use Case: Ask the agent to "delegate the login form validation refactor to Cursor" — it spins up a worktree, has Composer implement the change, reviews the diff for scope creep or secrets, cherry-picks the result, and marks the task done in Plans.md.

Quick Start

Ask the agent to delegate a single implementation task to Cursor Composer, for example: use cursor:do to add login form validation to the auth module.

Frequently Asked Questions about cursor-do

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I delegate a code change to Cursor Composer safely?

Invoke cursor:do with a one-line task description. The skill creates an isolated git worktree, runs cursor-companion.sh with --write inside it, reviews the resulting diff, and cherry-picks exactly one commit into your base branch.

What is the difference between cursor:do and cursor:ask?

cursor:ask is read-only delegation using --mode ask, needing no worktree or diff review. cursor:do handles write tasks and requires full containment: dedicated worktree, Lead diff review, and cherry-pick.

Does cursor-agent sandbox confine file writes?

No. Cursor's --sandbox flag confines shell commands but not file edits, and its allowlists are best-effort, not security boundaries. The only effective containment is a dedicated git worktree plus Lead diff review plus cherry-pick.

Why does cursor:do fail with cursor-agent not found?

The skill resolves the cursor-agent binary by checking agent and cursor-agent on PATH, verifying the resolved path contains cursor-agent, then falling back to ~/.local/bin/cursor-agent. If none exist, install it via setup-cursor.sh.

What happens if Cursor Composer returns multiple commits?

The skill enforces an exactly-one-commit contract. If Composer leaves a dirty changeset it is auto-committed or amended; if multiple commits remain, the cherry-pick aborts and the worktree is kept for manual review.

When should I use breezing --cursor instead of cursor:do?

Use breezing --cursor for multi-task parallel team runs with the Cursor backend. cursor:do is the shortest path for a single task with one cherry-pick, without starting the team flow.