mirror of
https://github.com/Mayccoll/Gogh.git
synced 2023-08-10 21:12:46 +03:00
Cleanup code
This commit is contained in:
88
test/test.sh
88
test/test.sh
@ -1,71 +1,31 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
|
||||
# Reset color
|
||||
RS="\e[0m"
|
||||
# Basic Colors
|
||||
BLACK="\e[0;30m"
|
||||
RED="\e[0;31m"
|
||||
GREEN="\e[0;32m"
|
||||
YELLOW="\e[0;33m"
|
||||
BLUE="\e[0;34m"
|
||||
PURPLE="\e[0;35m"
|
||||
CYAN="\e[0;36m"
|
||||
WHITE="\e[0;37m"
|
||||
|
||||
|
||||
function_message_title () {
|
||||
echo ""
|
||||
echo ""
|
||||
echo ""
|
||||
echo ""
|
||||
echo ""
|
||||
echo -e "${CYAN}"
|
||||
echo -e "# | ::::::::::::::::::::::::::::::::::::::::::::: | #"
|
||||
echo -e "# | ${RS} $1 ${CYAN}"
|
||||
echo -e "# | ::::::::::::::::::::::::::::::::::::::::::::: | #"
|
||||
echo -e "${RS}"
|
||||
}
|
||||
|
||||
|
||||
color () {
|
||||
# echo ""
|
||||
#black
|
||||
echo -e "\e[0;30m ███ *** AaBbCs --- ███ \\e[0m ---> Color 01 0;30m"
|
||||
#red
|
||||
echo -e "\e[0;31m ███ *** AaBbCs --- ███ \\e[0m ---> Color 02 0;31m"
|
||||
#green
|
||||
echo -e "\e[0;32m ███ *** AaBbCs --- ███ \\e[0m ---> Color 03 0;32m"
|
||||
#yellow
|
||||
echo -e "\e[0;33m ███ *** AaBbCs --- ███ \\e[0m ---> Color 04 0;33m"
|
||||
#blue
|
||||
echo -e "\e[0;34m ███ *** AaBbCs --- ███ \\e[0m ---> Color 05 0;34m"
|
||||
#purple
|
||||
echo -e "\e[0;35m ███ *** AaBbCs --- ███ \\e[0m ---> Color 06 0;35m"
|
||||
#cyan
|
||||
echo -e "\e[0;36m ███ *** AaBbCs --- ███ \\e[0m ---> Color 07 0;36m"
|
||||
#white
|
||||
echo -e "\e[0;37m ███ *** AaBbCs --- ███ \\e[0m ---> Color 08 0;37m"
|
||||
echo ""
|
||||
#black
|
||||
echo -e "\e[1;30m ███ *** AaBbCs --- ███ \\e[0m ---> Color 09 1;30m"
|
||||
#red
|
||||
echo -e "\e[1;31m ███ *** AaBbCs --- ███ \\e[0m ---> Color 10 1;31m"
|
||||
#green
|
||||
echo -e "\e[1;32m ███ *** AaBbCs --- ███ \\e[0m ---> Color 11 1;32m"
|
||||
#yellow
|
||||
echo -e "\e[1;33m ███ *** AaBbCs --- ███ \\e[0m ---> Color 12 1;33m"
|
||||
#blue
|
||||
echo -e "\e[1;34m ███ *** AaBbCs --- ███ \\e[0m ---> Color 13 1;34m"
|
||||
#purple
|
||||
echo -e "\e[1;35m ███ *** AaBbCs --- ███ \\e[0m ---> Color 14 1;35m"
|
||||
#cyan
|
||||
echo -e "\e[1;36m ███ *** AaBbCs --- ███ \\e[0m ---> Color 15 1;36m"
|
||||
#white
|
||||
echo -e "\e[1;37m ███ *** AaBbCs --- ███ \\e[0m ---> Color 16 1;37m"
|
||||
echo ""
|
||||
echo -e "\e[0;30m█████\\e[0m\e[0;31m█████\\e[0m\e[0;32m█████\\e[0m\e[0;33m█████\\e[0m\e[0;34m█████\\e[0m\e[0;35m█████\\e[0m\e[0;36m█████\\e[0m\e[0;37m█████\\e[0m"
|
||||
echo -e "\e[0m\e[1;30m█████\\e[0m\e[1;31m█████\\e[0m\e[1;32m█████\\e[0m\e[1;33m█████\\e[0m\e[1;34m█████\\e[0m\e[1;35m█████\\e[0m\e[1;36m█████\\e[0m\e[1;37m█████\\e[0m"
|
||||
printf '%s\n' "$(tput setaf 0 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 01 'tput setaf 0'" # black
|
||||
printf '%s\n' "$(tput setaf 1 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 02 'tput setaf 1'" # red
|
||||
printf '%s\n' "$(tput setaf 2 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 03 'tput setaf 2'" # green
|
||||
printf '%s\n' "$(tput setaf 3 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 04 'tput setaf 3'" # yellow
|
||||
printf '%s\n' "$(tput setaf 4 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 05 'tput setaf 4'" # blue
|
||||
printf '%s\n' "$(tput setaf 5 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 06 'tput setaf 5'" # pruple
|
||||
printf '%s\n' "$(tput setaf 6 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 07 'tput setaf 6'" # cyan
|
||||
printf '%s\n\n' "$(tput setaf 7 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 08 'tput setaf 7'" # white
|
||||
printf '%s\n' "$(tput setaf 8 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 09 'tput setaf 8'" # bold black
|
||||
printf '%s\n' "$(tput setaf 9 ) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 10 'tput setaf 9'" # bold red
|
||||
printf '%s\n' "$(tput setaf 10) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 11 'tput setaf 10'" # bold green
|
||||
printf '%s\n' "$(tput setaf 11) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 12 'tput setaf 11'" # bold yellow
|
||||
printf '%s\n' "$(tput setaf 12) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 13 'tput setaf 12'" # bold blue
|
||||
printf '%s\n' "$(tput setaf 13) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 14 'tput setaf 13'" # bold purple
|
||||
printf '%s\n' "$(tput setaf 14) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 15 'tput setaf 14'" # bold cyan
|
||||
printf '%s\n\n' "$(tput setaf 15) ███ *** AaBbCs --- ███ $(tput sgr0) ---> Color 16 'tput setaf 15'" # bold white
|
||||
|
||||
local color_str
|
||||
for c in {0..15}; do
|
||||
color_dot_str+="$(tput setaf $c)•$(tput sgr0)"
|
||||
[[ $c == 7 ]] && color_dot_str+=" "
|
||||
done
|
||||
printf '%s\n' "$color_str"
|
||||
unset color_str
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user