#color-logger-bash
debug, info, warn, error, success, highlight
debug "Hold on to your butts."
info "It's got a dragon painted right on the blade!"
warn "Danger, Will Robinson!"
error "Somebody gonna get a hurt real bad."
success "So you're telling me there's a chance..."
info "More Obscure?? Okay... " "$(highlight "I can't believe my eyes"). " "It's like looking in a mirror!"
Be sure to notice that highlight requires the "$()" format to deal with subshell issues maintaining the integrity of the message.
Ideal use is sourcing inside your script and then use a logger function directly.
highlight is a special case. It can be used in conjunction with other logging functions.
git clone https://github.com/swyckoff/bash-color-logger.git
./install.sh
or this (which is what install does)
cd /usr/local/bin
wget https://raw.githubusercontent.com/swyckoff/color-logger-bash/master/color-logger.bash
cd -
Pull down the script
wget https://raw.githubusercontent.com/swyckoff/bash-color-logger/master/color-logger.bash
'source' in your script
. color-logger.bash
color-logger.bash -h
- See/Add issues!
MIT