home/bin/coltest (view raw)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 |
#!/usr/bin/env bash
BLK="\e[30m"
RED="\e[31m"
GRN="\e[32m"
YLW="\e[33m"
BLU="\e[34m"
PUR="\e[35m"
CYN="\e[36m"
WHT="\e[37m"
RST="\e[0m"
# printf '%b\n' " no color "
# printf '%b\n' "${BLK} black ${RST} [black]"
# printf '%b\n' "${RED} red ${RST} [red]"
# printf '%b\n' "${GRN} green ${RST} [green]"
# printf '%b\n' "${YLW} yellow ${RST} [yellow]"
# printf '%b\n' "${BLU} blue ${RST} [blue]"
# printf '%b\n' "${PUR} purple ${RST} [purple]"
# printf '%b\n' "${CYN} cyan ${RST} [cyan]"
# printf '%b\n' "${WHT} white ${RST} [white]"
for (( i=0; i<7; i++ )); do
printf '\033[4%sm \033[m ' "$i"
done
printf '\n'
|