This is a simple loop that displays a rainbow of different colors.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | #!/bin/bash -
#title :colorscale.sh
#description :Show a rainbow of colors.
#author :bgw
#date :20111002
#version :0.1
#usage :./colorscale.sh
#notes :
#bash_version :4.1.5(1)-release
#==============================================================================
for c in {0..255} ; do
echo -e "\e[38;05;${c}m ${c} Bash Prompt Color Chart"
done
|
Use this to trick out you terminal prompt. I ran this on a Debian based system in gnome-terminal. I have not tested it on anything else. This does not work with GNU screen because it see colors differently.