cpt

[ARCHIVED] Carbs Packaging Tools
git clone git://git.ckyln.com/~cem/cpt.git
Log | Files | Refs | README | LICENSE

commit aab60bb9ecc118fe177b45ad7f8e04dcc75d94df
parent 17ee3eaed4f41565d2fd5cafb2d8063eddf39e08
Author: Dylan Araps <dylan.araps@gmail.com>
Date:   Wed, 22 Jan 2020 19:01:19 +0200

Merge branch 'master' of github.com:kissx/kiss

Diffstat:
Mkiss | 18+++++++-----------
1 file changed, 7 insertions(+), 11 deletions(-)

diff --git a/kiss b/kiss @@ -15,17 +15,13 @@ log() { # Print a message prettily. # - # This function uses the literal escape character (Ctrl+V+Escape) as - # a simple way of *safely* bypassing the escape sequence restrictions - # on 'printf %s'. Cheeky, I know. - # - # '\033[1;32m' Set text to color '2' and make it bold. - # '\033[m': Reset text formatting. - # '${3:-->}': If the 3rd argument is missing, set prefix to '->'. - # '${2:+[1;3Xm}': If the 2nd argument exists, set the text style of '$1'. - # '${2:+[m}': If the 2nd argument exists, reset text formatting. - printf '\033[1;33m%s \033[m%s\033[m %s\n' \ - "${3:-->}" "${2:+}$1${2:+}" "$2" + # '\033[1;32m' Set text to color '2' and make it bold. + # '\033[m': Reset text formatting. + # '${3:-->}': If the 3rd argument is missing, set prefix to '->'. + # '${2:+\033[1;3Xm}': If the 2nd argument exists, set text style of '$1'. + # '${2:+\033[m}': If the 2nd argument exists, reset text formatting. + printf '\033[1;33m%s \033[m%b%s\033[m %s\n' \ + "${3:-->}" "${2:+\033[1;36m}" "$1" "$2" } die() {