Revision 12840
Added by Aaron Marcuse-Kubitza almost 11 years ago
trunk/lib/sh/util.sh | ||
---|---|---|
511 | 511 |
{ |
512 | 512 |
kw_params format; local format="${format-1}" # bold |
513 | 513 |
if ! can_highlight_msg; then format=; fi |
514 |
local highlight="$(test "$format"; exit2bool)" |
|
515 |
echo "${highlight:+[0;${format}m}$1${highlight:+[0m}" |
|
514 |
echo "${format:+[0;${format}m}$1${format:+[0m}" |
|
516 | 515 |
} |
517 | 516 |
|
518 | 517 |
log_line!() # highlights log_level 1 messages to stand out against other output |
Also available in: Unified diff
lib/sh/util.sh: highlight_msg(): use $format itself as the $highlight boolean