Skip to content

Instantly share code, notes, and snippets.

@larshb
Created October 23, 2018 20:14
Show Gist options
  • Save larshb/51af21197dbbfd432b28eb5431b2b1dc to your computer and use it in GitHub Desktop.
Save larshb/51af21197dbbfd432b28eb5431b2b1dc to your computer and use it in GitHub Desktop.
Visual representation of bash text and background colors
#/bin/bash
# Based on https://askubuntu.com/a/279014
for x in {0..8}; do
for i in {30..37}; do
for a in {40..47}; do
echo -ne "\e[$x;$i;$a""m\\\e[$x;$i;$a""m\e[0;37;40m "
done
echo
done
done
echo ""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment