From 26893ea50f101dcc833a0e72fc1f148a99cd39a6 Mon Sep 17 00:00:00 2001 From: Tony Tkacik Date: Mon, 12 Jun 2017 14:31:56 +0200 Subject: [PATCH] bashrc: Added color support for termux Signed-off-by: Tony Tkacik --- bashrc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bashrc b/bashrc index 9493ef8..1931608 100755 --- a/bashrc +++ b/bashrc @@ -35,6 +35,7 @@ fi # set a fancy prompt (non-color, unless we know we "want" color) case "$TERM" in xterm-color) color_prompt=yes;; + xterm-256color) color_prompt=yes;; esac # uncomment for a colored prompt, if the terminal has the capability; turned @@ -43,7 +44,7 @@ esac force_color_prompt=yes if [ -n "$force_color_prompt" ]; then - if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then + if [ -n $(which tput) ] && tput setaf 1 >&/dev/null; then # We have color support; assume it's compliant with Ecma-48 # (ISO/IEC-6429). (Lack of such support is extremely rare, and such # a case would tend to support setf rather than setaf.)