From 45ad72f3c2b3037e826a285aa443d421ec7f8669 Mon Sep 17 00:00:00 2001 From: Christian Heller Date: Fri, 11 Dec 2015 02:45:04 +0100 Subject: [PATCH] Simplify Bash test. --- dotfiles_minimal/shinit | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/dotfiles_minimal/shinit b/dotfiles_minimal/shinit index a5a9ee2..c80a6bc 100644 --- a/dotfiles_minimal/shinit +++ b/dotfiles_minimal/shinit @@ -16,8 +16,7 @@ fi tput_color="$(tput setaf $colornumber)$(tput bold)" tput_reset="$(tput sgr0)" # Bash confuses the line length when not told to not count escape sequences. -which_shell=`lsof -ap $$ -d txt | awk 'NR>1 {print $NF}'` -if [ "${which_shell#*'bash'}" != "$which_shell" ]; then +if [ ! "$BASH" = "" ]; then tput_color="\[$tput_color\]" tput_reset="\[$tput_reset\]" fi -- 2.30.2