Skip to content

Instantly share code, notes, and snippets.

@tylerneylon
Created July 26, 2016 06:22
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tylerneylon/a43950ffbc95750b92f4573f70b62808 to your computer and use it in GitHub Desktop.
Save tylerneylon/a43950ffbc95750b92f4573f70b62808 to your computer and use it in GitHub Desktop.
Terminal-based color table
# A bash function to print out a table of
# colors supported by your terminal.
colortable() {
tput setaf 0
for i in $(seq 0 $(tput colors)); do
tput setab $i
printf %4d $i
done
echo
tput sgr0
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment