From 4004d109cf58142b377acb7c106d8ca255e62c18 Mon Sep 17 00:00:00 2001 From: Eric Nielsen Date: Fri, 1 Dec 2017 07:18:40 -0500 Subject: [PATCH] Revert "fix typo'd var; otherwise colors would never apply" This reverts commit abbeeb9d375560b0e10c782e64970f22ff0dce11. That was not a typo --- modules/utility/init.zsh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/utility/init.zsh b/modules/utility/init.zsh index 6f9cac9..85debb6 100644 --- a/modules/utility/init.zsh +++ b/modules/utility/init.zsh @@ -6,10 +6,12 @@ # Colours # -if (( ${terminfo[colors]} >= 8 )); then +if (( terminfo[colors] >= 8 )); then if [[ ${OSTYPE} == (*bsd*|darwin*) ]]; then # BSD + (( ! ${+LSCOLORS} )) && export LSCOLORS='exfxcxdxbxGxDxabagacad' + if [[ ${OSTYPE} == openbsd* ]]; then # stock OpenBSD ls does not support colours at all, but colorls does. if (( ${+commands[colorls]} )); then @@ -22,6 +24,7 @@ if (( ${terminfo[colors]} >= 8 )); then (( ! ${+GREP_COLOR} )) && export GREP_COLOR='37;45' else # GNU + (( ! ${+LS_COLORS} )) && if [[ ${+commands[dircolors]} -ne 0 && -s ${HOME}/.dir_colors ]]; then eval "$(dircolors --sh ${HOME}/.dir_colors)" else