Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
logging and colors
#!/usr/bin/env bash
RED=$'\e[0;31m'
R=${RED}
BLUE=$'\e[0;34m'
B=${BLUE}
GREEN=$'\e[0;32m'
G=${GREEN}
CYAN=$'\e[0;36m'
C=${CYAN}
YELLOW=$'\e[0;33m'
Y=${YELLOW}
RESET=$'\e[0m'
RC=${RESET}
announce(){
echo "${Y}[ $(date -u '+%Y-%m-%dT%H:%M') ] xXx - ${1}${RC}"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment