Skip to content

Instantly share code, notes, and snippets.

@rahulinux
Last active December 22, 2015 04:09
Show Gist options
  • Save rahulinux/6415072 to your computer and use it in GitHub Desktop.
Save rahulinux/6415072 to your computer and use it in GitHub Desktop.
Status Msg
status_msg() {
local status=$?
local failed="$(tput bold)$(tput setf 4)[failed]$(tput sgr0)"
local succeeded="$(tput bold)$(tput setf 2)[succeeded]$(tput sgr0)"
(( $status == 0 )) &&
echo $succeeded ||
echo $failed
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment