From 3aef6793c2bf0c0afec1fdb97a3a56e7f8d065c6 Mon Sep 17 00:00:00 2001 From: Josh Matthews Date: Tue, 26 Feb 2013 18:05:58 -0500 Subject: [PATCH] Now checking for 256 color terminal in tmux plugin. --- plugins/tmux/tmux.plugin.zsh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/plugins/tmux/tmux.plugin.zsh b/plugins/tmux/tmux.plugin.zsh index a2f36c0b..f67c2b8b 100644 --- a/plugins/tmux/tmux.plugin.zsh +++ b/plugins/tmux/tmux.plugin.zsh @@ -11,6 +11,14 @@ # Get the absolute path to the current directory local zsh_tmux_plugin_path="$(cd "$(dirname "$0")" && pwd)" +# Determine if the terminal supports 256 colors +if [[ `tput colors` == "256" ]] +then + export $ZSH_TMUX_TERM="screen-256" +else + export $ZSH_TMUX_TERM="screen" +fi + # Local variable to store the local config file to use, if any. local fixed_config=""