Last active
May 16, 2020 14:46
-
-
Save ryot4/589d7c4cf6a55ee56c1b7606e3220a9d to your computer and use it in GitHub Desktop.
Table of ANSI color escape sequence combinations
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/sh | |
for bg in '' $(seq 40 47 | sed 's/^/;/'); do | |
for bold in '' 1; do | |
for fg in '' $(seq 30 37 | sed 's/^/;/'); do | |
code="${bold}${fg}${bg}" | |
code="${code#;}" | |
printf '\033[%sm %7s\033[0m' "${code}" "${code}" | |
done | |
printf '\n' | |
done | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Example: