Created
February 12, 2020 15:11
-
-
Save Sibirtsev/845745b309fb36cb658f5199cb5a426e to your computer and use it in GitHub Desktop.
Bash colors
This file contains 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 | |
#Background | |
for clbg in {40..47} {100..107} 49 ; do | |
#Foreground | |
for clfg in {30..37} {90..97} 39 ; do | |
#Formatting | |
for attr in 0 1 2 4 5 7 ; do | |
#Print the result | |
echo -en "\033[${attr};${clbg};${clfg}m ${attr};${clbg};${clfg}m " | |
done | |
echo #Newline | |
done | |
done | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment