From 86b9b2700e6a9d986c66a6abb7d0b9ae647c78ab Mon Sep 17 00:00:00 2001 From: Aaron LI Date: Sun, 29 May 2016 22:51:20 +0800 Subject: tmux.conf: set "terminal-overrides" to avoid strange char Strange characters '???112' may appear when exited the tmux session, which is caused by the terminal that dose not properly handle the Cr (color reset) control sequence. So use "terminal-overrides" to override this. Environment: SSH to a DragonFly BSD with Xfce4 terminal. (other terminals, e.g., urxvt and konsole, are OK) --- _tmux.conf | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to '_tmux.conf') diff --git a/_tmux.conf b/_tmux.conf index 3762fe5..33dff6c 100644 --- a/_tmux.conf +++ b/_tmux.conf @@ -3,7 +3,7 @@ ## ## Aaron LI ## Created: 2015-01-22 -## Updated: 2016-05-01 +## Updated: 2016-05-29 ## ## References: ## [1] tmux: Productive Mouse-Free Development (by Brian P. Hogan) @@ -65,6 +65,12 @@ bind -r L resize-pane -R 5 ## Set the default terminal mode set-option -g default-terminal "screen-256color" +## Terminal settings +# Override terminal's default Cr (color reset) to avoid the strange +# 'char+112' when just exited the tmux session. +# Credit: https://github.com/tmux/tmux/issues/266 +set-option -g terminal-overrides ',xterm*:Cr=\E]12;gray\007' + ## Enable activity alerts set-window-option -g monitor-activity on set-option -g visual-activity on -- cgit v1.2.2