Files
Panama/config/dot/tmux/tmux.conf
T
Gabriel Brown 27af4fd443 Carry the colour scheme into btop and tmux
Two more applications that keep their own palette and so never followed
the desktop. btop was on "Default" and had never been themed at all;
tmux had Tokyo Night Moon hardcoded across seventeen lines, which meant
a dark status bar sitting under a light terminal in light mode.

Both themes are authored rather than borrowed. btop ships a
"tokyo-night" theme, but it is the Night variant (#1a1b26) where the
rest of this desktop is Moon (#222436), and two Tokyo Nights side by
side read as a mistake; it ships no Tokyo Night light theme at all.
Colours come from kitty's theme files so a terminal and what runs inside
it cannot disagree.

tmux follows kitty's shape: the colours move to themes/, tmux.conf
sources a generated current-theme.conf, and running servers are
re-sourced so an open session changes immediately rather than at next
launch. btop is different -- it OWNS btop.conf and rewrites it on exit,
so only the color_theme line is edited in place and the file is not
symlinked into the repository. btop reads its theme once at startup, so
a running instance keeps the old colours; forcing a restart would kill a
process the user is watching.

The tmux light theme took two passes. Mapping the palette role-for-role
put the standard Day accents on a mid-grey panel at 2.74:1 and 2.94:1 --
under the 3:1 floor, on a bar you read at a glance. It now uses Day's
darker accent variants on a lighter panel: 4.42:1 and 4.17:1, and
5.01:1 / 4.73:1 for the light text inside the inverted blocks.

The helper also now reports every target rather than only kitty. Saying
"kitty: applied" while silently skipping three other applications is
how a half-applied theme goes unnoticed.

Not changed: bat is configured with --theme ansi, which follows the
terminal's own palette, so it already tracks kitty with nothing to do.

Claude-Session: https://claude.ai/code/session_01BRvzt4H8XXLPVH5MyYdk9L
2026-08-18 11:04:00 -04:00

70 lines
1.8 KiB
Bash

# True color support (crucial for kitty + neovim)
set -g default-terminal "tmux-256color"
set -ag terminal-overrides ",xterm-256color:RGB"
# Super important for osc52, images, hyperlinks, etc.
set -g allow-passthrough on
# Enable mouse support
set -g mouse on
# Renumber windows when one is closed
set -g renumber-windows on
# Set prefix to C-Space
unbind C-b
set -g prefix C-Space
bind C-Space send-prefix
# Set status bar
#set -g status-bg pink
# Tokyo Night Moon color palette
# Colours live in themes/ and are generated into current-theme.conf by
# panama-theme-apps, which regenerates it whenever the desktop colour scheme
# changes. -q so a fresh checkout without the generated file still starts.
source-file -q "~/.config/tmux/current-theme.conf"
# Increase scrollback buffer
set -g history-limit 50000
# Display tmux messages for 4 seconds
set -g display-time 4000
# Refresh status bar every 5 seconds
set -g status-interval 5
# Focus events for neovim autoread
set -g focus-events on
# Aggressive resize (useful for multi-monitor)
setw -g aggressive-resize on
# Reduce escape time (better for neovim)
set -sg escape-time 10
# Split panes using | and -
bind | split-window -h -c "#{pane_current_path}"
bind - split-window -v -c "#{pane_current_path}"
unbind '"'
unbind %
# Reload config
bind r source-file ~/.config/tmux/tmux.conf \; display "Config reloaded!"
# Switch panes with vim keys
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# Resize panes with vim keys
bind -r H resize-pane -L 5
bind -r J resize-pane -D 5
bind -r K resize-pane -U 5
bind -r L resize-pane -R 5
# Vi mode for copy mode
setw -g mode-keys vi
bind -T copy-mode-vi v send-keys -X begin-selection
bind -T copy-mode-vi y send-keys -X copy-selection-and-cancel