fix(tmux): use tmux-256color and declare RGB per outer terminal - #10
Conversation
|
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
There was a problem hiding this comment.
Pull request overview
This PR updates the tmux configuration to accurately report terminal capabilities inside tmux by switching the internal $TERM to tmux-256color, and restores truecolor (24-bit) support by explicitly declaring RGB capability per outer terminal.
Changes:
- Set tmux’s
default-terminaltotmux-256colorto avoid misreporting capabilities (e.g., italics) to applications inside panes. - Append per-outer-terminal
terminal-featuresentries to advertise truecolor (RGB) forxterm-ghosttyandxterm-kitty.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
d85c491 to
4e833e3
Compare
b6f6042 to
18d82bb
Compare
default-terminal was xterm-256color, a terminfo that describes something tmux is not, so capabilities (notably italics) were misreported to programs running in the panes. tmux-256color is the entry that actually describes tmux. Switching it alone would have regressed colour. terminal-features is keyed on the OUTER terminal's name rather than default-terminal, and tmux-256color does not advertise RGB itself, so the existing xterm-256color:RGB line only ever matched Windows Terminal on the WSL box. Ghostty and kitty on the mac report xterm-ghostty and xterm-kitty and were never covered, which is why srcery's 24-bit colours quantised there. All three are now listed. The hyperlinks, extended-keys and focus-events settings are untouched. ncurses-term is pinned in .chezmoidata.yaml because Debian's ncurses-base ships only a minimal terminfo set without tmux-256color, and tmux would fail to start on the WSL box without it. macOS ships the entry already. Verified by loading the config on a scratch tmux socket: default-terminal resolves to tmux-256color and the three RGB features sit alongside tmux's built-in feature table rather than replacing it.
|
Reworked onto the current The original branch was cut before
The two fixes turned out to be complementary, not competing: Scope change worth a look: this also pins Verified by loading the config on a scratch tmux socket: |
4e833e3 to
07bdf50
Compare

default-terminal was xterm-256color, a terminfo that describes something
tmux is not, so it misreported capabilities (e.g. italics) to programs in
the panes. Switch to tmux-256color, the entry that actually describes tmux.
tmux-256color does not advertise Tc/RGB on its own, so that switch alone
would have downgraded srcery's 24-bit colours to the 256-colour approximation
and stopped nvim matching the tmux status bar. terminal-features is keyed on
the OUTER terminal, so declare RGB for each one actually used (ghostty,
kitty), appended with -as to keep tmux's built-in feature table.
Verified in a fresh pane: TERM=tmux-256color, COLORTERM=truecolor, and a
24-bit escape emitted as 38;2;252;232;195 matching srcery #FCE8C3.