set -g default-terminal "screen-256color" set -g history-limit 50000 # v1.10.3: `set -g mouse on` removed. tmux's mouse mode captured wheel/touch # events at the protocol level, so xterm.js never saw them and the viewport # couldn't scroll on mobile. With mouse off, xterm.js handles scrollback # natively (wheel on desktop, finger-drag on mobile via touch-action: pan-y). # Tradeoff: lose tmux mouse pane-resize and scroll-inside-vim; acceptable for # the homelab single-user setup. setw -g mode-keys vi set -g status off set -g destroy-unattached off # v1.10.1: shells drop privs to samkintop (uid 1000) so the terminal runs in # the user's environment, not root. `env HOME=… USER=…` is required because # gosu (and su-exec before it) only changes uid/gid — it leaves env intact, # and the tmux server runs as root so HOME would otherwise be /root. bash -l # then sources samkintop's ~/.profile / ~/.bashrc to pick up PATH (nvm, # ~/.local/bin, ~/.opencode/bin). # v1.10.2: su-exec → gosu (alpine → debian; functionally identical). set -g default-command "gosu samkintop:samkintop env HOME=/home/samkintop USER=samkintop SHELL=/bin/bash bash -l"