Commit graph

144 commits

Author SHA1 Message Date
Zachary Salzbank
730d64b943
feat: add --direction flag to markdown open command (#1763)
Supports left/right/up/down, defaulting to right (existing behavior).
Matches the --direction flag convention used by new-pane and new-split.
2026-03-20 01:48:28 -07:00
bagelcode-jhkim
e0c301b277
feat: add set-color/clear-color to workspace-action CLI (#1833)
* [auto] cmux session changes (1 files) [03/19 17:38]

* feat: add set-color/clear-color to workspace-action

- CLI: parse --color option in runWorkspaceAction
- CLI: validate --color required for set-color action
- CLI: pass color param to v2 payload
- CLI: update help text and usage summary
- TerminalController: add set_color/clear_color to supportedActions
- TerminalController: handle set_color/clear_color cases via setTabColor

* fix: resolve named colors via palette, improve clear_color response

* fix: validate hex input via normalizedHex, fix synopsis typo
2026-03-19 22:34:31 -07:00
Lawrence Chen
b301218405
Honor explicit notification surface targets 2026-03-19 01:21:18 -07:00
Austin Wang
55cb5c6763
Fix sidebar workspace PR status display and false positives (#1636)
* test(sidebar): add failing PR checks regressions

* fix(sidebar): show workspace PR status

* refactor(sidebar): restore PR icon style

* refactor(sidebar): simplify PR check labels

* test(sidebar): cover focused workspace PR selection

* fix(sidebar): scope workspace PRs to current branch

* test(sidebar): cover stale PR after branch change

* fix(sidebar): clear stale PRs on branch changes

* test(sidebar): cover workspace PR false positives

* fix(sidebar): stop false-positive workspace PR badges

* test(cmuxTests): remove duplicate sidebar PR regressions
2026-03-17 22:57:12 -07:00
Lawrence Chen
8d8fadbb27
Add hidden CLI command for live terminal debugging (#1599)
* Add hidden terminal debug CLI command

* Expand orphan terminal debug metadata

* Remove stray CLIProcessRunner test target wiring

* Tighten debug terminal diagnostics handling

---------

Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com>
2026-03-17 04:03:49 -07:00
Lawrence Chen
832426af56
Stabilize SSH remote flow after merging main 2026-03-16 23:57:48 -07:00
Lawrence Chen
03dc055138
Merge remote-tracking branch 'origin/main' into pr-ssh-stack-main
# Conflicts:
#	CLI/cmux.swift
#	Sources/Panels/BrowserPanel.swift
#	Sources/TabManager.swift
#	Sources/Workspace.swift
#	cmuxTests/GhosttyConfigTests.swift
2026-03-16 23:16:12 -07:00
Austin Wang
9bf6ad9457
Avoid blocking browser PR metadata updates (#1564) 2026-03-16 22:10:15 -07:00
Lawrence Chen
3fbfd74aa1 Fix socket focus and startup env regressions 2026-03-13 21:55:48 -07:00
Lawrence Chen
623262493b
Fix stale Claude sidebar status: add missing hooks, OSC suppression, PID sweep (#1306)
* Fix stale Claude status in sidebar by adding missing hooks and OSC suppression

The Claude Code integration only used 3 hooks (SessionStart, Stop, Notification),
leaving gaps that caused stale sidebar status. Now uses 6 hooks:

- SessionEnd: clears status when Claude exits (covers Ctrl+C where Stop doesn't fire)
- UserPromptSubmit: clears "Needs input" and sets "Running" on new prompt
- PreToolUse (async): clears "Needs input" when Claude resumes after permission grant

Also:
- Suppress OSC 9/99 desktop notifications for workspaces with active Claude hook
  sessions to prevent duplicates from the raw OSC path
- Store Claude process PID in status entries for stale-session detection
- Add 30-second sweep timer that checks agent PIDs and clears stale entries
  (safety net for SIGKILL/crash where no hook fires)
- Update wrapper test expectations for the new hook set

Fixes https://github.com/manaflow-ai/cmux/issues/1301

* Don't show "Running" status on Claude launch, only when actually working

SessionStart now registers the PID for tracking and OSC suppression via
set_agent_pid without setting a visible status entry. "Running" only
appears when the user submits a prompt (UserPromptSubmit) or Claude
starts using tools (PreToolUse).

Added set_agent_pid / clear_agent_pid socket commands to decouple PID
tracking from visible status entries. OSC suppression checks agentPIDs
instead of statusEntries so it works during the initial idle period.

* Don't restore status entries across app restarts

Status entries are ephemeral runtime state tied to running processes
(e.g. claude_code "Running"). Restoring them after restart shows stale
status for processes that no longer exist.

* Address PR review comments and remove debug logging

- session-end: only clear status/PID/notifications when Stop didn't fire first
- PID sweep: check errno == ESRCH instead of treating all kill(pid,0) failures as dead
- Validate CMUX_CLAUDE_PID > 0
- Propagate tracked PID in pre-tool-use setClaudeStatus
- OSC suppression: use tabManagerFor(tabId:) for multi-window support
- clearAgentPID: resolve tab UUID before async dispatch
- restoreSessionSnapshot: also clear agentPIDs alongside statusEntries
- Fix AskUserQuestion surfaceId overwrite (wrong workspace notification)
- Fix notification text matching for "Claude Code needs your attention"
- AskUserQuestion: render option labels as bracketed inline text
- Remove artificial text truncation limits
- Remove temporary JSONL debug logging from all handlers

* Use resolveTabIdForSidebarMutation in clearAgentPID
2026-03-13 20:47:42 -07:00
Lawrence Chen
2a8d4475a3
Throttle repeated socket listener start failures 2026-03-13 19:54:09 -07:00
Lawrence Chen
2eae782739 Merge remote-tracking branch 'origin/main' into pr-ssh-stack-main
# Conflicts:
#	.github/workflows/ci.yml
#	CLI/cmux.swift
#	Sources/GhosttyTerminalView.swift
#	Sources/SocketControlSettings.swift
#	Sources/TabManager.swift
#	Sources/TerminalController.swift
#	Sources/Workspace.swift
#	ghostty
#	scripts/reload.sh
2026-03-13 17:56:38 -07:00
Lawrence Chen
8a0934b801
Fallback stable socket listener to a user-scoped path (#1351)
* Fallback stable socket listener to user socket path

* Move stable socket path out of /tmp

* Keep socket health checks active on fallback paths

---------

Co-authored-by: Lawrence Chen <lawrencecchen@users.noreply.github.com>
2026-03-13 17:37:01 -07:00
Lawrence Chen
5dd93a8ab1
Merge pull request #1401 from manaflow-ai/task-cmd-shift-u-exits-cmd-shift-enter-mode
Exit split zoom when jumping to unread
2026-03-13 17:28:34 -07:00
Lawrence Chen
cd04bb8932
Merge origin/main into feat-cmux-themes-command 2026-03-13 17:22:12 -07:00
Lawrence Chen
09a98c911d
Guard notification focus failures 2026-03-13 17:21:40 -07:00
Lawrence Chen
a99ee15672
fix: honor shell state for close confirmation 2026-03-13 15:43:04 -07:00
Lawrence Chen
965965c879 Merge origin/main into pr-ssh-stack-main 2026-03-13 06:25:08 -07:00
Lawrence Chen
50b5969d62 Add remote favicon proxy regression 2026-03-13 06:15:23 -07:00
Lawrence Chen
4fffe3be3d Address ssh stack review follow-ups 2026-03-13 04:28:24 -07:00
Lawrence Chen
601e5a92e4 Merge origin/main into pr-ssh-stack-main 2026-03-13 04:18:07 -07:00
Lawrence Chen
6584a01aef
Add cmux themes command 2026-03-13 03:26:51 -07:00
Ariel Tobiana
1d6f55ce97
Include current_directory and custom_color in list-workspaces output (#544)
Expose workspace working directory and tab color in the workspace.list
response, enabling CLI-based workspace sorting and color inspection.
2026-03-12 23:40:38 -07:00
Lawrence Chen
19b59cae37 Reapply "Merge pull request #239 from manaflow-ai/issue-151-ssh-remote-port-proxying"
This reverts commit f7cbbad434.
2026-03-12 15:54:26 -07:00
Lawrence Chen
f7cbbad434 Revert "Merge pull request #239 from manaflow-ai/issue-151-ssh-remote-port-proxying"
This reverts commit 78e4bd32ba, reversing
changes made to cf75da8f8a.
2026-03-12 14:45:58 -07:00
Lawrence Chen
8a9e28e129 Secure remote daemon distribution and relay auth 2026-03-12 05:04:44 -07:00
Lawrence Chen
de47345538 Address ssh review feedback and CI blockers 2026-03-11 23:03:53 -07:00
Lawrence Chen
1b4f396a48 Merge remote-tracking branch 'origin/main' into issue-151-ssh-remote-port-proxying
# Conflicts:
#	Sources/Panels/BrowserPanel.swift
2026-03-11 22:52:47 -07:00
austinpower1258
5233874425 ok 2026-03-11 18:32:23 -07:00
Lawrence Chen
d67090994e Merge branch 'main' into issue-151-ssh-remote-port-proxying 2026-03-11 15:56:47 -07:00
Lawrence Chen
d9021861e3 Preserve ssh remote browser proxy flow 2026-03-11 15:45:20 -07:00
Lawrence Chen
52783bddf0
Polish welcome, feedback, and shortcuts flows (#1169)
* Add cmux welcome command with ASCII logo and shortcuts

Adds `cmux welcome` CLI command that prints a blue-to-purple gradient
chevron logo, version info, and key shortcuts. Auto-runs once on first
workspace creation via UserDefaults. Adds "Welcome" to the ? help menu
in the sidebar footer, which opens a new workspace running the command.

* Polish welcome, feedback, and shortcuts flows
2026-03-10 20:59:34 -07:00
Austin Wang
d25067f38f
Merge pull request #1170 from manaflow-ai/fix-1160-devtools-loop
Fix side-docked browser DevTools resizing
2026-03-10 20:12:17 -07:00
austinpower1258
eea6cdc1bd works 2026-03-10 19:18:30 -07:00
Lawrence Chen
e5445f4071 Fix cmux ssh startup isolation 2026-03-10 00:18:27 -07:00
Lawrence Chen
bdebc8ecc9 Merge branch 'main' into issue-151-ssh-remote-port-proxying
# Conflicts:
#	CLI/cmux.swift
#	Sources/ContentView.swift
#	Sources/GhosttyTerminalView.swift
#	Sources/Panels/BrowserPanel.swift
#	Sources/Panels/BrowserPanelView.swift
#	Sources/TabManager.swift
#	Sources/TerminalController.swift
#	Sources/Workspace.swift
#	Sources/WorkspaceContentView.swift
#	ghostty
2026-03-09 18:36:59 -07:00
Lawrence Chen
30bb74dc92 Merge branch 'pr-374-ssh-remote-cli-relay' into issue-151-ssh-remote-port-proxying
# Conflicts:
#	CLI/cmux.swift
#	Sources/ContentView.swift
#	Sources/GhosttyTerminalView.swift
#	Sources/Panels/TerminalPanel.swift
#	Sources/SocketControlSettings.swift
#	Sources/TabManager.swift
#	Sources/TerminalController.swift
#	Sources/Workspace.swift
#	daemon/remote/README.md
#	daemon/remote/cmd/cmuxd-remote/main.go
#	docs/remote-daemon-spec.md
#	tests_v2/test_ssh_remote_cli_metadata.py
2026-03-09 18:31:10 -07:00
Gonzalo Serrano
3a3a2da6db Add color field to sidebar_state output
Expose workspace customColor in sidebar_state so external
tools can read it without a new API endpoint.
2026-03-09 15:01:02 +01:00
austinpower1258
01e9a05817 Merge remote-tracking branch 'origin/main' into issue-1036-tooltip-tracking-area-crash
# Conflicts:
#	Sources/ContentView.swift
2026-03-07 02:53:20 -08:00
austinpower1258
9e8a401e3c Fix tooltip tracking lifetime and shortcut lag 2026-03-07 01:46:02 -08:00
Lawrence Chen
e7c3961489
Revert "Add workspace pages in the titlebar (#1030)" (#1040)
This reverts commit 4de975e6a4.
2026-03-07 00:05:58 -08:00
Lawrence Chen
4de975e6a4
Add workspace pages in the titlebar (#1030)
* Add workspace pages in the titlebar

* Add workspace pages UI test target entry

* Relax workspace pages UI test titlebar checks

* Use page close button in workspace pages UI test

* Stabilize workspace pages UI test interruptions

* Skip page close confirms in UI tests

* Clean up superseded workspace handoffs

* Tighten page hint UI assertions

---------

Co-authored-by: cmux <cmux@cmuxs-Mac-mini.local>
2026-03-06 21:23:11 -08:00
austinpower1258
d43d7d6a51 Fix drag hover redraw churn in hosted panes 2026-03-06 15:47:11 -08:00
Lawrence Chen
d8ffb3eedb
Merge pull request #932 from manaflow-ai/issue-922-notify-steals-window-focus
Fix cmux notify focus steal regression
2026-03-06 00:51:47 -08:00
Lawrence Chen
6993c8ceef Allow notify_target across windows 2026-03-05 22:53:37 -08:00
Lawrence Chen
21bb31dcfb Avoid blocking notify regression socket replies 2026-03-05 21:58:38 -08:00
Lawrence Chen
335aaaecec Fix send_workspace routing in inactive windows 2026-03-05 21:24:25 -08:00
austinpower1258
7af383c3d0 Merge branch 'main' of https://github.com/manaflow-ai/cmux into issue-915-terminal-not-loaded 2026-03-05 20:58:49 -08:00
austinpower1258
990b6ba12a ok 2026-03-05 20:51:51 -08:00
Lawrence Chen
acd8dbff69 Keep send_workspace test-only 2026-03-05 20:24:49 -08:00