We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c5c3fbf commit f6d67e3Copy full SHA for f6d67e3
releasey/libs/_log.sh
@@ -27,17 +27,17 @@ if [[ -t 2 ]] &&
27
[[ "${NO_COLOR:-}" != "1" ]] &&
28
[[ "${TERM:-}" != "dumb" ]] &&
29
command -v tput >/dev/null; then
30
- RED='\033[0;31m'
31
- GREEN='\033[0;32m'
32
- YELLOW='\033[1;33m'
33
- BLUE='\033[0;34m'
34
- RESET='\033[0m' # No Color
+ RED=${RED:-$(tput setaf 1)}
+ GREEN=${GREEN:-$(tput setaf 2)}
+ YELLOW=${YELLOW:-$(tput bold; tput setaf 3)}
+ BLUE=${BLUE:-$(tput setaf 4)}
+ RESET=${RESET:-$(tput sgr0)}
35
else
36
- RED=''
37
- GREEN=''
38
- YELLOW=''
39
- BLUE=''
40
- RESET=''
+ RED=${RED:-''}
+ GREEN=${GREEN:-''}
+ YELLOW=${YELLOW:-''}
+ BLUE=${BLUE:-''}
+ RESET=${RESET:-''}
41
fi
42
43
function print_error() {
0 commit comments