diff options
author | xero <x@xero.nu> | 2014-01-25 20:30:17 -0500 |
---|---|---|
committer | xero <x@xero.nu> | 2014-01-25 20:30:17 -0500 |
commit | 7e892df9b0e32673d5a635aca1ebfb079473a3f2 (patch) | |
tree | 84f1f05399d16bc611db54111dee9ca06b2e683d /fun/colors | |
parent | abb204ed8349b10dc53fc5884c8388c11d23776d (diff) | |
download | dotfiles_ascii-7e892df9b0e32673d5a635aca1ebfb079473a3f2.tar.xz dotfiles_ascii-7e892df9b0e32673d5a635aca1ebfb079473a3f2.zip |
add fun color scripts mostly from http://crunchbang.org/forums/viewtopic.php?id=13645
Diffstat (limited to 'fun/colors')
-rwxr-xr-x | fun/colors | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/fun/colors b/fun/colors new file mode 100755 index 0000000..c8d527b --- /dev/null +++ b/fun/colors @@ -0,0 +1,13 @@ +#!/bin/bash + +xdef="$HOME/.Xdefaults" + +colors=( $( sed -re '/^!/d; /^$/d; /^#/d; s/(\*color)([0-9]):/\10\2:/g;' $xdef | grep 'color[01][0-9]:' | sort | sed 's/^.*: *//g' ) ) + +echo -e "\e[1;37m + Black Red Green Yellow Blue Magenta Cyan White +──────────────────────────────────────────────────────────────────────\e[0m" +for i in {0..7}; do echo -en "\e[$((30+$i))m ${colors[i]} \e[0m"; done +echo +for i in {8..15}; do echo -en "\e[1;$((22+$i))m ${colors[i]} \e[0m"; done +echo -e "\n" |