summaryrefslogtreecommitdiffstats
path: root/envsetup.sh
diff options
context:
space:
mode:
authorRoman Birg <roman@cyngn.com>2015-10-16 10:29:06 -0700
committerRoman Birg <roman@cyngn.com>2015-10-26 11:58:40 -0700
commitead9a5c6c96c7bb30515b1f4d47d87a0a2949592 (patch)
treec1501dc6413f6a6532809428289a204f606d7326 /envsetup.sh
parentc240fb90269a8d7676facd31d33116e66a141c9c (diff)
downloadbuild-ead9a5c6c96c7bb30515b1f4d47d87a0a2949592.zip
build-ead9a5c6c96c7bb30515b1f4d47d87a0a2949592.tar.gz
build-ead9a5c6c96c7bb30515b1f4d47d87a0a2949592.tar.bz2
fix success/failure coloring for darwin
what's the point of OS X if it's not pretty Change-Id: I7a1ed0766adead46b46092acf826c6ef270edd10 Signed-off-by: Roman Birg <roman@cyngn.com>
Diffstat (limited to 'envsetup.sh')
-rw-r--r--envsetup.sh13
1 files changed, 6 insertions, 7 deletions
diff --git a/envsetup.sh b/envsetup.sh
index 2f019f9..36b00b4 100644
--- a/envsetup.sh
+++ b/envsetup.sh
@@ -2302,9 +2302,9 @@ function pez {
local retval=$?
if [ $retval -ne 0 ]
then
- echo -e "\e[0;31mFAILURE\e[00m"
+ printf "\e[0;31mFAILURE\e[00m\n"
else
- echo -e "\e[0;32mSUCCESS\e[00m"
+ printf "\e[0;32mSUCCESS\e[00m\n"
fi
return $retval
}
@@ -2328,7 +2328,7 @@ function mk_timer()
if [ -n "$ncolors" ] && [ $ncolors -ge 8 ]; then
color_failed="\e[0;31m"
color_success="\e[0;32m"
- color_reset="\e[00m"
+ color_reset="\e[0m"
else
color_failed=""
color_success=""
@@ -2336,9 +2336,9 @@ function mk_timer()
fi
echo
if [ $ret -eq 0 ] ; then
- echo -n -e "${color_success}#### make completed successfully "
+ printf "${color_success}#### make completed successfully "
else
- echo -n -e "${color_failed}#### make failed to build some targets "
+ printf "${color_failed}#### make failed to build some targets "
fi
if [ $hours -gt 0 ] ; then
printf "(%02g:%02g:%02g (hh:mm:ss))" $hours $mins $secs
@@ -2347,8 +2347,7 @@ function mk_timer()
elif [ $secs -gt 0 ] ; then
printf "(%s seconds)" $secs
fi
- echo -e " ####${color_reset}"
- echo
+ printf " ####${color_reset}\n\n"
return $ret
}