* Fix minimal mode toggle not properly updating titlebar state UpdateTitlebarAccessoryController only re-evaluated titlebar accessories on window focus events (didBecomeKey/didBecomeMain), not when the presentation mode actually changed. This caused: 1. Switching to minimal: accessories weren't immediately removed 2. Switching back to standard: accessories were never re-attached (removeAccessoryIfPresent cleared attachedWindows, but no event triggered re-attachment) 3. Repeated toggling left the window in inconsistent states Add a UserDefaults observer that detects presentation mode changes and re-evaluates all windows. When switching to minimal, accessories are removed; when switching to standard, fresh accessories are created and attached. Also handle the fullscreen edge case where re-attached accessories must be hidden to avoid doubling with SwiftUI overlay controls. * Hide window toolbar in minimal mode to eliminate titlebar gap The NSToolbar (attached by WindowToolbarController) creates a non-zero titlebar area even in minimal mode, leaving an empty gap above the Bonsplit tab bar. In minimal mode there's no need for the toolbar (it shows a "Cmd:" text that's hidden anyway with titleVisibility=.hidden). Hide the toolbar when switching to minimal mode and restore it when switching back to standard. Also set initial visibility on attachment based on the current mode. * Apply ignoresSafeArea to contentAndSidebarLayout in minimal mode The titlebar gap persisted because intermediate SwiftUI views still respected the window's safe area even though MainWindowHostingView zeroes safeAreaInsets. Apply .ignoresSafeArea(.container, edges: .top) directly to the contentAndSidebarLayout when in minimal mode so the entire content (sidebar + terminal) extends into the titlebar area. * Remove toolbar entirely in minimal mode instead of just hiding toolbar.isVisible=false still reserves titlebar space. Remove the toolbar entirely (window.toolbar=nil) when switching to minimal mode and re-attach it when switching back to standard. Skip toolbar attachment entirely when launching in minimal mode. * Add BonsplitTabDragUITests.swift to cmuxUITests target The test file existed on disk but was missing from the Xcode project, causing all BonsplitTabDrag UI tests (including minimal mode tests) to silently report 0 tests on CI. * Use negative titlebar padding in minimal mode to extend content into titlebar The native titlebar area (28.5pt for traffic lights) persists even without a toolbar and despite .ignoresSafeArea() modifiers. Use negative padding (-titlebarPadding) in minimal mode to pull the terminal content up into the titlebar area. The sidebar's internal trafficLightPadding spacer keeps sidebar content properly offset below the traffic lights. * Add window drag handle to Bonsplit top strip in minimal mode In minimal mode, the custom titlebar (which provides the window drag handle) is hidden. Add a WindowDragHandleView to the top strip overlay so users can drag-to-move the window from the Bonsplit tab bar area. The TitlebarDoubleClickMonitorView is kept as a background for double-click-to-zoom. * Use native titlebar drag in minimal mode instead of WindowDragHandleView WindowDragHandleView defers to interactive siblings (Bonsplit tab bar), so it never captures hits. Instead, set window.isMovable=true in minimal mode so the native titlebar area handles drag-to-move and double-click-to-zoom. Remove the non-functional overlay from WorkspaceContentView. * Enable isMovableByWindowBackground in minimal mode for window dragging window.isMovable alone doesn't work because the Bonsplit tab bar captures all hits before the native titlebar drag engages. Use isMovableByWindowBackground=true so any area that doesn't handle mouse events becomes a drag handle. Also capture workspacePresentationMode in the WindowAccessor closure so the window properties update when toggling modes. * Add debug logging for minimal mode window drag diagnosis * Intercept double-click in minimal mode tab bar to zoom instead of new tab Bonsplit's EmptyTabBarDoubleClickMonitorView creates a new tab on double-click in the tab bar empty space. In minimal mode, intercept these double-clicks with a higher-priority local event monitor and perform the standard macOS titlebar action (zoom/minimize based on System Settings) instead. Only intercepts in the top 30pt strip and only when minimal mode is active. * Fix double-click monitor ordering and coordinate calculation NSEvent local monitors are called LIFO (last installed first). Install the minimal-mode double-click interceptor with a 0.5s delay so it's added after Bonsplit's EmptyTabBarDoubleClickMonitorView monitors, ensuring it runs first and can consume the event. Also fix the distance-from-top calculation to use window frame height instead of contentLayoutRect height, since the tab bar is in the titlebar area. * Remove unnecessary delay from double-click monitor installation * Show split buttons on hover only in minimal mode, fix sidebar controls re-attachment Two fixes: 1. Add splitButtonsOnHover to BonsplitConfiguration.Appearance. In minimal mode, the Bonsplit split buttons (terminal, browser, split right/down) fade in only when hovering the tab bar. Revert to always-visible when switching back to standard mode. 2. Delay titlebar accessory re-attachment when switching to standard mode so the toolbar is re-added first. Without this, the accessory attaches before the toolbar exists, causing the sidebar controls to not appear in the titlebar. * Fix splitButtonsOnHover via onChange instead of body eval, add debug logs * Update bonsplit submodule for splitButtonsOnHover * Remove debug logs, verified splitButtonsOnHover and accessory re-attachment on macmini * Read presentationMode directly in TabBarView via @AppStorage The @Observable configuration propagation wasn't reliably triggering re-renders in TabBarView. Read the workspacePresentationMode directly via @AppStorage in TabBarView instead, which SwiftUI reactively updates when UserDefaults changes. Remove the syncSplitButtonsOnHover workaround from WorkspaceContentView. * Fix tab drag, double-click zone, and sidebar controls re-attachment - Revert isMovableByWindowBackground to false; it breaks Bonsplit tab reordering. Keep isMovable=true in minimal mode so the sidebar area (which has WindowDragHandleView) is draggable. - Increase double-click intercept zone from 30pt to 40pt to cover the full tab bar height (33pt). - Use asyncAfter(0.1s) for titlebar accessory re-attachment when switching to standard mode, giving the toolbar time to re-attach. * Add debug logging for titlebar accessory re-attachment diagnosis * Fix crash and sidebar controls re-attachment Remove debug logging that crashed when accessing window properties during iteration. Increase deferred re-attachment delay to 0.3s to give the WindowAccessor callback time to set the window identifier and toolbar before attachIfNeeded checks isMainTerminalWindow. * Keep titlebar accessories attached in minimal mode instead of removing The remove/re-add cycle was fragile: re-attachment depended on window identifiers being set, toolbar being re-added, and timing delays. Instead, keep TitlebarControlsAccessoryViewController always attached and let its own UserDefaults observer handle visibility. It already hides itself (view.isHidden=true, preferredContentSize=.zero) in minimal mode and shows itself in standard mode. No timing hacks needed. * Force titlebar accessory layout after toolbar re-addition * Use both self.isHidden and view.alphaValue/isHidden for accessory visibility self.isHidden alone doesn't reliably hide the accessory when the toolbar is nil on macOS 26. Add view.alphaValue=0 and view.isHidden as visual fallbacks. Crucially, don't zero preferredContentSize or frames so fittingSize returns valid values when switching back. * Set window.isMovable=false always to fix sidebar button clicks window.isMovable=true in minimal mode blocks clicks on the sidebar controls because the native titlebar drag intercepts mouse events in the overlapping area. The sidebar's WindowDragHandleView already handles drag-to-move via performDrag with withTemporaryWindowMovableEnabled, so native isMovable isn't needed. * Add drag-to-move from empty bonsplit tab bar space in minimal mode * Use overlay for tab bar drag, smart hitTest passes through tabs/buttons * Add double-click zoom/minimize to tab bar drag view * Add leading padding for traffic lights when sidebar collapsed in minimal mode * Add traffic light inset to tab bar when sidebar collapsed in minimal mode * Fix accessory space and double-click in minimal mode - Zero preferredContentSize in minimal mode (so accessory takes no space) but seed hostingView with cached size before querying fittingSize when switching back (so size can be restored). - Skip EmptyTabBarDoubleClickMonitorView in minimal mode so DraggableTabBarView handles double-click for zoom instead. - Remove redundant ContentView double-click monitor. * Auto-detect traffic light inset in TabBarView via GeometryReader Instead of propagating sidebar state through config, the tab bar detects its own position relative to the window. If in minimal mode and the tab bar's leading edge is near the window edge (< 20pt, no sidebar), add 72pt spacer for traffic light clearance. * Increase traffic light spacer to 80pt * Fix tab click passthrough in minimal mode drag overlay * Check full window for interactive hits in drag overlay * Fix drag overlay capturing all clicks via reentrancy guard in hitTest * Distinguish interactive controls from hosting views in drag hitTest * Walk ancestor chain for button detection in drag overlay hitTest * Replace overlay with background drag view per ensemble recommendation * Only add traffic light inset for top-left pane * Use GeometryReader for traffic light inset, check screen position * Fix operator precedence in traffic light inset check * Use window frame for traffic light inset detection * Set tabBarLeadingInset from ContentView via onChange handlers Replace unreliable coordinate-based detection with direct state from ContentView, which knows both sidebar visibility and minimal mode. Syncs on appear, sidebar toggle, and mode toggle. * Use allPaneIds.first for top-left pane detection, no hierarchy threading needed * Update bonsplit submodule to merged main --------- Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com> |
||
|---|---|---|
| .claude/commands | ||
| .github | ||
| AppIcon.icon | ||
| Assets.xcassets | ||
| CLI | ||
| cmuxTests | ||
| cmuxUITests | ||
| daemon/remote | ||
| design | ||
| docs | ||
| ghostty@bc9be90a21 | ||
| GhosttyTabs.xcodeproj | ||
| homebrew-cmux@a5f372ecfa | ||
| node_modules | ||
| Resources | ||
| scripts | ||
| skills | ||
| Sources | ||
| tests | ||
| tests_v2 | ||
| vendor | ||
| web | ||
| .gitignore | ||
| .gitkeep | ||
| .gitmodules | ||
| .vercelignore | ||
| AGENTS.md | ||
| bun.lock | ||
| CHANGELOG.md | ||
| CLAUDE.md | ||
| cmux-Bridging-Header.h | ||
| cmux.entitlements | ||
| CONTRIBUTING.md | ||
| ghostty.h | ||
| LICENSE | ||
| package.json | ||
| Package.resolved | ||
| Package.swift | ||
| PROJECTS.md | ||
| README.ar.md | ||
| README.bs.md | ||
| README.da.md | ||
| README.de.md | ||
| README.es.md | ||
| README.fr.md | ||
| README.it.md | ||
| README.ja.md | ||
| README.km.md | ||
| README.ko.md | ||
| README.md | ||
| README.no.md | ||
| README.pl.md | ||
| README.pt-BR.md | ||
| README.ru.md | ||
| README.th.md | ||
| README.tr.md | ||
| README.uk.md | ||
| README.vi.md | ||
| README.zh-CN.md | ||
| README.zh-TW.md | ||
| THIRD_PARTY_LICENSES.md | ||
| TODO.md | ||
cmux
A Ghostty-based macOS terminal with vertical tabs and notifications for AI coding agents
English | 日本語 | Tiếng Việt | 简体中文 | 繁體中文 | 한국어 | Deutsch | Español | Français | Italiano | Dansk | Polski | Русский | Bosanski | العربية | Norsk | Português (Brasil) | ไทย | Türkçe | ភាសាខ្មែរ | Українська
▶ Demo video · The Zen of cmux
Features
Notification ringsPanes get a blue ring and tabs light up when coding agents need your attention |
|
Notification panelSee all pending notifications in one place, jump to the most recent unread |
|
In-app browserSplit a browser alongside your terminal with a scriptable API ported from agent-browser |
|
Vertical + horizontal tabsSidebar shows git branch, linked PR status/number, working directory, listening ports, and latest notification text. Split horizontally and vertically. |
|
- 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/configfor themes, fonts, and colors - GPU-accelerated — Powered by libghostty for smooth rendering
Install
DMG (recommended)
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, linked PR status/number, 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.
The Zen of cmux
cmux is not prescriptive about how developers hold their tools. It's a terminal and browser with a CLI, and the rest is up to you.
cmux is a primitive, not a solution. It gives you a terminal, a browser, notifications, workspaces, splits, tabs, and a CLI to control all of it. cmux doesn't force you into an opinionated way to use coding agents. What you build with the primitives is yours.
The best developers have always built their own tools. Nobody has figured out the best way to work with agents yet, and the teams building closed products definitely haven't either. The developers closest to their own codebases will figure it out first.
Give a million developers composable primitives and they'll collectively find the most efficient workflows faster than any product team could design top-down.
Documentation
For more info on how to configure cmux, head over to our docs.
Keyboard Shortcuts
Workspaces
| Shortcut | Action |
|---|---|
| ⌘ N | New workspace |
| ⌘ 1–8 | Jump to workspace 1–8 |
| ⌘ 9 | Jump to last workspace |
| ⌃ ⌘ ] | Next workspace |
| ⌃ ⌘ [ | Previous workspace |
| ⌘ ⇧ W | Close workspace |
| ⌘ ⇧ R | Rename workspace |
| ⌘ B | Toggle sidebar |
Surfaces
| Shortcut | Action |
|---|---|
| ⌘ T | New surface |
| ⌘ ⇧ ] | Next surface |
| ⌘ ⇧ [ | Previous surface |
| ⌃ Tab | Next surface |
| ⌃ ⇧ Tab | Previous surface |
| ⌃ 1–8 | Jump to surface 1–8 |
| ⌃ 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
Browser developer-tool shortcuts follow Safari defaults and are customizable in Settings → Keyboard Shortcuts.
| Shortcut | Action |
|---|---|
| ⌘ ⇧ L | Open browser in split |
| ⌘ L | Focus address bar |
| ⌘ [ | Back |
| ⌘ ] | Forward |
| ⌘ R | Reload page |
| ⌥ ⌘ I | Toggle Developer Tools (Safari default) |
| ⌥ ⌘ C | Show JavaScript Console (Safari default) |
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 |
Nightly Builds
cmux NIGHTLY is a separate app with its own bundle ID, so it runs alongside the stable version. Built automatically from the latest main commit and auto-updates via its own Sparkle feed.
Report nightly bugs on GitHub Issues or in #nightly-bugs on Discord.
Session restore (current behavior)
On relaunch, cmux currently restores app layout and metadata only:
- Window/workspace/pane layout
- Working directories
- Terminal scrollback (best effort)
- Browser URL and navigation history
cmux does not restore live process state inside terminal apps. For example, active Claude Code/tmux/vim sessions are not resumed after restart yet.
Star History
Contributing
Ways to get involved:
- Follow us on X for updates @manaflowai, @lawrencecchen, and @austinywang
- Join the conversation on Discord
- Create and participate in GitHub issues and discussions
- Let us know what you're building with cmux
Community
Founder's Edition
cmux is free, open source, and always will be. If you'd like to support development and get early access to what's coming next:
- Prioritized feature requests/bug fixes
- Early access: cmux AI that gives you context on every workspace, tab and panel
- Early access: iOS app with terminals synced between desktop and phone
- Early access: Cloud VMs
- Early access: Voice mode
- My personal iMessage/WhatsApp
License
cmux is open source under AGPL-3.0-or-later.
If your organization cannot comply with AGPL, a commercial license is available. Contact founders@manaflow.com for details.