diff --git a/update.sh b/update.sh index 85f24c3f2..6aa3f15af 100755 --- a/update.sh +++ b/update.sh @@ -1,16 +1,22 @@ #!/usr/bin/env bash set -eu +function color { + if [[ -t 1 ]]; then + tput setaf ${1:-7} + fi +} + function say { - tput setaf 5 + color 5 # magenta echo -e "( ^-^) < $1" - tput setaf 7 + color } function running { - tput setaf 3 + color 3 # yellow echo "[running] \$ $1" - tput setaf 7 + color } say "Start upgrading Firefish!"