Skip to content

Terminal#9

Merged
andyrewlee merged 10 commits intomainfrom
terminal
Jan 1, 2026
Merged

Terminal#9
andyrewlee merged 10 commits intomainfrom
terminal

Conversation

@andyrewlee
Copy link
Owner

No description provided.

andyrewlee and others added 10 commits January 1, 2026 08:28
Implements amux-93p: Split sidebar horizontally with terminal at bottom.

Features:
- Terminal section below file changes in sidebar (50/50 split)
- Opens user's default shell ($SHELL) in current worktree directory
- Navigation: Ctrl+J to terminal, Ctrl+K back to files, Ctrl+L to sidebar
- Terminal persists per worktree when switching between worktrees
- VTerm rendering with scrollback support
- Proper PTY handling following center pane patterns

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Track last terminal size to avoid redundant PTY resizes that cause
  shell prompt to redraw repeatedly
- Intercept navigation keys (Ctrl+H/K) before forwarding to sidebar
  terminal, similar to center pane pattern
- Fix immediate navigation when leaving sidebar terminal

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
The navigation handlers were missing return statements, causing the key
to be routed to the newly focused pane after focus change. This sent
Ctrl+J (0x0a newline) to the terminal, causing the shell prompt to repeat.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Commented out synchronous debug logging for key presses since it does
file I/O on every keystroke. This should reduce input latency.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Add MoveUp, MoveDown, Help bindings to app KeyMap
- Add terminalKeyMap to sidebar terminal with scroll bindings
- Replace inline key.NewBinding() calls with pre-allocated bindings
- Reduces allocations on every keystroke

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Rendering both file changes and terminal with JoinVertical caused
perceived lag. Now ctrl+j/k switches between showing ONLY file changes
OR terminal at full height.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@andyrewlee andyrewlee merged commit b82fb12 into main Jan 1, 2026
1 check passed
@andyrewlee andyrewlee deleted the terminal branch January 1, 2026 17:26
andyrewlee added a commit that referenced this pull request Jan 8, 2026
* Add sidebar terminal section with worktree-specific shell

Implements amux-93p: Split sidebar horizontally with terminal at bottom.

Features:
- Terminal section below file changes in sidebar (50/50 split)
- Opens user's default shell ($SHELL) in current worktree directory
- Navigation: Ctrl+J to terminal, Ctrl+K back to files, Ctrl+L to sidebar
- Terminal persists per worktree when switching between worktrees
- VTerm rendering with scrollback support
- Proper PTY handling following center pane patterns

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Fix sidebar terminal resize spam and Ctrl+J/K navigation

- Track last terminal size to avoid redundant PTY resizes that cause
  shell prompt to redraw repeatedly
- Intercept navigation keys (Ctrl+H/K) before forwarding to sidebar
  terminal, similar to center pane pattern
- Fix immediate navigation when leaving sidebar terminal

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Fix Ctrl+J/K sending newline to terminal on focus change

The navigation handlers were missing return statements, causing the key
to be routed to the newly focused pane after focus change. This sent
Ctrl+J (0x0a newline) to the terminal, causing the shell prompt to repeat.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Remove debug logging from hot paths to reduce latency

Commented out synchronous debug logging for key presses since it does
file I/O on every keystroke. This should reduce input latency.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Add timing debug hook for key latency investigation (commented out)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Optimize key bindings: pre-allocate instead of inline creation

- Add MoveUp, MoveDown, Help bindings to app KeyMap
- Add terminalKeyMap to sidebar terminal with scroll bindings
- Replace inline key.NewBinding() calls with pre-allocated bindings
- Reduces allocations on every keystroke

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Fix sidebar lag: show one pane at a time instead of vertical split

Rendering both file changes and terminal with JoinVertical caused
perceived lag. Now ctrl+j/k switches between showing ONLY file changes
OR terminal at full height.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Fix sidebar focus lag with gutter highlight

* Match sidebar focus borders to pane styling

* Unify sidebar into single pane with inner focus

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant