Tags: netj/optmux
Tags
Fix wtcode hotkey and integrate WTCODE_TMUX_MODE (#15) * Fix new_window shortcuts closing before showing output/errors Apply remain_wrap to new_window shortcuts so they pause on error, preventing the window from closing before the user can read the output. Fixes wtcode (C-M-c) and help (C-M-h) hotkeys. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> * Use WTCODE_TMUX_MODE=split-window for wtcode hotkey The C-M-c shortcut now runs wtcode in a new window with WTCODE_TMUX_MODE=split-window, which makes wtcode create a split pane with `cd /worktree && claude` in shell history. This allows easily restarting Claude after exit without re-selecting the worktree. Flow: C-M-c → new window → wtcode runs → split created → claude starts After Claude exits, press up arrow to get the command back. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> * Simplify wtcode hotkey: use new-window mode, no optmux new_window Changed C-M-c to run wtcode with WTCODE_TMUX_MODE=new-window in a temporary split pane, letting wtcode create the new window itself. Flow: C-M-c → temp split (zoomed) → wtcode creates new window → wtcode sends `cd /worktree && claude` → wtcode exits, temp split closes Result: Clean new window with Claude, command in shell history. Simpler than previous approach (optmux new_window + wtcode split-window). Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> * Run wtcode detached to avoid zoom flicker Added detached: true to C-M-c shortcut so the temporary split pane runs in background without disrupting focus or causing zoom flicker. Flow: C-M-c → background split → wtcode creates new window → split exits User stays in current pane, new window appears seamlessly. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> * Use split-window mode with new_window and remain: false Changed to WTCODE_TMUX_MODE=split-window with remain: false to avoid leaving error windows when wtcode exits with non-zero status. Flow: C-M-c → new window → wtcode (fzf UI) → split created → wtcode sends `cd /worktree && claude` → wtcode exits cleanly The split keeps the window alive, no error prompts on failure. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> * Bump version to 0.6.0 --------- Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
Fix extra default window when loading tmuxp sessions Move window 0 (tips + plugins-update) creation from a tmux session-created hook into cli.py, running it after tmuxp finishes. This prevents tmuxp from interfering with the hook and eliminates the bogus default window at index 1. Also skip re-creating the optmux window when attaching to an existing session. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
PreviousNext