Add showcolors.bash

This commit is contained in:
Marco Hinz 2013-07-03 17:23:38 +02:00
parent 039f361ff7
commit a268d48655
3 changed files with 15 additions and 3 deletions

1
.gitignore vendored
View File

@ -6,4 +6,5 @@
!README.md
!doc/signify.txt
!plugin/signify.vim
!showcolors.bash
!signify.gif

View File

@ -264,9 +264,9 @@ Personally I use (256 colors terminal):
highlight SignifySignDelete cterm=bold ctermbg=237 ctermfg=167
highlight SignifySignChange cterm=bold ctermbg=237 ctermfg=227
For Unix people there is a small script, showcolors.sh, in the repo that shows
all 256 colors available to the terminal. That makes picking the right numbers
much easier.
For Unix people there is a small script, showcolors.bash, in the repo that
shows all 256 colors available to the terminal. That makes picking the right
numbers much easier.
==============================================================================

11
showcolors.bash Executable file
View File

@ -0,0 +1,11 @@
#!/bin/bash
if ! hash tput 2>/dev/null; then
echo "I cannot find the 'tput' program." \
'You might find it in one of the ncurses packages.' >&2
exit 1
fi
for i in {0..255}; do
tput setab $i && echo -n " $i "
done