generated from me/template-mit
Add function to check all the terminal colors of a system.
This commit is contained in:
@@ -825,6 +825,7 @@ alias exec-html="run-site"
|
||||
alias site-host="run-site"
|
||||
alias host-site="run-site"
|
||||
|
||||
# TBD: Move this to a different section?
|
||||
function git-check {
|
||||
dir="`pwd`"
|
||||
if [[ -n "$1" ]]; then
|
||||
@@ -858,6 +859,28 @@ function git-check {
|
||||
echo -e "\nDone!"
|
||||
}
|
||||
|
||||
# TBD: Move this to a different section?
|
||||
function check-colors {
|
||||
min=0
|
||||
max=255
|
||||
unset i
|
||||
for (( i = min; i <= max; i++ )); do
|
||||
tput setaf $i
|
||||
printf "%03d" "$i"
|
||||
tput sgr0
|
||||
if (( i < max )); then
|
||||
printf " "
|
||||
fi
|
||||
done
|
||||
printf "\n"
|
||||
}
|
||||
alias color-check="check-colors"
|
||||
alias show-colors="check-colors"
|
||||
alias test-colors="check-colors"
|
||||
alias colors="check-colors"
|
||||
alias term-colors="check-colors"
|
||||
alias display-colors="check-colors"
|
||||
|
||||
|
||||
## Finalize ##
|
||||
|
||||
|
||||
Reference in New Issue
Block a user