dot-files/scripts/function/display_warning
Buddy Sandidge 4a47c0e8f4 Squashed 'gvm/' content from commit 23017d2c9
git-subtree-dir: gvm
git-subtree-split: 23017d2c98964d5178082340c69d63fd01512f5f
2014-08-05 21:18:26 -07:00

14 lines
208 B
Plaintext

display_warning() {
which tput &> /dev/null
if [[ "$?" == "0" ]] && [[ "$TERM" == "xterm" ]]; then
# YELLOW!
tput sgr0
tput setaf 3
echo "WARNING: $1"
tput sgr0
else
echo "$1"
fi
return 1
}