aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAaron LI <aaronly.me@gmail.com>2016-05-29 22:51:20 +0800
committerAaron LI <aaronly.me@gmail.com>2016-05-29 22:58:06 +0800
commit86b9b2700e6a9d986c66a6abb7d0b9ae647c78ab (patch)
tree6fc8b13e0e4d67e2052d4c978bb4b4137ab83b4f
parentfa695734493d4068b3c67a8f1895a1a2a322ed61 (diff)
downloaddotfiles-86b9b2700e6a9d986c66a6abb7d0b9ae647c78ab.tar.bz2
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)
-rw-r--r--_tmux.conf8
1 files changed, 7 insertions, 1 deletions
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