Last active
March 19, 2020 21:22
-
-
Save lexblagus/8c7460b4e983b66397c3c2006e69ae45 to your computer and use it in GitHub Desktop.
Bash colors template
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 | |
for clbg in {40..47} {100..107} 49 ; do # background | |
for clfg in {30..37} {90..97} 39 ; do # foreground | |
for attr in 0 1 2 4 5 7 ; do # formatting | |
printf "\e[${attr};${clbg};${clfg}m" # colorization | |
printf "\\\e[${attr};${clbg};${clfg}m" # code text prefix | |
printf " ░▒▓█▓▒░ " # sample characters | |
printf "\\\e[0m" # code text suffix | |
printf "\e[0m" # reset color | |
printf " " # space between columns | |
done | |
echo # newline between foregrounds | |
done | |
echo # newline between backgrounds | |
done | |
exit 0 |
Author
lexblagus
commented
Mar 19, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment