---
name: CMUX Shared Behavior
slug: cmux-shared-behavior
category: Quality
description: CMUX Shared Behavior enforces a single shared action and mutation path across all entrypoints (shortcuts, command palette, context menu, CLI, settings, debug menu) with consistent optimistic updates and rollback; use it when adding entrypoints or when tests missed a bug.
github: "https://github.com/manaflow-ai/cmux/tree/main/skills/cmux-shared-behavior"
language: Swift
stars: 26034
forks: 2205
install: "npx degit https://github.com/manaflow-ai/cmux/tree/main/skills/cmux-shared-behavior ~/.claude/skills/cmux-shared-behavior"
installs_to: ~/.claude/skills/cmux-shared-behavior
source_path: skills/cmux-shared-behavior/SKILL.md
collection_size: 20
category_size: 1354
collection_url: "https://dirskills.com/collections/manaflow-ai/cmux"
added: 2026-08-14T07:12:10.448Z
last_synced: 2026-08-14T07:12:10.448Z
canonical_url: "https://dirskills.com/skills/cmux-shared-behavior"
---

# CMUX Shared Behavior

CMUX Shared Behavior enforces a single shared action and mutation path across all entrypoints (shortcuts, command palette, context menu, CLI, settings, debug menu) with consistent optimistic updates and rollback; use it when adding entrypoints or when tests missed a bug.

**Install:**

```bash
npx degit https://github.com/manaflow-ai/cmux/tree/main/skills/cmux-shared-behavior ~/.claude/skills/cmux-shared-behavior
```

## README

# cmux Shared Behavior

## Shared entrypoints

When a behavior is exposed through multiple surfaces (keyboard shortcut, command palette, context menu, CLI/socket command, settings UI, debug menu), implement one shared action/model path and verify every entrypoint that should invoke it. Do not patch one surface and leave the others with duplicated logic.

## Optimistic updates

Keep one mutation path. Record pending state with a request id or a previous snapshot, reconcile from the authoritative result, and handle failure with an explicit rollback or error state. Never let each entrypoint maintain its own optimistic copy.

## Missed-bug coverage

When a user says tests missed a bug, add or adjust behavior-level coverage around the exact repro path before claiming the fix is complete.
