Ghostty-based macOS terminal with vertical tabs and notifications for AI coding agents https://cmux.com
Find a file
Lawrence Chen 463c6baabb
Fix CJK IME input (Korean, Chinese, Japanese) (#125)
* Fix CJK IME input not working (#118)

CJK (Korean, Japanese, Chinese) IME input was completely broken because
cmux never forwarded preedit/composition state to Ghostty's libghostty.

Root causes and fixes:

1. Missing preedit sync: Added syncPreedit() that calls
   ghostty_surface_preedit() to notify Ghostty about IME composition
   text. Called from setMarkedText, unmarkText, and after
   interpretKeyEvents in keyDown.

2. Wrong composing flag: The composing flag on key events now correctly
   accounts for when composition just ended (markedTextBefore was true
   but markedText is now empty), preventing spurious deletions when
   canceling composition.

3. Event interception during IME: Added early exits in
   performKeyEquivalent, the NSWindow swizzle, and the local event
   monitor (handleCustomShortcut) to avoid stealing key events while
   IME has active marked text.

4. IME popup positioning: firstRect(forCharacterRange:) now uses
   ghostty_surface_ime_point() for accurate cursor-relative positioning
   of the IME candidate window.

* Add regression tests for CJK IME composition (#118)

31 tests covering Korean, Japanese, and Chinese IME input scenarios:

- Korean jamo combining: ㅎ -> 하 -> 한 composition lifecycle
- Chinese pinyin: multi-letter marked text and candidate selection
- Japanese hiragana-to-kanji: romaji -> hiragana -> kanji conversion
- insertText correctly commits composed text and clears marked state
- unmarkText properly clears composition state (idempotent)
- performKeyEquivalent returns false during active composition for
  all key types (plain, shift, space, return, escape)
- Shortcut bypass: hasMarkedText gates the handleCustomShortcut bypass
- Multi-syllable sequences, backspace correction, and rapid transitions
- keyTextAccumulator lifecycle tests

Also adds #if DEBUG test accessors for keyTextAccumulator on
GhosttyNSView to enable unit testing the accumulator path.
2026-02-19 22:37:41 -08:00
.claude/commands Fix homebrew SHA mismatch race condition (#111) 2026-02-19 17:44:00 -08:00
.github/workflows Fix homebrew SHA mismatch race condition (#111) 2026-02-19 17:44:00 -08:00
Assets.xcassets Add dev build branding and reload scripts 2026-01-28 01:20:48 -08:00
CLI Fix --help/-h on subcommands being silently ignored (#119) (#128) 2026-02-19 22:29:28 -08:00
cmuxTests Fix CJK IME input (Korean, Chinese, Japanese) (#125) 2026-02-19 22:37:41 -08:00
cmuxUITests Fix split-close stale-frame stretch and add regression coverage 2026-02-19 04:15:50 -08:00
docs Add features table with images to README (#63) 2026-02-18 01:24:54 -08:00
ghostty@80d3fa07ff Fix split-close stale-frame stretch and add regression coverage 2026-02-19 04:15:50 -08:00
GhosttyTabs.xcodeproj Fix CJK IME input (Korean, Chinese, Japanese) (#125) 2026-02-19 22:37:41 -08:00
homebrew-cmux@dcfaa081e5 Update homebrew-cmux submodule to latest 2026-02-19 21:36:15 -08:00
node_modules Update app and tooling 2026-01-29 17:36:26 -08:00
Resources Move port scanning from shell to app-side with batching (#100) 2026-02-19 01:04:47 -08:00
scripts Fix homebrew SHA mismatch race condition (#111) 2026-02-19 17:44:00 -08:00
skills Add sidebar metadata (git branch, ports, logs, progress), fix localhost URL resolution, simplify analytics 2026-02-16 02:46:39 -08:00
Sources Fix CJK IME input (Korean, Chinese, Japanese) (#125) 2026-02-19 22:37:41 -08:00
tests Fix homebrew SHA mismatch race condition (#111) 2026-02-19 17:44:00 -08:00
tests_v2 Fix split blackout race and stabilize focus handoff 2026-02-19 17:10:27 -08:00
vendor Fix panel resize hitbox and stale portal frame behavior (#114) 2026-02-19 18:32:57 -08:00
web Remove docs-site, add PostHog analytics to web (#66) 2026-02-18 04:00:04 -08:00
.gitignore Add /release-local skill and direnv setup 2026-02-17 21:33:11 -08:00
.gitmodules Fix frozen terminals after split churn (#12) 2026-02-13 16:45:31 -08:00
.vercelignore Add Vercel ignore 2026-01-29 17:50:35 -08:00
AGENTS.md agents 2026-01-22 03:18:02 -08:00
bun.lock Update app and tooling 2026-01-29 17:36:26 -08:00
CHANGELOG.md Bump version to 0.59.0 2026-02-19 21:29:27 -08:00
CLAUDE.md Rename test targets to cmuxTests and cmuxUITests 2026-02-18 21:19:56 -08:00
cmux-Bridging-Header.h Rename to cmux and add About panel 2026-01-26 03:05:03 -08:00
cmux.entitlements Bump version to 0.48.0 (#80) 2026-02-18 17:56:22 -08:00
CONTRIBUTING.md Rename test targets to cmuxTests and cmuxUITests 2026-02-18 21:19:56 -08:00
ghostty.h Initial commit: macOS terminal app with vertical tabs using libghostty 2026-01-22 01:16:24 -08:00
LICENSE Add nightly update channel workflow and adopt AGPL licensing 2026-02-14 02:43:03 -08:00
package.json Add nightly update channel workflow and adopt AGPL licensing 2026-02-14 02:43:03 -08:00
Package.resolved Initial commit: macOS terminal app with vertical tabs using libghostty 2026-01-22 01:16:24 -08:00
Package.swift Rename to cmux and add About panel 2026-01-26 03:05:03 -08:00
PROJECTS.md Reversion all 1.x.x to 0.x.x for pre-launch versioning 2026-02-17 18:31:05 -08:00
README.ar.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.bs.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.da.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.de.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.es.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.fr.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.it.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.ja.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.ko.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.md Add features table with images to README (#64) 2026-02-18 01:31:21 -08:00
README.no.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.pl.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.pt-BR.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.ru.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.th.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.tr.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.zh-CN.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
README.zh-TW.md update keyboard shortcuts in README and translations 2026-02-15 21:49:54 -08:00
THIRD_PARTY_LICENSES.md add third-party licenses and update bonsplit submodule 2026-02-14 20:33:40 -08:00
TODO.md todos 2026-02-19 18:36:53 -08:00

cmux

A Ghostty-based macOS terminal with vertical tabs and notifications for AI coding agents

Download cmux for macOS

English | 简体中文 | 繁體中文 | 한국어 | Deutsch | Español | Français | Italiano | Dansk | 日本語 | Polski | Русский | Bosanski | العربية | Norsk | Português (Brasil) | ไทย | Türkçe

cmux screenshot

Features

Notification rings

Panes get a blue ring and tabs light up when AI agents need your attention
Notification rings

Notification panel

See all pending notifications in one place, jump to the most recent unread
Sidebar notification badge

In-app browser

Split a browser alongside your terminal with a scriptable API ported from agent-browser
Built-in browser

Vertical + horizontal tabs

Sidebar shows git branch, working directory, listening ports, and latest notification text. Split horizontally and vertically.
Vertical tabs and split panes
  • Scriptable — CLI and socket API to create workspaces, split panes, send keystrokes, and automate the browser
  • Native macOS app — Built with Swift and AppKit, not Electron. Fast startup, low memory.
  • Ghostty compatible — Reads your existing ~/.config/ghostty/config for themes, fonts, and colors
  • GPU-accelerated — Powered by libghostty for smooth rendering

Install

Download cmux for macOS

Open the .dmg and drag cmux to your Applications folder. cmux auto-updates via Sparkle, so you only need to download once.

Homebrew

brew tap manaflow-ai/cmux
brew install --cask cmux

To update later:

brew upgrade --cask cmux

On first launch, macOS may ask you to confirm opening an app from an identified developer. Click Open to proceed.

Why cmux?

I run a lot of Claude Code and Codex sessions in parallel. I was using Ghostty with a bunch of split panes, and relying on native macOS notifications to know when an agent needed me. But Claude Code's notification body is always just "Claude is waiting for your input" with no context, and with enough tabs open I couldn't even read the titles anymore.

I tried a few coding orchestrators but most of them were Electron/Tauri apps and the performance bugged me. I also just prefer the terminal since GUI orchestrators lock you into their workflow. So I built cmux as a native macOS app in Swift/AppKit. It uses libghostty for terminal rendering and reads your existing Ghostty config for themes, fonts, and colors.

The main additions are the sidebar and notification system. The sidebar has vertical tabs that show git branch, working directory, listening ports, and the latest notification text for each workspace. The notification system picks up terminal sequences (OSC 9/99/777) and has a CLI (cmux notify) you can wire into agent hooks for Claude Code, OpenCode, etc. When an agent is waiting, its pane gets a blue ring and the tab lights up in the sidebar, so I can tell which one needs me across splits and tabs. Cmd+Shift+U jumps to the most recent unread.

The in-app browser has a scriptable API ported from agent-browser. Agents can snapshot the accessibility tree, get element refs, click, fill forms, and evaluate JS. You can split a browser pane next to your terminal and have Claude Code interact with your dev server directly.

Everything is scriptable through the CLI and socket API — create workspaces/tabs, split panes, send keystrokes, open URLs in the browser.

Keyboard Shortcuts

Workspaces

Shortcut Action
⌘ N New workspace
⌘ 18 Jump to workspace 18
⌘ 9 Jump to last workspace
⌃ ⌘ ] Next workspace
⌃ ⌘ [ Previous workspace
⌘ ⇧ W Close workspace
⌘ B Toggle sidebar

Surfaces

Shortcut Action
⌘ T New surface
⌘ ⇧ ] Next surface
⌘ ⇧ [ Previous surface
⌃ Tab Next surface
⌃ ⇧ Tab Previous surface
⌃ 18 Jump to surface 18
⌃ 9 Jump to last surface
⌘ W Close surface

Split Panes

Shortcut Action
⌘ D Split right
⌘ ⇧ D Split down
⌥ ⌘ ← → ↑ ↓ Focus pane directionally
⌘ ⇧ H Flash focused panel

Browser

Shortcut Action
⌘ ⇧ L Open browser in split
⌘ L Focus address bar
⌘ [ Back
⌘ ] Forward
⌘ R Reload page
⌥ ⌘ I Open Developer Tools

Notifications

Shortcut Action
⌘ I Show notifications panel
⌘ ⇧ U Jump to latest unread

Find

Shortcut Action
⌘ F Find
⌘ G / ⌘ ⇧ G Find next / previous
⌘ ⇧ F Hide find bar
⌘ E Use selection for find

Terminal

Shortcut Action
⌘ K Clear scrollback
⌘ C Copy (with selection)
⌘ V Paste
⌘ + / ⌘ - Increase / decrease font size
⌘ 0 Reset font size

Window

Shortcut Action
⌘ ⇧ N New window
⌘ , Settings
⌘ ⇧ , Reload configuration
⌘ Q Quit

License

This project is licensed under the GNU Affero General Public License v3.0 or later (AGPL-3.0-or-later).

See LICENSE for the full text.