From 2e02a00e96a0bf02e68c460c0219f2e2aea8cb91 Mon Sep 17 00:00:00 2001 From: Kolan Sh Date: Mon, 18 Mar 2013 17:20:18 +0400 Subject: [PATCH] Condition for LS_COLORS updated. --- constants.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/constants.sh b/constants.sh index ac118d6..7b4a583 100755 --- a/constants.sh +++ b/constants.sh @@ -14,5 +14,8 @@ export PROMPT_COMMAND='history -a' unset DBUS_SESSION_BUS_ADDRESS -[[ -f $HOME/.dircolors ]] && eval $(dircolors -b $HOME/.dircolors) -[[ -n "$DISPLAY" ]] && [[ -f $HOME/.dircolors_256 ]] && eval $(dircolors -b $HOME/.dircolors_256) +if [[ "linux" == "$TERM" && -f $HOME/.dircolors ]]; then + eval $(dircolors -b $HOME/.dircolors) +elif [[ "linux" != "$TERM" && -f $HOME/.dircolors_256 ]]; then + eval $(dircolors -b $HOME/.dircolors_256) +fi