Skip to content

Instantly share code, notes, and snippets.

@akhan3
Created June 26, 2020 16:31
Show Gist options
  • Save akhan3/144e3e37d3f4e7745fcb4bbbd90852df to your computer and use it in GitHub Desktop.
Save akhan3/144e3e37d3f4e7745fcb4bbbd90852df to your computer and use it in GitHub Desktop.
256 colors in terminal
#!/bin/bash
for i in {0..255} ; do
printf "\x1b[38;5;${i}mcolour${i} "
if [ $((i % 24)) -eq 0 ]; then
echo;
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment