Skip to content

[Adapter] Cursor #34

@shreyas-lyzr

Description

@shreyas-lyzr

Summary

Add a full adapter for Cursor, enabling export, run, and enhanced import support.

Details

Cursor is a widely-used AI-powered code editor. It uses:

  • .cursor/rules/ directory with .mdc files (markdown with YAML frontmatter) for project rules
  • .cursorrules (legacy, single file) for global project instructions
  • Rule files support globs, alwaysApply, description, and content fields
  • Rules can be scoped to specific file patterns (e.g., *.ts, src/api/**)

gitagent already has a basic cursor import (reads .cursorrules), but a full adapter would add:

  • Export: Convert a gitagent agent to Cursor's .cursor/rules/*.mdc format, mapping skills to scoped rules
  • Run: Not applicable (Cursor is an IDE, not a CLI runner) — skip or document as N/A
  • Enhanced import: Read .cursor/rules/*.mdc files (not just legacy .cursorrules), map scoped rules to skills

Acceptance Criteria

  • gitagent export --format cursor generates valid .cursor/rules/*.mdc files with frontmatter
  • Skills with file globs map to scoped Cursor rules
  • SOUL.md + RULES.md map to alwaysApply: true rules
  • Enhanced import reads .cursor/rules/*.mdc directory (not just .cursorrules)
  • Documentation added to README adapter table
  • Mapping document: what gitagent fields map, what gets dropped

Resources

  • Cursor rules docs
  • Existing import in src/commands/import.ts (importFromCursor) for reference
  • Existing adapters in src/adapters/ for the export pattern

Metadata

Metadata

Assignees

No one assigned

    Labels

    adapterFramework adapterenhancementNew feature or requesthelp wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions