#!/bin/zsh attrs=(none bold dim italic underline blink undefined 'reverse video' invisible strikethrough) colors=(default black red green yellow blue magenta cyan white) for ai in {0..5} {7..9}; do [[ $ai == 0 ]] && a='' || a="$ai;" echo "$ai: $attrs[(($ai+1))]" for fi in {29..37}; do [[ $fi == 29 ]] && f='' || f="$fi;" echo -n ' ' for bi in {39..47}; do [[ $bi == 39 ]] && b='' || b="$bi" echo -ne "\e[$a$f$b""m${(r[7])colors[(($fi-28))]}\e[0m " done echo done done