Skip to content

feat(types): add Cursor (cursor-agent CLI) support (#131)#189

Merged
fujibee merged 2 commits into
mainfrom
feat/cursor-type
Jun 22, 2026
Merged

feat(types): add Cursor (cursor-agent CLI) support (#131)#189
fujibee merged 2 commits into
mainfrom
feat/cursor-type

Conversation

@fujibee

@fujibee fujibee commented Jun 22, 2026

Copy link
Copy Markdown
Owner

Summary

Adds Cursor (cursor-agent CLI, Composer 2.5) as a first-class agmsg agent type, as requested in #131. With the #181 manifest-driven type registry now on main, this is a pure plugin — a single scripts/drivers/types/cursor/ directory, no core code changes.

How Cursor integrates

Cursor's local CLI auto-loads project rules from .cursor/rules/*.mdc. An .mdc with alwaysApply: true is applied every turn — the always-on instruction channel agmsg needs, the cursor-agent analogue of gemini/opencode's markdown rules file. Maps cleanly to agmsg turn delivery.

  • type.confdelivery_modes=turn off, detect_proc=cursor-agent, hooks_file=.cursor/rules/agmsg.mdc, cli=cursor-agent (metadata).
  • _delivery.sh — writes the .mdc with alwaysApply: true frontmatter + the inbox-check instruction.
  • template.md — the /agmsg command doc, typed for cursor.

Scope

  • Local cursor-agent only (Cloud agents don't fire lifecycle hooks), per the issue.
  • Not spawnable yetspawn.sh launch of cursor-agent is left as a follow-up; this PR is about joining the mesh and turn-mode delivery.
  • The cursor-agent rules/hooks systems are beta, so the schema may shift.

Tests

Mirrors the opencode delivery suite (accept turn / off removes / reject monitor+both / idempotent) plus an assertion that the rule file is an always-apply .mdc. Updated the type-registry built-ins test (7 → 8). Full suite green except two pre-existing test_watch.bats timing flakes (unrelated — this PR touches no watcher code).

@kurochan001 offered to verify on a real Cursor install — would be very welcome once this is in.

Closes #131.

fujibee added 2 commits June 21, 2026 22:21
Cursor's CLI agent (cursor-agent, Composer 2.5) joins the agmsg mesh as a
turn-mode type. Thanks to the #181 manifest-driven type registry, this is a
pure plugin: a new scripts/drivers/types/cursor/ directory, no core changes.

- type.conf: turn/off delivery, detect_proc=cursor-agent, hooks_file points at
  .cursor/rules/agmsg.mdc, cli=cursor-agent (metadata; not spawnable yet).
- _delivery.sh: writes an always-apply .mdc rule (`alwaysApply: true`
  frontmatter) so the Cursor CLI auto-loads the inbox-check instruction every
  turn — the cursor-agent analogue of gemini/opencode's rules file.
- template.md: the /agmsg command doc, typed for cursor.
- Tests mirror the opencode delivery suite plus an .mdc-frontmatter assertion;
  type-registry known-types updated (seven → eight built-ins).
- Docs: agent-types.md and install.sh --agent-type help list cursor.

Local (cursor-agent hooks are beta); the reporter offered to verify on a real
Cursor install. Requested by @kurochan001.
…is honored

The two TPL_TYPE case arms in install.sh listed gemini|antigravity|opencode|hermes
but not cursor, so --agent-type cursor fell through to the codex template and
shipped a codex-typed SKILL.md — the documented Cursor install path would then
join/deliver as codex, defeating #131. Add cursor to both arms and a regression
test. (co1 review on #189.)
@fujibee fujibee merged commit 3fc66b0 into main Jun 22, 2026
5 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Cursor (cursor-agent CLI) support

1 participant