Skip to content

Instantly share code, notes, and snippets.

@rcmdnk
Created September 5, 2013 23:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rcmdnk/6457780 to your computer and use it in GitHub Desktop.
Save rcmdnk/6457780 to your computer and use it in GitHub Desktop.
#!/bin/bash
bg=40
if [ "$1" != "" ];then
if [ "$1" = "white" ] || [ "$1" = "w" ];then
bg=47
fi
fi
for i in {0..255}; do
num=`printf "%03d" $i`
printf " \e[${bg};38;05;${i}m${num}\e[m"
if [ $((${i}%16)) -eq 15 ];then
echo
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment