Fix true color support for nvim in tmux

Uses the correct TERM env var and sets the correct rgb setting for
surrounding terminal.
This commit is contained in:
Marty Oehme 2019-11-18 17:16:32 +01:00
parent cd762cde4a
commit b33a58b593

View file

@ -25,7 +25,8 @@ set -g terminal-overrides "xterm*:XT:smcup@:rmcup@"
set-window-option -g automatic-rename on set-window-option -g automatic-rename on
set-option -g set-titles on set-option -g set-titles on
set -g mouse on set -g mouse on
set -g default-terminal xterm-256color # set -g default-terminal xterm-256color
set -g default-terminal tmux-256color
set -g status-keys vi set -g status-keys vi
set -g history-limit 10000 set -g history-limit 10000
@ -37,6 +38,8 @@ setw -g aggressive-resize on
# No delay for escape key press # No delay for escape key press
set -sg escape-time 0 set -sg escape-time 0
# enable true color support for nvim
set -ga terminal-overrides ',xterm-256color:RGB'
# Set Cursor terminal override, so nvim can change cursor style when changing modes # Set Cursor terminal override, so nvim can change cursor style when changing modes
# more info see nvim, :help tui-cursor-shape # more info see nvim, :help tui-cursor-shape
set -ga terminal-overrides '*:Ss=\E[%p1%d q:Se=\E[ q' set -ga terminal-overrides '*:Ss=\E[%p1%d q:Se=\E[ q'