cursor-composer-workflows

Master Cursor Composer for multi-file AI editing, scaffolding, and refactoring. Triggers on "cursor composer", "multi-file edit", "cursor generate files", "composer workflow", "cursor scaffold", "Cmd+I".

25 stars

Best use case

cursor-composer-workflows is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Master Cursor Composer for multi-file AI editing, scaffolding, and refactoring. Triggers on "cursor composer", "multi-file edit", "cursor generate files", "composer workflow", "cursor scaffold", "Cmd+I".

Teams using cursor-composer-workflows should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/cursor-composer-workflows/SKILL.md --create-dirs "https://raw.githubusercontent.com/ComeOnOliver/skillshub/main/skills/jeremylongshore/claude-code-plugins-plus-skills/cursor-composer-workflows/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/cursor-composer-workflows/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How cursor-composer-workflows Compares

Feature / Agentcursor-composer-workflowsStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Master Cursor Composer for multi-file AI editing, scaffolding, and refactoring. Triggers on "cursor composer", "multi-file edit", "cursor generate files", "composer workflow", "cursor scaffold", "Cmd+I".

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# Cursor Composer Workflows

Master Cursor Composer (Cmd+I / Ctrl+I) for multi-file code generation, scaffolding, and coordinated refactoring. Composer is the primary tool for changes that span multiple files.

## Composer Interface

```
┌─────────────────────────────────────────────────────────┐
│  Composer                                    [Model ▾]  │
│─────────────────────────────────────────────────────────│
│  Context: [src/api/] [prisma/schema.prisma]             │
│─────────────────────────────────────────────────────────│
│  Create a CRUD API for products with:                   │
│  - Prisma model with id, name, price, category          │
│  - API routes (GET list, GET by id, POST, PUT, DELETE)  │
│  - Zod validation schemas                               │
│  - Unit tests with vitest                               │
│─────────────────────────────────────────────────────────│
│  ┌─ Changes ──────────────────────────────────────────┐ │
│  │  ✅ prisma/schema.prisma          (+12 lines)      │ │
│  │  ✅ src/api/products/route.ts     (new file)       │ │
│  │  ✅ src/api/products/[id]/route.ts (new file)      │ │
│  │  ✅ src/schemas/product.ts        (new file)       │ │
│  │  ✅ tests/api/products.test.ts    (new file)       │ │
│  └────────────────────────────────────────────────────┘ │
│  [Apply All]  [Review Changes]  [Reject]                │
└─────────────────────────────────────────────────────────┘
```

## Core Workflow Patterns

### 1. Feature Scaffolding

Generate a complete feature across multiple files:

```
@src/api/users/route.ts @prisma/schema.prisma

Create a complete "orders" feature following the same patterns as users:
1. Prisma model: Order (id, userId, items, total, status, createdAt)
2. OrderItem model: (id, orderId, productId, quantity, price)
3. API routes: GET /api/orders, GET /api/orders/[id], POST /api/orders
4. Zod validation schemas matching the Prisma models
5. Service layer with createOrder, getOrders, getOrderById
```

Composer reads the referenced files to replicate the existing pattern.

### 2. Cross-File Refactoring

Rename, restructure, or migrate patterns across the codebase:

```
@src/services/ @src/api/

Refactor all service functions to use a Result type instead of throwing errors.

Current pattern:
  async function getUser(id: string): Promise<User> { throw new NotFoundError(); }

Target pattern:
  async function getUser(id: string): Promise<Result<User, NotFoundError>> { ... }

Update all callers in the API routes to handle the Result type.
```

### 3. Test Generation

Generate tests that match existing test patterns:

```
@tests/api/users.test.ts @src/api/products/route.ts

Generate vitest tests for the products API following the same patterns
as users.test.ts. Cover:
- GET /api/products returns list with pagination
- GET /api/products/[id] returns 404 for missing product
- POST /api/products validates required fields
- POST /api/products returns 201 with created product
Use the same mock setup and assertion patterns.
```

### 4. Migration / Upgrade

Apply systematic changes across many files:

```
@src/components/

Migrate all components from CSS Modules to Tailwind CSS:
- Replace className={styles.container} with className="..."
- Map existing CSS properties to Tailwind utilities
- Remove the .module.css import and file
- Preserve responsive breakpoints and dark mode support
```

## Agent Mode

Composer can operate in Agent mode, which autonomously executes multi-step tasks:

- Reads and searches files without explicit @-mentions
- Runs terminal commands (with your approval)
- Chains multiple tool calls (up to 25 before pausing)
- Makes decisions about which files to modify

Agent mode activates by default in Cursor 2.0. It is best for open-ended tasks where you describe the goal but not every step.

### Parallel Agents

Run up to 8 agents simultaneously, each in its own Composer tab. Useful for:
- Working on unrelated features in parallel
- Exploring different implementation approaches
- Running tests in one agent while coding in another

## Diff Review and Application

Before applying changes, Composer shows a complete diff for each file:

```diff
// prisma/schema.prisma
+ model Order {
+   id        String      @id @default(cuid())
+   userId    String
+   user      User        @relation(fields: [userId], references: [id])
+   items     OrderItem[]
+   total     Int
+   status    OrderStatus @default(PENDING)
+   createdAt DateTime    @default(now())
+ }
+
+ enum OrderStatus {
+   PENDING
+   CONFIRMED
+   SHIPPED
+   DELIVERED
+   CANCELLED
+ }
```

**Review workflow:**
1. Click each file in the Changes panel to see its diff
2. Accept individual files or `Apply All`
3. After applying, run your build/tests before committing
4. If something is wrong, `Cmd+Z` undoes the last applied change

## Composer Prompting Best Practices

### Be Specific About File Structure
```
# BAD
Create a blog feature

# GOOD
Create a blog feature with these files:
- src/api/posts/route.ts (GET list with pagination, POST create)
- src/api/posts/[slug]/route.ts (GET by slug, PUT update, DELETE)
- src/types/post.ts (Post interface, CreatePostInput, UpdatePostInput)
- src/services/post.service.ts (PostService class with Prisma operations)
```

### Reference Existing Patterns
```
# BAD
Add authentication middleware

# GOOD
@src/middleware/rateLimit.ts
Add authentication middleware in src/middleware/auth.ts following
the same middleware pattern: export a function that returns NextResponse,
use the same error response format, add the same type annotations.
```

### Incremental Over Monolithic
Instead of one massive prompt, break into steps:

1. "Create the Prisma models and run prisma generate"
2. "Create the service layer with CRUD operations"
3. "Create the API routes that use the service"
4. "Add validation schemas and wire them into the routes"
5. "Generate tests for the service and routes"

Each step can reference the output of the previous step.

## Enterprise Considerations

- **Code review before apply**: Always review diffs. Composer can hallucinate imports or use wrong patterns.
- **Version control**: Commit before running Composer on existing code. Easy rollback with `git checkout .`
- **Team standards**: Use `.cursor/rules/` to encode patterns so Composer follows team conventions
- **Cost awareness**: Composer uses premium model tokens. Complex multi-file prompts consume significant context.

## Resources

- [Composer Overview](https://docs.cursor.com/composer/overview)
- [Agent Mode](https://docs.cursor.com/agent)
- [Context Management](https://docs.cursor.com/context/@-symbols/overview)

Related Skills

time-series-decomposer

25
from ComeOnOliver/skillshub

Time Series Decomposer - Auto-activating skill for Data Analytics. Triggers on: time series decomposer, time series decomposer Part of the Data Analytics skill category.

building-gitops-workflows

25
from ComeOnOliver/skillshub

This skill enables Claude to construct GitOps workflows using ArgoCD and Flux. It is designed to generate production-ready configurations, implement best practices, and ensure a security-first approach for Kubernetes deployments. Use this skill when the user explicitly requests "GitOps workflow", "ArgoCD", "Flux", or asks for help with setting up a continuous delivery pipeline using GitOps principles. The skill will generate the necessary configuration files and setup code based on the user's specific requirements and infrastructure.

cursor-usage-analytics

25
from ComeOnOliver/skillshub

Track and analyze Cursor usage metrics via admin dashboard: requests, model usage, team productivity, and cost optimization. Triggers on "cursor analytics", "cursor usage", "cursor metrics", "cursor reporting", "cursor dashboard", "cursor ROI".

cursor-upgrade-migration

25
from ComeOnOliver/skillshub

Upgrade Cursor versions, migrate from VS Code, and transfer settings between machines. Triggers on "upgrade cursor", "update cursor", "cursor migration", "cursor new version", "vs code to cursor", "cursor changelog".

cursor-team-setup

25
from ComeOnOliver/skillshub

Set up Cursor for teams: plan selection, member management, shared rules, admin dashboard, and onboarding. Triggers on "cursor team", "cursor organization", "cursor business", "cursor enterprise setup", "cursor admin".

cursor-tab-completion

25
from ComeOnOliver/skillshub

Master Cursor Tab autocomplete, ghost text, and AI code suggestions. Triggers on "cursor completion", "cursor tab", "cursor suggestions", "cursor autocomplete", "cursor ghost text", "cursor copilot".

cursor-sso-integration

25
from ComeOnOliver/skillshub

Configure SAML 2.0 and OIDC SSO for Cursor with Okta, Microsoft Entra ID, and Google Workspace. Triggers on "cursor sso", "cursor saml", "cursor oauth", "enterprise cursor auth", "cursor okta", "cursor entra", "cursor scim".

cursor-rules-config

25
from ComeOnOliver/skillshub

Configure Cursor project rules using .cursor/rules/*.mdc files and legacy .cursorrules. Triggers on "cursorrules", ".cursorrules", "cursor rules", "cursor config", "cursor project settings", ".mdc rules", "project rules".

cursor-reference-architecture

25
from ComeOnOliver/skillshub

Reference architecture for Cursor IDE projects: directory structure, rules organization, indexing strategy, and team configuration patterns. Triggers on "cursor architecture", "cursor project structure", "cursor best practices", "cursor file structure".

cursor-prod-checklist

25
from ComeOnOliver/skillshub

Production readiness checklist for Cursor IDE setup: security, rules, indexing, privacy, and team standards. Triggers on "cursor production", "cursor ready", "cursor checklist", "optimize cursor setup", "cursor onboarding".

cursor-privacy-settings

25
from ComeOnOliver/skillshub

Configure Cursor privacy mode, data handling, telemetry, and sensitive file exclusion. Triggers on "cursor privacy", "cursor data", "cursor security", "privacy mode", "cursor telemetry", "cursor data retention".

cursor-performance-tuning

25
from ComeOnOliver/skillshub

Optimize Cursor IDE performance: reduce memory usage, speed up indexing, tune AI features, and manage extensions for large codebases. Triggers on "cursor performance", "cursor slow", "cursor optimization", "cursor memory", "speed up cursor", "cursor lag".