Created
October 25, 2011 20:17
-
-
Save eager/1314108 to your computer and use it in GitHub Desktop.
Bash colorized outputs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Text color variables | |
txtund=$(tput sgr 0 1) # Underline | |
txtbld=$(tput bold) # Bold | |
txtred=$(tput setaf 1) # Red | |
txtgrn=$(tput setaf 2) # Green | |
txtylw=$(tput setaf 3) # Yellow | |
txtblu=$(tput setaf 4) # Blue | |
txtpur=$(tput setaf 5) # Purple | |
txtcyn=$(tput setaf 6) # Cyan | |
txtwht=$(tput setaf 7) # White | |
txtrst=$(tput sgr0) # Text reset |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment