Revision 12810
Added by Aaron Marcuse-Kubitza almost 11 years ago
util.sh | ||
---|---|---|
489 | 489 |
# format: the # in xfree86.org/current/ctlseqs.html#Character_Attributes |
490 | 490 |
{ |
491 | 491 |
kw_params format; local format="${format-4}" # underline |
492 |
local highlight="$(can_highlight_msg; exit2bool)" |
|
492 |
local highlight="$(test "$format" && can_highlight_msg; exit2bool)"
|
|
493 | 493 |
echo "${highlight:+[${format}m}$1${highlight:+[0m}" |
494 | 494 |
} |
495 | 495 |
|
Also available in: Unified diff
lib/sh/util.sh: highlight_msg(): allow turning off formatting w/ empty $format