This commit is contained in:
2025-08-13 21:46:48 +02:00
commit c3e2e6509b
818 changed files with 54187 additions and 0 deletions

2457
local_bin/asciiquarium Executable file

File diff suppressed because it is too large Load Diff

16
local_bin/backupGamesaves Executable file
View File

@@ -0,0 +1,16 @@
#!/bin/bash
notify() {
notify-send "$1" -i ~/.local/share/icons/Catppuccin-SE/64x64@2x/apps/org.gnome.games.svg --app-name=Ludusavi
}
if ! command -v ludusavi &>/dev/null; then
notify "Error: ludusavi is not installed"
exit 1
fi
notify "Started Backup..."
ludusavi backup --force --full-limit 3
notify "Backup Complete"

BIN
local_bin/bonsai Executable file

Binary file not shown.

46
local_bin/color-scripts/alpha Executable file
View File

@@ -0,0 +1,46 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: Ivo
# Source: http://crunchbang.org/forums/viewtopic.php?pid=134749#p134749
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m" whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m" whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${boldon}${redfbright} ██████ ${reset} ${boldon}${greenfbright}██████ ${reset}${boldon}${yellowfbright} ██████${reset} ${boldon}${bluefbright}██████ ${reset} ${boldon}${purplefbright} ██████${reset} ${boldon}${cyanfbright} ███████${reset}
${boldon}${redfbright} ████████${reset} ${boldon}${greenfbright}██ ██ ${reset}${boldon}${yellowfbright}██ ${reset} ${boldon}${bluefbright}██ ██${reset} ${boldon}${purplefbright}██████ ${reset} ${boldon}${cyanfbright}█████████${reset}
${redf} ██ ████${reset} ${greenf}██ ████ ${reset}${yellowf}████ ${reset} ${bluef}████ ██${reset} ${purplef}████ ${reset} ${cyanf}█████ ${reset}
${redf} ██ ██${reset} ${greenf}██████ ${reset}${yellowf}████████${reset} ${bluef}██████ ${reset} ${purplef}████████${reset} ${cyanf}██ ${reset}
EOF

40
local_bin/color-scripts/arch Executable file
View File

@@ -0,0 +1,40 @@
#!/bin/sh
# Author: Ivo
# Source: http://crunchbang.org/forums/viewtopic.php?pid=237794#p237794
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m";
cyanf="${esc}[36m"; purplef="${esc}[35m"
redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m";
cyanfbright="${esc}[96m"; purplefbright="${esc}[95m"
boldon="${esc}[1m";
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${boldon}${redfbright} ■ ${boldon}${greenfbright} ■ ${boldon}${yellowfbright} ■ ${boldon}${bluefbright} ■ ${boldon}${purplefbright} ■ ${boldon}${cyanfbright} ■ ${reset}
${boldon}${redfbright} ■■■ ${boldon}${greenfbright} ■■■ ${boldon}${yellowfbright} ■■■ ${boldon}${bluefbright} ■■■ ${boldon}${purplefbright} ■■■ ${boldon}${cyanfbright} ■■■ ${reset}
${boldon}${redfbright} ■■■■■ ${boldon}${greenfbright} ■■■■■ ${boldon}${yellowfbright} ■■■■■ ${boldon}${bluefbright} ■■■■■ ${boldon}${purplefbright} ■■■■■ ${boldon}${cyanfbright} ■■■■■ ${reset}
${redf} ■( )■ ${greenf} ■( )■ ${yellowf} ■( )■ ${bluef} ■( )■ ${purplef} ■( )■ ${cyanf} ■( )■ ${reset}
${redf} ■■■■ ■■■■ ${greenf} ■■■■ ■■■■ ${yellowf} ■■■■ ■■■■ ${bluef} ■■■■ ■■■■ ${purplef} ■■■■ ■■■■ ${cyanf} ■■■■ ■■■■ ${reset}
${redf} ■■ ■■ ${greenf} ■■ ■■ ${yellowf} ■■ ■■ ${bluef} ■■ ■■ ${purplef} ■■ ■■ ${cyanf} ■■ ■■ ${reset}
EOF

26
local_bin/color-scripts/bars Executable file
View File

@@ -0,0 +1,26 @@
#!/bin/bash
# ANSI color scheme script by pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=139126#p139126
# Initializing mod by lolilolicon from Archlinux
#
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
for i in {0..7}; do
printf -v fbright$i %b "\e[9${i}m"
done
bld=$'\e[1m'
rst=$'\e[0m'
inv=$'\e[7m'
cat << EOF
$f1▬▬▬▬▬ $f2▬▬▬▬▬ $f3▬▬▬▬▬ $f4▬▬▬▬▬ $f5▬▬▬▬▬ $f6▬▬▬▬▬
$bld$fbright1▬▬▬▬▬ $fbright2▬▬▬▬▬ $fbright3▬▬▬▬▬ $fbright4▬▬▬▬▬ $fbright5▬▬▬▬▬ $fbright6▬▬▬▬▬
$rst
EOF

View File

@@ -0,0 +1,16 @@
#!/bin/bash
echo "This should be a smooth gradient"
echo ""
awk 'BEGIN{
s="/\\/\\/\\/\\/\\"; s=s s s s s s s s;
for (colnum = 0; colnum<77; colnum++) {
r = 255-(colnum*255/76);
g = (colnum*510/76);
b = (colnum*255/76);
if (g>255) g = 510-g;
printf "\033[48;2;%d;%d;%dm", r,g,b;
printf "\033[38;2;%d;%d;%dm", 255-r,255-g,255-b;
printf "%s\033[0m", substr(s,colnum+1,1);
}
printf "\n";
}'

View File

@@ -0,0 +1,15 @@
#!/bin/bash
# Author: SuNjACk
# Source: http://crunchbang.org/forums/viewtopic.php?pid=135226#p135226
xdef="${XRESOURCES:-$HOME/.Xresources}"
colors=( $( sed -re '/^!/d; /^$/d; /^#/d; s/(\*color)([0-9]):/\10\2:/g;' $xdef | grep -E 'color[0-9]+:' | sort | sed 's/^.*: *//g' ) )
echo -e "\e[1;97m
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;$((82+$i))m ${colors[i]} \e[0m"; done
echo -e "\n"

View File

@@ -0,0 +1,97 @@
#!/bin/bash
# Tom Hale, 2016. MIT Licence.
# Print out 256 colours, with each number printed in its corresponding colour
# See http://askubuntu.com/questions/821157/print-a-256-color-test-pattern-in-the-terminal/821163#821163
set -eu # Fail on errors or undeclared variables
printable_colours=256
# Return a colour that contrasts with the given colour
# Bash only does integer division, so keep it integral
function contrast_colour {
local r g b luminance
colour="$1"
if (( colour < 16 )); then # Initial 16 ANSI colours
(( colour == 0 )) && printf "15" || printf "0"
return
fi
# Greyscale # rgb_R = rgb_G = rgb_B = (number - 232) * 10 + 8
if (( colour > 231 )); then # Greyscale ramp
(( colour < 244 )) && printf "15" || printf "0"
return
fi
# All other colours:
# 6x6x6 colour cube = 16 + 36*R + 6*G + B # Where RGB are [0..5]
# See http://stackoverflow.com/a/27165165/5353461
# r=$(( (colour-16) / 36 ))
g=$(( ((colour-16) % 36) / 6 ))
# b=$(( (colour-16) % 6 ))
# If luminance is bright, print number in black, white otherwise.
# Green contributes 587/1000 to human perceived luminance - ITU R-REC-BT.601
(( g > 2)) && printf "0" || printf "15"
return
# Uncomment the below for more precise luminance calculations
# # Calculate percieved brightness
# # See https://www.w3.org/TR/AERT#color-contrast
# # and http://www.itu.int/rec/R-REC-BT.601
# # Luminance is in range 0..5000 as each value is 0..5
# luminance=$(( (r * 299) + (g * 587) + (b * 114) ))
# (( $luminance > 2500 )) && printf "0" || printf "15"
}
# Print a coloured block with the number of that colour
function print_colour {
local colour="$1" contrast
contrast=$(contrast_colour "$1")
printf "\e[48;5;%sm" "$colour" # Start block of colour
printf "\e[38;5;%sm%3d" "$contrast" "$colour" # In contrast, print number
printf "\e[0m " # Reset colour
}
# Starting at $1, print a run of $2 colours
function print_run {
local i
for (( i = "$1"; i < "$1" + "$2" && i < printable_colours; i++ )) do
print_colour "$i"
done
printf " "
}
# Print blocks of colours
function print_blocks {
local start="$1" i
local end="$2" # inclusive
local block_cols="$3"
local block_rows="$4"
local blocks_per_line="$5"
local block_length=$((block_cols * block_rows))
# Print sets of blocks
for (( i = start; i <= end; i += (blocks_per_line-1) * block_length )) do
printf "\n" # Space before each set of blocks
# For each block row
for (( row = 0; row < block_rows; row++ )) do
# Print block columns for all blocks on the line
for (( block = 0; block < blocks_per_line; block++ )) do
print_run $(( i + (block * block_length) )) "$block_cols"
done
(( i += block_cols )) # Prepare to print the next row
printf "\n"
done
done
}
print_run 0 16 # The first 16 colours are spread over the whole spectrum
printf "\n"
print_blocks 16 231 6 6 3 # 6x6x6 colour cube between 16 and 231 inclusive
print_blocks 232 255 12 2 1 # Not 50, but 24 Shades of Grey

View File

@@ -0,0 +1,74 @@
#!/bin/sh
#
# ┳━┓┳━┓0┏┓┓┳━┓┏━┓┓ ┳
# ┃┳┛┃━┫┃┃┃┃┃━┃┃ ┃┃┃┃
# ┃┗┛┛ ┃┃┃┗┛┻━┛┛━┛┗┻┛
# ┳━┓┳ ┓┳┏ ┳━┓
# ┃━┛┃ ┃┣┻┓┣━
# ┇ ┗━┛┃ ┛┻━┛
# ┓━┓┳┏ ┳ ┓┳ ┳
# ┗━┓┣┻┓┃ ┃┃ ┃
# ━━┛┇ ┛┗━┛┗━┛┗━┛
#
# the worst color script
# by xero <http://0w.nz>
cat << 'EOF'
 .................
 .syhhso++++++++/++osyyhys+.
 -oddyo+o+++++++++++++++o+oo+osdms:
 :dmyo++oosssssssssssssssooooooo+/+ymm+`
 hmyo++ossyyhhddddddddddddhyyyssss+//+ymd-
 -mho+oosyhhhddmmmmmmmmmmmmmmddhhyyyso+//+hN+
 my+++syhhhhdmmNNNNNNNNNNNNmmmmmdhhyyyyo//+sd:
 hs//+oyhhhhdmNNNNNNNNNNNNNNNNNNmmdhyhhhyo//++y
 s+++shddhhdmmNNNNNNNNNNNNNNNNNNNNmdhhhdhyo/++/
 'hs+shmmmddmNNNNNNNNNNNNNNNNNNNNNmddddddhs+oh/
 shsshdmmmmmNNMMMMMMMMMMMNNNNNNNNmmmmmmdhssdh-
 +ssohdmmmmNNNNNMMMMMMMMNNNNNNmmmmmNNmdhhhs:`
 -+oo++////++sydmNNNNNNNNNNNNNNNNNNNdyyys/--://+//:
 d/+hmNNNmmdddhhhdmNNNNNNNNNNNNNNNmdhyyyhhhddmmNmdyd-
 ++--+ymNMMNNNNNNmmmmNNNNNNNNNNNmdhddmNNMMMMMMNmhyss
 /d+` -+ydmNMMMMMMNNmNMMMMMMMmmmmNNMMMMMNNmh- :sdo
 sNo ` /ohdmNNMMMMNNMMMMMNNNMMMMMNmdyo/ ` hNh
 M+' ``-/oyhmNNMNhNMNhNMMMMNmho/ ` 'MN/
 d+' `-+osydh0w.nzmNNmho: 'mN:
 +o/ ` :oo+:s :+o/-` -dds
 :hdo x `-/ooss:':+ooo: ` 0 :sdm+
 +dNNNh+ :ydmNNm' `sddmyo +hmNmds
 dhNMMNNNNmddhsyhdmmNNNM: NNmNmhyo+oyyyhmNMMNmysd
 ydNNNNNh+/++ohmMMMMNMNh oNNNNNNNmho++++yddhyssy
 `:sNMMMMN' `mNMNNNd/`
XXXXXXXXX y/hMMNm/ .dXb. -hdmdy: ` XXXXXXXXXXX
XXXXXXXX `o+hNNds. -ymNNy- .yhys+/`` XXXXXXXXXX
XXXXXXXX +-+//o/+odMNMMMNdmh++////-/s XXXXXXXXXX
XXXXXXX mhNd -+d/+myo++ysy/hs -mNsdh/ XXXXXXXXXX
XXXXXXXX mhMN+ dMm-/-smy-::dMN/sMMmdo XXXXXXXXXX
XXXXXXXXXX NMy+NMMh oMMMs yMMMyNMMs+ XXXXXXXXXXX
XXXXXXXXXXX dy-hMMm+dMMMdoNMMh ydo XXXXXXXXXXXXX
XXXXXXXXXXXXX  smm 'NMMy dms sm XXXXXXXXXXXXXX
XXXXXXXXXXXXXX XXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
EOF

View File

@@ -0,0 +1,27 @@
#!/bin/bash
# Author: HostGrady
# Font used: https://patorjk.com/software/taag/#p=display&f=Cricket&t=suckless
if [ -x "$(command -v tput)" ]; then
bold="$(tput bold)"
blue="$(tput setaf 4)"
cyan="$(tput setaf 6)"
reset="$(tput sgr0)"
fi
art="${bold}${blue} __ __
.-----.--.--.----| |--| .-----.-----.-----.
|__ --| | | __| <| | -__|__ --|__ --|
|_____|_____|____|__|__|__|_____|_____|_____|
${reset}${cyan} software that sucks less${reset} "
# use this as a base if you want to redo this one
#art=" __ __
#.-----.--.--.----| |--| .-----.-----.-----.
#|__ --| | | __| <| | -__|__ --|__ --|
#|_____|_____|____|__|__|__|_____|_____|_____|
# software that sucks less "
echo "$art"

View File

@@ -0,0 +1,103 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
# ▄█████▄
# █████████
# ████████▀██
# ██████████▄██
# ██▀▀███▀▀████
# ████ █ ██ ███
# █ ████
# █ ▄ ████
# ███▀▀▀▀▀▄▀████
# ██▀▀▀▀▀▀ ███▄
# ▄█▀ █████
# ███ ██████
# ███ ██████
# █▀██ ██████
# █ █ █ ████
# █ █ ██ ███
# ██ ▀ █▀ ████
# ███ ████
# █████ ███ ███
# █▀▀███ █████████
# ▄█ ███ █▀ ████ ▀█
# ▄█▀ ████ █ ▀ █
# █ ████ █ █ ██
# █ ██ █ █ ▀█
# █ █ █ █ █
# █ ███████████ ▄▀
# █▄ █ ▀▀▀▀▀▀▀ █ ▄▀
# ▀▀▀▀▀▄▄▄█▀ ▀▄ █
# ▀▀▀▀
# play with these to change:
tuxbg=${cyanb} # color behind tux
tuxfg=${blackf} # tux line color
# tip: auto update your drawings to see changes real-time
# while true; do (sleep 3s && clear && sh script); done
cat << EOF
${tuxfg}${tuxbg}
▄█████▄
█████████
${whiteb}████████▀██${tuxbg}
${whiteb}██████████▄██${tuxbg}
${whiteb}██▀▀███▀▀████${tuxbg}
${whiteb}████ █ ██ ███${tuxbg}
${yellowb}█ ████${tuxbg}
${yellowb}█ ▄ ████${tuxbg}
${yellowb}███▀▀▀▀▀▄${whiteb}▀████${tuxbg}
${whiteb}██▀▀▀▀▀▀ ███${tuxbg}▄
▄█${whiteb}▀ █████${tuxbg}
${whiteb}███ ██████${tuxbg}
${whiteb}███ ██████${tuxbg}
${whiteb}█▀██ ██████${tuxbg}
${whiteb}█ █ █ ████${tuxbg}
${whiteb}█ █ ██ ███${tuxbg}
${whiteb}██ ▀ █▀ ████${tuxbg}
${whiteb}███ ████${tuxbg}
${whiteb}█████ ███ ███${tuxbg}
${yellowb}█▀▀███${whiteb} █████████${tuxbg}
▄${yellowb}█ ███${whiteb} █${yellowb}▀ ████ ▀█${tuxbg}
▄█${yellowb}▀ ████${whiteb} █${yellowb} ▀ █${tuxbg}
█${yellowb} ████${whiteb} █ █${yellowb} ██${tuxbg}
█${yellowb} ██${whiteb} █ █${yellowb} ▀█${tuxbg}
█${yellowb} █${whiteb} █ █${yellowb} █${tuxbg}
█${yellowb} ███████████${yellowb} ▄${tuxbg}▀
█${yellowb}▄ █${tuxbg} ▀▀▀▀▀▀▀ █${yellowb} ▄${tuxbg}▀
▀▀▀▀▀${yellowb}▄▄▄█${tuxbg}▀ ▀${yellowb}▄ █${tuxbg}
▀▀▀▀${tuxbg}
${reset}
EOF

View File

@@ -0,0 +1,64 @@
#!/bin/sh
# Author: Ivo
# Source: http://crunchbang.org/forums/viewtopic.php?pid=237794#p237794
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m";
cyanf="${esc}[36m"; purplef="${esc}[35m"
redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m";
cyanfbright="${esc}[96m"; purplefbright="${esc}[95m"
boldon="${esc}[1m";
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓
░▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░
░▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░
░▓▓▓▓▓▓▓▓▓▓▓▒▒▒▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒▒▒▒
░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▒▒▒▓▓▓▓▓▓▓▓▓▓▓▓▓░░░▒▒▒▒▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒ ▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▒ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▒ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓░▓▓▓▒▒▒▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒▒▒▒ ▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒
▓▓▓▓▓▓▓▓▓▓▓▓▒ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
░░░░▓▓▓▓▓▓▓▓▓▓▓▓▒ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░░░░▒▒▒▒▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓▓▓▓▓▓▓▓▓░
░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓▓▓▓▓▓▓▓▓░
░▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░ ░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
░▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░ ░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓░░░░ ░░░░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▒
▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒ ▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒ ▒▒▒▒▒▒▒▒▒▒▒▒▓
EOF

View File

@@ -0,0 +1,5 @@
#!/bin/bash
pcs() { for i in {0..7}; do echo -en "\e[${1}$((30+$i))m \u2588\u2588 \e[0m"; done; }
pcsbright() { for i in {0..7}; do echo -en "\e[${1}$((90+$i))m \u2588\u2588 \e[0m"; done; }
printf "\n%s\n%s\n\n" "$(pcs)" "$(pcsbright '1;')"

54
local_bin/color-scripts/blocks2 Executable file
View File

@@ -0,0 +1,54 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: ed209
# Source: http://crunchbang.org/forums/viewtopic.php?pid=295676#p295676
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one. ■ ■ ▓ ■ ■ ■ ■ ■
initializeANSI
cat << EOF
${redf}■■■■${reset}${boldon}${redfbright}■■${reset} ${greenf}■■■■${reset}${boldon}${greenfbright}■■${reset} ${yellowf}■■■■${reset}${boldon}${yellowfbright}■■${reset} ${bluef}■■■■${reset}${boldon}${purplefbright}■■${reset} ${purplef}■■■■${reset}${boldon}${bluefbright}■■${reset} ${cyanf}■■■■${reset}${boldon}${cyanfbright}■■${reset}
${redf}■■${reset}${boldon}${greenfbright}■■${reset}${boldon}${redfbright}■■${reset} ${greenf}■■${reset}${boldon}${yellowfbright}■■${reset}${boldon}${greenfbright}■■${reset} ${yellowf}■■${reset}${boldon}${bluefbright}■■${reset}${boldon}${yellowfbright}■■${reset} ${bluef}■■${reset}${purplef}■■${reset}${boldon}${purplefbright}■■${reset} ${purplef}■■${reset}${boldon}${cyanfbright}■■${reset}${boldon}${bluefbright}■■${reset} ${cyanf}■■${reset}${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}
${greenf}■■${reset}${boldon}${greenfbright}■■${reset}${boldon}${redfbright}■■${reset} ${yellowf}■■${reset}${boldon}${yellowfbright}■■${reset}${boldon}${greenfbright}■■${reset} ${bluef}■■${reset}${boldon}${bluefbright}■■${reset}${boldon}${yellowfbright}■■${reset} ${boldon}${cyanfbright}■■${reset}${purplef}■■${reset}${boldon}${purplefbright}■■${reset} ${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}${boldon}${bluefbright}■■${reset} ${bluef}■■${reset}${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}
${greenf}■■${reset}${boldon}${greenfbright}■■${reset}${boldon}${redfbright}■■${reset} ${yellowf}■■${reset}${boldon}${yellowfbright}■■${reset}${boldon}${greenfbright}■■${reset} ${bluef}■■${reset}${boldon}${bluefbright}■■${reset}${boldon}${yellowfbright}■■${reset} ${boldon}${cyanfbright}■■${reset}${purplef}■■${reset}${boldon}${purplefbright}■■${reset} ${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}${boldon}${bluefbright}■■${reset} ${bluef}■■${reset}${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}
${redf}■■■■${reset}${boldon}${redfbright}■■${reset} ${greenf}■■■■${reset}${boldon}${greenfbright}■■${reset} ${yellowf}■■■■${reset}${boldon}${yellowfbright}■■${reset} ${bluef}■■■■${reset}${boldon}${purplefbright}■■${reset} ${purplef}■■■■${reset}${boldon}${bluefbright}■■${reset} ${cyanf}■■■■${reset}${boldon}${cyanfbright}■■${reset}
${redf}■■${reset}${boldon}${greenfbright}■■${reset}${boldon}${redfbright}■■${reset} ${greenf}■■${reset}${boldon}${yellowfbright}■■${reset}${boldon}${greenfbright}■■${reset} ${yellowf}■■${reset}${boldon}${bluefbright}■■${reset}${boldon}${yellowfbright}■■${reset} ${bluef}■■${reset}${purplef}■■${reset}${boldon}${purplefbright}■■${reset} ${purplef}■■${reset}${boldon}${cyanfbright}■■${reset}${boldon}${bluefbright}■■${reset} ${cyanf}■■${reset}${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}
${greenf}■■${reset}${boldon}${greenfbright}■■${reset}${boldon}${redfbright}■■${reset} ${yellowf}■■${reset}${boldon}${yellowfbright}■■${reset}${boldon}${greenf}■■${reset} ${bluef}■■${reset}${boldon}${bluef}■■${reset}${boldon}${yellowf}■■${reset} ${boldon}${cyanf}■■${reset}${purplef}■■${reset}${boldon}${purplef}■■${reset} ${boldon}${purplef}■■${reset}${boldon}${cyanf}■■${reset}${boldon}${bluef}■■${reset} ${bluef}■■${reset}${boldon}${purplef}■■${reset}${boldon}${cyanf}■■${reset}
${greenf}■■${reset}${boldon}${greenfbright}■■${reset}${boldon}${redfbright}■■${reset} ${yellowf}■■${reset}${boldon}${yellowfbright}■■${reset}${boldon}${greenfbright}■■${reset} ${bluef}■■${reset}${boldon}${bluefbright}■■${reset}${boldon}${yellowfbright}■■${reset} ${boldon}${cyanfbright}■■${reset}${purplef}■■${reset}${boldon}${purplefbright}■■${reset} ${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}${boldon}${bluefbright}■■${reset} ${bluef}■■${reset}${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}
${redf}■■■■${reset}${boldon}${redfbright}■■${reset} ${greenf}■■■■${reset}${boldon}${greenfbright}■■${reset} ${yellowf}■■■■${reset}${boldon}${yellowfbright}■■${reset} ${bluef}■■■■${reset}${boldon}${purplefbright}■■${reset} ${purplef}■■■■${reset}${boldon}${bluefbright}■■${reset} ${cyanf}■■■■${reset}${boldon}${cyanfbright}■■${reset}
${redf}■■${reset}${boldon}${greenfbright}■■${reset}${boldon}${redfbright}■■${reset} ${greenf}■■${reset}${boldon}${yellowfbright}■■${reset}${boldon}${greenfbright}■■${reset} ${yellowf}■■${reset}${boldon}${bluefbright}■■${reset}${boldon}${yellowfbright}■■${reset} ${bluef}■■${reset}${purplef}■■${reset}${boldon}${purplefbright}■■${reset} ${purplef}■■${reset}${boldon}${cyanfbright}■■${reset}${boldon}${bluefbright}■■${reset} ${cyanf}■■${reset}${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}
${greenf}■■${reset}${boldon}${greenfbright}■■${reset}${boldon}${redfbright}■■${reset} ${yellowf}■■${reset}${boldon}${yellowfbright}■■${reset}${boldon}${greenfbright}■■${reset} ${bluef}■■${reset}${boldon}${bluefbright}■■${reset}${boldon}${yellowfbright}■■${reset} ${boldon}${cyanfbright}■■${reset}${purplef}■■${reset}${boldon}${purplefbright}■■${reset} ${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}${boldon}${bluefbright}■■${reset} ${bluef}■■${reset}${boldon}${purplefbright}■■${reset}${boldon}${cyanfbright}■■${reset}
${greenf}■■${reset}${boldon}${greenf}■■${reset}${boldon}${redf}■■${reset} ${yellowf}■■${reset}${boldon}${yellowf}■■${reset}${boldon}${greenf}■■${reset} ${bluef}■■${reset}${boldon}${bluef}■■${reset}${boldon}${yellowf}■■${reset} ${boldon}${cyanf}■■${reset}${purplef}■■${reset}${boldon}${purplef}■■${reset} ${boldon}${purplef}■■${reset}${boldon}${cyanf}■■${reset}${boldon}${bluef}■■${reset} ${bluef}■■${reset}${boldon}${purplef}■■${reset}${boldon}${cyanf}■■${reset}
EOF

63
local_bin/color-scripts/bloks Executable file
View File

@@ -0,0 +1,63 @@
#!/bin/bash
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackb="${esc}[1;90m"; redb="${esc}[1;91m"; greenb="${esc}[1;92m"
yellowb="${esc}[1;93m" blueb="${esc}[1;94m"; purpleb="${esc}[1;95m"
cyanb="${esc}[1;96m"; whiteb="${esc}[1;97m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
numbers (){
initializeANSI
cat << EOF
${blackf}11111111${reset} ${redf}22222222${reset} ${greenf}33333333${reset} ${yellowf}44444444${reset} ${bluef}55555555${reset} ${purplef}66666666${reset} ${cyanf}77777777${reset} ${whitef}88888888${reset}
${blackb}11111111${reset} ${redb}22222222${reset} ${greenb}33333333${reset} ${yellowb}44444444${reset} ${blueb}55555555${reset} ${purpleb}66666666${reset} ${cyanb}77777777${reset} ${whiteb}88888888${reset}
EOF
}
blocks (){
initializeANSI
cat << EOF
${blackf}████${reset}${blackb}████${reset} ${redf}████${reset}${redb}████${reset} ${greenf}████${reset}${greenb}████${reset} ${yellowf}████${reset}${yellowb}████${reset} ${bluef}████${reset}${blueb}████${reset} ${purplef}████${reset}${purpleb}████${reset} ${cyanf}████${reset}${cyanb}████${reset} ${whitef}████${reset}${whiteb}████${reset}
${blackf}████${reset}${blackb}████${reset} ${redf}████${reset}${redb}████${reset} ${greenf}████${reset}${greenb}████${reset} ${yellowf}████${reset}${yellowb}████${reset} ${bluef}████${reset}${blueb}████${reset} ${purplef}████${reset}${purpleb}████${reset} ${cyanf}████${reset}${cyanb}████${reset} ${whitef}████${reset}${whiteb}████${reset}
${blackf}████${reset}${blackb}████${reset} ${redf}████${reset}${redb}████${reset} ${greenf}████${reset}${greenb}████${reset} ${yellowf}████${reset}${yellowb}████${reset} ${bluef}████${reset}${blueb}████${reset} ${purplef}████${reset}${purpleb}████${reset} ${cyanf}████${reset}${cyanb}████${reset} ${whitef}████${reset}${whiteb}████${reset}
EOF
}
case $1 in
b) blocks;;
n) numbers;;
a) blocks && numbers;;
*) blocks && numbers;;
esac

View File

@@ -0,0 +1,38 @@
#!/bin/sh
#
# colorbars - smpte color bars in sh
# http://git.io/colorbars
echo
for y in $(seq 0 13); do
printf %s ' '
for color in 7 3 6 2 5 1 4; do
tput setab ${color}
printf %s ' '
done
tput sgr0
echo
done
for y in 0 1; do
printf %s ' '
for color in 4 0 5 0 6 0 7; do
tput setab ${color}
printf %s ' '
done
tput sgr0
echo
done
for y in $(seq 0 4); do
printf %s ' '
for color in 4 4 4 4 4 7 7 7 7 7 5 5 5 5 5 0 0 0 0 0 0 0 0 0 0 0 0 0; do
tput setab ${color}
printf %s ' '
done
tput sgr0
echo
done
echo

View File

@@ -0,0 +1,30 @@
#!/bin/bash
# Daniel Crisman's ANSI color chart script from
# The Bash Prompt HOWTO: 6.1. Colours
# http://www.tldp.org/HOWTO/Bash-Prompt-HOWTO/x329.html
#
# This function echoes a bunch of color codes to the
# terminal to demonstrate what's available. Each
# line is the color code of one forground color,
# out of 17 (default + 16 escapes), followed by a
# test use of that color on all nine background
# colors (default + 8 escapes).
T='•••' # The text for the color test
echo -e "\n def 40m 41m 42m 43m 44m 45m 46m 47m";
for FGs in ' m' ' 1m' ' 30m' '1;90m' ' 31m' '1;91m' ' 32m' \
'1;92m' ' 33m' '1;93m' ' 34m' '1;94m' ' 35m' '1;95m' \
' 36m' '1;96m' ' 37m' '1;97m';
do FG=${FGs// /}
echo -en " $FGs \033[$FG $T "
for BG in 40m 41m 42m 43m 44m 45m 46m 47m;
do echo -en "$EINS \033[$FG\033[$BG $T \033[0m";
done
echo;
done
echo

View File

@@ -0,0 +1,21 @@
#!/bin/bash
# Author: machinebacon
# Source: http://linuxbbq.org/bbs/viewtopic.php?f=4&t=1656#p33237
T='*' # The test text
echo -e "\n 40m 41m 42m 43m\
44m 45m 46m 47m";
for FGs in ' m' ' 1m' ' 30m' '1;90m' ' 31m' '1;91m' ' 32m' \
'1;92m' ' 33m' '1;93m' ' 34m' '1;94m' ' 35m' '1;95m' \
' 36m' '1;96m' ' 37m' '1;97m';
do FG=${FGs// /}
echo -en " $FGs \033[$FG $T "
for BG in 40m 41m 42m 43m 44m 45m 46m 47m;
do echo -en "$EINS \033[$FG\033[$BG $T \033[0m";
done
echo;
done
echo

View File

@@ -0,0 +1,34 @@
#!/bin/bash
# Original: http://frexx.de/xterm-256-notes/
# http://frexx.de/xterm-256-notes/data/colortable16.sh
# Modified by Aaron Griffin
# and further by Kazuo Teramoto
FGNAMES=(' black ' ' red ' ' green ' ' yellow' ' blue ' 'magenta' ' cyan ' ' white ')
BGNAMES=('DFT' 'BLK' 'RED' 'GRN' 'YEL' 'BLU' 'MAG' 'CYN' 'WHT')
echo " ┌──────────────────────────────────────────────────────────────────────────┐"
for b in {0..8}; do
((b>0)) && bg=$((b+39))
echo -en "\033[0m ${BGNAMES[b]} │ "
for f in {0..7}; do
echo -en "\033[${bg}m\033[$((f+30))m ${FGNAMES[f]} "
done
echo -en "\033[0m │"
echo -en "\033[0m\n\033[0m │ "
for f in {0..7}; do
echo -en "\033[${bg}m\033[1;$((f+90))m ${FGNAMES[f]} "
done
echo -en "\033[0m │"
echo -e "\033[0m"
((b<8)) &&
echo " ├──────────────────────────────────────────────────────────────────────────┤"
done
echo " └──────────────────────────────────────────────────────────────────────────┘"

View File

@@ -0,0 +1,13 @@
#!/bin/sh
# Author: baskerville
# Source: http://crunchbang.org/forums/viewtopic.php?pid=288344#p288344
printf "\033[0m
\033[49;35m|\033[49;31m|\033[101;31m|\033[41;97m|\033[49;91m|\033[49;93m|\033[0m
\033[105;35m|\033[45;97m|\033[49;97m||\033[100;97m||\033[49;37m||\033[103;33m|\033[43;97m|\033[0m
\033[49;95m|\033[49;94m|\033[100;37m||\033[40;97m||\033[40;37m||\033[49;33m|\033[49;32m|\033[0m
\033[104;34m|\033[44;97m|\033[49;90m||\033[40;39m||\033[49;39m||\033[102;32m|\033[42;97m|\033[0m
\033[49;34m|\033[49;36m|\033[106;36m|\033[46;97m|\033[49;96m|\033[49;92m|\033[0m
"

19
local_bin/color-scripts/crowns Executable file
View File

@@ -0,0 +1,19 @@
#!/bin/bash
# Author: venam
cat <<EOF
            
                                
            
                                                        
                                                
                                                
                                                        
                    
                    
 
 
EOF

47
local_bin/color-scripts/crunch Executable file
View File

@@ -0,0 +1,47 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: gutterslob
# Source: http://crunchbang.org/forums/viewtopic.php?pid=148022#p148022
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbrightbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${reset}${redf} ██ ██ ${reset}${greenf} ██ ██ ${reset}${yellowf} ██ ██ ${reset}${bluef} ██ ██ ${reset}${purplef} ██ ██ ${reset}${cyanf} ██ ██ ${reset}
${reset}${redf}██████████ ${reset}${greenf} ██████████ ${reset}${yellowf} ██████████ ${reset}${bluef} ██████████ ${reset}${purplef} ██████████ ${reset} ${cyanf}██████████ ${reset}
${reset}${redf} ██${boldon}${redfbright}██${boldoff}${redf}██ ${reset}${greenf} ██${boldon}${greenfbright}██${boldoff}${greenf}██ ${reset}${yellowf} ██${boldon}${yellowfbright}██${boldoff}${yellowf}██ ${reset}${bluef} ██${boldon}${bluefbright}██${boldoff}${bluef}██ ${reset}${purplef} ██${boldon}${purplefbright}██${boldoff}${purplef}██ ${reset}${cyanf} ██${boldon}${cyanfbright}██${boldoff}${cyanf}██ ${reset}
${reset}${redf}██████████ ${reset}${greenf} ██████████ ${reset}${yellowf} ██████████ ${bluef} ██████████ ${purplef} ██████████ ${reset}${cyanf} ██████████${reset}
${reset}${redf} ██ ██ ${reset}${greenf} ██ ██ ${reset}${yellowf} ██ ██ ${reset}${bluef} ██ ██ ${reset}${purplef} ██ ██ ${reset}${cyanf} ██ ██ ${reset}
${reset}
EOF

View File

@@ -0,0 +1,46 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: steampunknyanja
# Source: http://crunchbang.org/forums/viewtopic.php?pid=146715#p146715
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${reset}${redf} ██ ██ ${reset}${boldon}${redfbright}██ ${reset}${greenf} ██ ██ ${reset}${boldon}${greenfbright}██ ${reset}${yellowf} ██ ██ ${reset}${boldon}${yellowfbright}██ ${reset}${bluef} ██ ██ ${reset}${boldon}${bluefbright}██ ${reset}${purplef} ██ ██ ${reset}${boldon}${purplefbright}██ ${reset}${cyanf} ██ ██ ${reset}${boldon}${cyanfbright}██
${reset}${redf}██████████ ${reset}${boldon}${redfbright}██ ${reset}${greenf}██████████ ${reset}${boldon}${greenfbright}██ ${reset}${yellowf}██████████ ${reset}${boldon}${yellowfbright}██ ${reset}${bluef}██████████ ${reset}${boldon}${bluefbright}██ ${reset}${purplef}██████████ ${reset}${boldon}${purplefbright}██ ${reset}${cyanf}██████████ ${reset}${boldon}${cyanfbright}██
${reset}${redf} ██ ██ ${reset}${boldon}${redfbright}██ ${reset}${greenf} ██ ██ ${reset}${boldon}${greenfbright}██ ${reset}${yellowf} ██ ██ ${reset}${boldon}${yellowfbright}██ ${reset}${bluef} ██ ██ ${reset}${boldon}${bluefbright}██ ${reset}${purplef} ██ ██ ${reset}${boldon}${purplefbright}██ ${reset}${cyanf} ██ ██ ${reset}${boldon}${cyanfbright}██
${reset}${redf}██████████ ${reset}${greenf}██████████ ${reset}${yellowf}██████████ ${reset}${bluef}██████████ ${reset}${purplef}██████████ ${reset}${cyanf}██████████
${reset}${redf} ██ ██ ${reset}${boldon}${redfbright}██ ${reset}${greenf} ██ ██ ${reset}${boldon}${greenfbright}██ ${reset}${yellowf} ██ ██ ${reset}${boldon}${yellowfbright}██ ${reset}${bluef} ██ ██ ${reset}${boldon}${bluefbright}██ ${reset}${purplef} ██ ██ ${reset}${boldon}${purplefbright}██ ${reset}${cyanf} ██ ██ ${reset}${boldon}${cyanfbright}██
${reset}
EOF

View File

@@ -0,0 +1,44 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: thevdude
# Source: http://crunchbang.org/forums/viewtopic.php?pid=147530#p147530
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${reset}${redf}▄█▄█▄ ${reset}${boldon}${redfbright}█ ${reset}${greenf}▄█▄█▄ ${reset}${boldon}${greenfbright}█ ${reset}${yellowf}▄█▄█▄ ${reset}${boldon}${yellowfbright}█ ${reset}${bluef}▄█▄█▄ ${reset}${boldon}${bluefbright}█ ${reset}${purplef}▄█▄█▄ ${reset}${boldon}${purplefbright}█ ${reset}${cyanf}▄█▄█▄ ${reset}${boldon}${cyanfbright}█${reset}
${reset}${redf}▄█▄█▄ ${reset}${boldon}${redfbright}▀ ${reset}${greenf}▄█▄█▄ ${reset}${boldon}${greenfbright}▀ ${reset}${yellowf}▄█▄█▄ ${reset}${boldon}${yellowfbright}▀ ${reset}${bluef}▄█▄█▄ ${reset}${boldon}${bluefbright}▀ ${reset}${purplef}▄█▄█▄ ${reset}${boldon}${purplefbright}▀ ${reset}${cyanf}▄█▄█▄ ${reset}${boldon}${cyanfbright}▀${reset}
${reset}${redf} ▀ ▀ ${reset}${boldon}${redfbright}▀ ${reset}${greenf} ▀ ▀ ${reset}${boldon}${greenfbright}▀ ${reset}${yellowf} ▀ ▀ ${reset}${boldon}${yellowfbright}▀ ${reset}${bluef} ▀ ▀ ${reset}${boldon}${bluefbright}▀ ${reset}${purplef} ▀ ▀ ${reset}${boldon}${purplefbright}▀ ${reset}${cyanf} ▀ ▀ ${reset}${boldon}${cyanfbright}▀${reset}
EOF

View File

@@ -0,0 +1,56 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=129265#p129265
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
# ****************************** Building blocks: █ ▓ ▒ ░ ▄ ▀ ▐ ▌ ● ═ ║ ╔ ╦ ╗ ╚ ╩ ╝ ■ ▬ ▲ ▼ ◄ ►
initializeANSI
cat << EOF
${redf} ▄████▄ ${greenf} ▄████▄ ${yellowf} ▄████▄ ${bluef} ▄████▄ ${purplef} ▄████▄ ${cyanf} ▄████▄
${redf} ██▀▀▀▀██ ${greenf} ██▀▀▀▀██ ${yellowf} ██▀▀▀▀██ ${bluef} ██▀▀▀▀██ ${purplef} ██▀▀▀▀██ ${cyanf} ██▀▀▀▀██
${redf} █ █ ${greenf} █ █ ${yellowf} █ █ ${bluef} █ █ ${purplef} █ █ ${cyanf} █ █
${redf} █ ▄▀▀▄ █ ${greenf} █ ▄▀▀▄ █ ${yellowf} █ ▄▀▀▄ █ ${bluef} █ ▄▀▀▄ █ ${purplef} █ ▄▀▀▄ █ ${cyanf} █ ▄▀▀▄ █
${redf} █ ▄█▬▄▄▬█▄ █ ${greenf}█ ▄█▬▄▄▬█▄ █ ${yellowf}█ ▄█▬▄▄▬█▄ █ ${bluef}█ ▄█▬▄▄▬█▄ █ ${purplef}█ ▄█▬▄▄▬█▄ █ ${cyanf}█ ▄█▬▄▄▬█▄ █
${boldon}
${redfbright} ▄████▄ ${greenfbright} ▄████▄ ${yellowfbright} ▄████▄ ${bluefbright} ▄████▄ ${purplefbright} ▄████▄ ${cyanfbright} ▄████▄
${redfbright} ██▀▀▀▀██ ${greenfbright} ██▀▀▀▀██ ${yellowfbright} ██▀▀▀▀██ ${bluefbright} ██▀▀▀▀██ ${purplefbright} ██▀▀▀▀██ ${cyanfbright} ██▀▀▀▀██
${redfbright} █ █ ${greenfbright} █ █ ${yellowfbright} █ █ ${bluefbright} █ █ ${purplefbright} █ █ ${cyanfbright} █ █
${redfbright} █ ▄▀▀▄ █ ${greenfbright} █ ▄▀▀▄ █ ${yellowfbright} █ ▄▀▀▄ █ ${bluefbright} █ ▄▀▀▄ █ ${purplefbright} █ ▄▀▀▄ █ ${cyanfbright} █ ▄▀▀▄ █
${redfbright} █ ▄█▬▄▄▬█▄ █ ${greenfbright}█ ▄█▬▄▄▬█▄ █ ${yellowfbright}█ ▄█▬▄▄▬█▄ █ ${bluefbright}█ ▄█▬▄▄▬█▄ █ ${purplefbright}█ ▄█▬▄▄▬█▄ █ ${cyanfbright}█ ▄█▬▄▄▬█▄ █
${reset}
EOF

39
local_bin/color-scripts/debian Executable file
View File

@@ -0,0 +1,39 @@
#!/bin/sh
# Based on ufetch-debian
# https://gitlab.com/jschx/ufetch/-/blob/master/ufetch-debian
if [ -x "$(command -v tput)" ]; then
bold="$(tput bold)"
black="$(tput setaf 0)"
red="$(tput setaf 1)"
green="$(tput setaf 2)"
yellow="$(tput setaf 3)"
blue="$(tput setaf 4)"
magenta="$(tput setaf 5)"
cyan="$(tput setaf 6)"
white="$(tput setaf 7)"
reset="$(tput sgr0)"
fi
# you can change these
ic="${reset}" # info
c0="${reset}${red}"
c1="${reset}${green}"
c2="${reset}${yellow}"
c3="${reset}${blue}"
c4="${reset}${magenta}"
c5="${reset}${cyan}"
## OUTPUT
cat <<EOF
${c0} ,---._ ${c1} ,---._ ${c2} ,---._ ${c3} ,---._ ${c4} ,---._ ${c5} ,---._
${c0} /\` __ \\ ${c1} /\` __ \\ ${c2} /\` __ \\ ${c3} /\` __ \\ ${c4} /\` __ \\ ${c5} /\` __ \\
${c0} | / | ${c1} | / | ${c2} | / | ${c3} | / | ${c4} | / | ${c5} | / |
${c0} | \`.__.\` ${c1} | \`.__.\` ${c2} | \`.__.\` ${c3} | \`.__.\` ${c4} | \`.__.\` ${c5} | \`.__.\`
${c0} \ ${c1} \ ${c2} \ ${c3} \ ${c4} \ ${c5} \
${c0} \`-,_ ${c1} \`-,_ ${c2} \`-,_ ${c3} \`-,_ ${c4} \`-,_ ${c5} \`-,_
${ic}
EOF

48
local_bin/color-scripts/dna Executable file
View File

@@ -0,0 +1,48 @@
#!/bin/bash
# ANSI color scheme script by pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=144011#p144011
# Initializing mod by lolilolicon from Archlinux
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
for i in {0..7}; do
printf -v fbright$i %b "\e[9${i}m"
done
bld=$'\e[1m'
rst=$'\e[0m'
inv=$'\e[7m'
cat << EOF
$f1█-----$bld$fbright1█ $rst$f2█-----$bld$fbright2█$rst $f3█-----$bld$fbright3█$rst $f4█-----$bld$fbright4█$rst $f5█-----$bld$fbright5█$rst $f6█-----$bld$fbright6█$rst
$f1█---$bld$fbright1█$rst $f2█---$bld$fbright2█$rst $f3█---$bld$fbright3█$rst $f4█---$bld$fbright4█$rst $f5█---$bld$fbright5█$rst $f6█---$bld$fbright6█$rst
$f1 █-$bld$fbright1█$rst $f2 █-$bld$fbright2█$rst $f3 █-$bld$fbright3█$rst $f4 █-$bld$fbright4█$rst $f5 █-$bld$fbright5█$rst $f6 █-$bld$fbright6█$rst
$f1█$rst $f2█$rst $f3█$rst $f4█$rst $f5█$rst $f6█$rst
$f1$bld$fbright1█-$rst$f1█$rst $f2$bld$fbright2█_$rst$f2█$rst $f3$bld$fbright3█-$rst$f3█$rst $f4$bld$fbright4█-$rst$f4█$rst $f5$bld$fbright5█-$rst$f5█$rst $f6$bld$fbright6█-$rst$f6█$rst
$f1$bld$fbright1█---$rst$f1█$rst $f2$bld$fbright2█---$rst$f2█$rst $f3$bld$fbright3█---$rst$f3█$rst $f4$bld$fbright4█---$rst$f4█$rst $f5$bld$fbright5█---$rst$f5█$rst $f6$bld$fbright6█---$rst$f6█$rst
$f1$bld$fbright1█-----$rst$f1█$rst $f2$bld$fbright2█-----$rst$f2█$rst $f3$bld$fbright3█-----$rst$f3█$rst $f4$bld$fbright4█-----$rst$f4█$rst $f5$bld$fbright5█-----$rst$f5█$rst $f6$bld$fbright6█-----$rst$f6█$rst
$f1$bld$fbright1█---$rst$f1█$rst $f2$bld$fbright2█---$rst$f2█$rst $f3$bld$fbright3█---$rst$f3█$rst $f4$bld$fbright4█---$rst$f4█$rst $f5$bld$fbright5█---$rst$f5█$rst $f6$bld$fbright6█---$rst$f6█$rst
$f1$bld$fbright1█-$rst$f1█$rst $f2$bld$fbright2█-$rst$f2█$rst $f3$bld$fbright3█-$rst$f3█$rst $f4$bld$fbright4█-$rst$f4█$rst $f5$bld$fbright5█-$rst$f5█$rst $f6$bld$fbright6█-$rst$f6█$rst
$f1$bld$fbright1█$rst $f2$bld$fbright2█$rst $f3$bld$fbright3█$rst $f4$bld$fbright4█$rst $f5$bld$fbright5█$rst $f6$bld$fbright6█$rst
$f1█-$bld$fbright1█$rst $f2█-$bld$fbright2█$rst $f3█-$bld$fbright3█$rst $f4█-$bld$fbright4█$rst $f5█-$bld$fbright5█$rst $f6█-$bld$fbright6█$rst
$f1█---$bld$fbright1█$rst $f2█---$bld$fbright2█$rst $f3█---$bld$fbright3█$rst $f4█---$bld$fbright4█$rst $f5█---$bld$fbright5█$rst $f6█---$bld$fbright6█$rst
$f1█-----$bld$fbright1█ $rst$f2█-----$bld$fbright2█$rst $f3█-----$bld$fbright3█$rst $f4█-----$bld$fbright4█$rst $f5█-----$bld$fbright5█$rst $f6█-----$bld$fbright6█$rst
$f1█---$bld$fbright1█$rst $f2█---$bld$fbright2█$rst $f3█---$bld$fbright3█$rst $f4█---$bld$fbright4█$rst $f5█---$bld$fbright5█$rst $f6█---$bld$fbright6█$rst
$f1 █-$bld$fbright1█$rst $f2 █-$bld$fbright2█$rst $f3 █-$bld$fbright3█$rst $f4 █-$bld$fbright4█$rst $f5 █-$bld$fbright5█$rst $f6 █-$bld$fbright6█$rst
$f1█$rst $f2█$rst $f3█$rst $f4█$rst $f5█$rst $f6█$rst
$f1$bld$fbright1█-$rst$f1█$rst $f2$bld$fbright2█_$rst$f2█$rst $f3$bld$fbright3█-$rst$f3█$rst $f4$bld$fbright4█-$rst$f4█$rst $f5$bld$fbright5█-$rst$f5█$rst $f6$bld$fbright6█-$rst$f6█$rst
$f1$bld$fbright1█---$rst$f1█$rst $f2$bld$fbright2█---$rst$f2█$rst $f3$bld$fbright3█---$rst$f3█$rst $f4$bld$fbright4█---$rst$f4█$rst $f5$bld$fbright5█---$rst$f5█$rst $f6$bld$fbright6█---$rst$f6█$rst
$f1$bld$fbright1█-----$rst$f1█$rst $f2$bld$fbright2█-----$rst$f2█$rst $f3$bld$fbright3█-----$rst$f3█$rst $f4$bld$fbright4█-----$rst$f4█$rst $f5$bld$fbright5█-----$rst$f5█$rst $f6$bld$fbright6█-----$rst$f6█$rst
$f1$bld$fbright1█---$rst$f1█$rst $f2$bld$fbright2█---$rst$f2█$rst $f3$bld$fbright3█---$rst$f3█$rst $f4$bld$fbright4█---$rst$f4█$rst $f5$bld$fbright5█---$rst$f5█$rst $f6$bld$fbright6█---$rst$f6█$rst
$f1$bld$fbright1█-$rst$f1█$rst $f2$bld$fbright2█-$rst$f2█$rst $f3$bld$fbright3█-$rst$f3█$rst $f4$bld$fbright4█-$rst$f4█$rst $f5$bld$fbright5█-$rst$f5█$rst $f6$bld$fbright6█-$rst$f6█$rst
$f1$bld$fbright1█$rst $f2$bld$fbright2█$rst $f3$bld$fbright3█$rst $f4$bld$fbright4█$rst $f5$bld$fbright5█$rst $f6$bld$fbright6█$rst
$f1█-$bld$fbright1█$rst $f2█-$bld$fbright2█$rst $f3█-$bld$fbright3█$rst $f4█-$bld$fbright4█$rst $f5█-$bld$fbright5█$rst $f6█-$bld$fbright6█$rst
$f1█---$bld$fbright1█$rst $f2█---$bld$fbright2█$rst $f3█---$bld$fbright3█$rst $f4█---$bld$fbright4█$rst $f5█---$bld$fbright5█$rst $f6█---$bld$fbright6█$rst
$f1█-----$bld$fbright1█ $rst$f2█-----$bld$fbright2█$rst $f3█-----$bld$fbright3█$rst $f4█-----$bld$fbright4█$rst $f5█-----$bld$fbright5█$rst $f6█-----$bld$fbright6█$rst
EOF

View File

@@ -0,0 +1,58 @@
#!/bin/sh
# Author: Ivo
# Source: http://crunchbang.org/forums/viewtopic.php?pid=237794#p237794
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m";
cyanf="${esc}[36m"; purplef="${esc}[35m"
redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m";
cyanfbright="${esc}[96m"; purplefbright="${esc}[95m"
boldon="${esc}[1m";
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${boldon} ▓ ▓ ▓▓▓ ▓ ▓ ▓▓▓ ▓ ▓ ▓ ▓░ ░░▓ ▓▓ ▓ ▓▓
${boldon}▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓░▓▓▓▓▓▓▓▓░▓▒ ░░▓▓▓▓░▓▓▓▓░▓▓▓▓▓▓▓▓░▓▓▓▓░ ▓▓▓▓▓▓▓▓
${boldon} ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░▓▓▓▓▓▓▓ ▓▓▓▓▓░▓▓
${boldon} ▓▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓░▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░▓ ▓▓▓▓▓▓▓▓
${boldon} ▓▓▓▓▓▓▒ ▓▓▓▓▒▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░▓
${boldon} ▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓░▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon} ▓▓▓▓▓▓▓ ▓▓▒▓▓░▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓░▓▓▓▓░ ▓▓▓▓▓▓▓▓▒▓▓▓▓▓▓▓▓▓▓▓░░▓▓▓
${boldon} ▓▓▓▓░▓▓ ▓▓▓░▓▓░▓▓▓▓▓░▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░
${boldon} ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon} ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░
${boldon} ▓▓▓▓░▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon} ▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓ ▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon} ▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon} ▓▓░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░▓░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓░▓▓▓▓▓▓▓
${boldon} ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░▓ ▓▓▓▓▓▓▓▓▓▓░▓▓▓▓▓ ▓▓▓▓▓▓░▓▓▓▓▓▓▓▓▓ ▓▓▓▓░▓▓ ░▓ ▓▓▓▓▓▓▓
${boldon} ▓▓▓▓▓▓▓▓▒▓▓▓▓▓▓░ ▓░▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓░▓▓▓ ▓▓▓▓▓▓▓
${boldon} ▓▓▓▓ ▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓ ▓▓▓▓░▒▓▓▓▓ ▓▓ ▓▓▓░░▓▓
${boldon} ▓▓▓▓▓▓ ▓▓░ ░▓▓░ ▓▓░▓ ▓▓▓▓▓▓▓
${boldon} ▓▓▓▓▓▓▓▓ ░▓▓▓▓▓▓
${boldon} ▓▓▓▓▓ ▓▓▓░░
${boldon} ░▓▓ ▒▓▓
${reset}
EOF

View File

@@ -0,0 +1,58 @@
#!/bin/sh
# Author: Ivo
# Source: http://crunchbang.org/forums/viewtopic.php?pid=237794#p237794
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m";
cyanf="${esc}[36m"; purplef="${esc}[35m"
redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m";
cyanfbright="${esc}[96m"; purplefbright="${esc}[95m"
boldon="${esc}[1m";
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${boldon}${yellowfbright} ▓ ▓ ▓▓▓ ▓ ▓ ▓▓▓ ▓ ▓ ▓ ▓░ ░░▓ ▓▓ ▓ ▓▓
${boldon}${yellowfbright}▓▓${boldon}${yellowfbright}▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓░▓▓▓▓▓▓▓▓░▓▒ ░░▓▓▓▓░▓▓▓▓░▓▓▓▓▓▓▓▓░▓▓▓▓░ ▓▓▓▓▓${boldon}${yellowfbright}▓▓▓
${boldon}${yellowfbright} ▓▓${boldon}${bluefbright}▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░▓▓▓▓▓▓▓ ▓▓▓▓▓░${boldon}${yellowfbright}▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${bluefbright}▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓░▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░▓ ▓▓▓▓▓▓${boldon}${yellowfbright}▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${bluefbright}▓▓▓▒ ▓▓▓▓▒▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓░▓
${boldon}${yellowfbright} ▓▓▓${boldon}${bluefbright}▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓░▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓
${boldon}${yellowfbright} ▓▓${boldon}${bluefbright}▓▓▓▓▓ ▓▓▒▓▓░▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓░▓▓▓▓░ ▓▓▓▓▓▓▓▓▒▓▓▓▓▓▓▓▓▓▓▓░░${boldon}${yellowfbright}▓▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${bluefbright}▓░▓▓ ▓▓▓░▓▓░▓▓▓▓▓░▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓▓░
${boldon}${yellowfbright} ▓▓${boldon}${redfbright}▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${redfbright}▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓░
${boldon}${yellowfbright} ▓▓${boldon}${redfbright}▓▓░▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${redfbright}▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓ ▓▓▓▓▓ ▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${redfbright}▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓${boldon}${redfbright}░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓▓
${boldon}${yellowfbright} ▓▓${boldon}${redfbright}░▓▓▓▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓░▓░${boldon}${yellowfbright}${boldon}${redfbright}▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓░▓▓▓▓${boldon}${yellowfbright}▓▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${redfbright}▓▓▓▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓░▓ ▓▓${boldon}${redfbright}▓▓▓▓▓▓▓▓░▓▓▓▓▓ ▓▓▓▓▓▓░▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓ ▓▓▓▓░▓▓ ░▓ ▓${boldon}${redfbright}▓▓▓▓${boldon}${yellowfbright}▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${redfbright}▓▓▓▓▓▒▓▓▓${boldon}${yellowfbright}▓▓▓░ ▓░▓${boldon}${redfbright}▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓ ▓▓${boldon}${redfbright}▓▓▓▓▓▓▓▓${boldon}${yellowfbright}▓▓ ▓░▓▓▓ ▓${boldon}${redfbright}▓▓▓▓${boldon}${yellowfbright}▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${redfbright}▓ ▓▓▓▓▓${boldon}${yellowfbright}▓▓▓ ▓▓${boldon}${redfbright}▓▓${boldon}${redfbright}▓▓▓${boldon}${yellowfbright}▓▓ ▓▓${boldon}${redfbright}▓▓░▒▓▓${boldon}${yellowfbright}▓▓ ▓▓ ▓${boldon}${redfbright}▓▓░░${boldon}${yellowfbright}▓▓
${boldon}${yellowfbright} ▓▓▓${boldon}${redfbright}▓▓▓${boldon}${yellowfbright} ▓▓░ ░▓▓░ ▓▓░▓ ▓${boldon}${redfbright}▓▓▓▓▓${boldon}${yellowfbright}▓
${boldon}${yellowfbright} ▓▓▓${boldon}${redfbright}▓▓▓${boldon}${yellowfbright}▓▓ ░▓${boldon}${redfbright}▓▓▓▓${boldon}${yellowfbright}▓
${boldon}${yellowfbright} ▓▓${boldon}${redfbright}▓${boldon}${yellowfbright}▓▓ ▓${boldon}${redfbright}▓▓░${boldon}${yellowfbright}░
${boldon}${yellowfbright} ░▓▓${boldon}${redfbright} ${boldon}${yellowfbright} ▒▓${boldon}${redfbright}${boldon}${yellowfbright}▓
${reset}
EOF

50
local_bin/color-scripts/elfman Executable file
View File

@@ -0,0 +1,50 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: thevdude
# Source: http://crunchbang.org/forums/viewtopic.php?pid=144700#p144700
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${boldon}${whitefbright} ▄▄▄${reset}
${boldon}${whitefbright} ▄█████▄▄ ${reset}
${boldon}${whitefbright}███${cyanb}▀▀▀▀${blackb}▀${cyanb}▀${blackb}▀${cyanb}▀${reset}
${boldon}${whitefbright}███${cyanb}▄ ${boldoff}${blackf}▀ ▀${reset}${cyanf}▀${reset}
${boldon}${whitefbright} ▄${cyanb} ${reset}${boldon}${whitefbright}█████▄ ${boldoff}${redf}█▄${reset}
${boldoff}${redf}▀▀${reset}${boldon}${redb}${whitefbright}▄${cyanb}▄ ${redb}▄▄▄${reset}${boldoff}${redf}▀██▀${reset}
${boldon}${whitefbright} ██▀▀▀██▀ ${boldoff}${redf}▀${reset}
${boldon}${whitefbright} ▀▀▀▀ ▀▀▀▀${reset}
EOF

48
local_bin/color-scripts/faces Executable file
View File

@@ -0,0 +1,48 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=127737#p127737
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${white}╔══════════════════════════════════════════════════════════════════╗
${white}║ ${redf} ▄█ █▄${reset} ${greenf} ▄█ █▄${reset} ${yellowf} ▄█ █▄${reset} ${bluef} ▄█ █▄${reset} ${purplef} ▄█ █▄${reset} ${cyanf} ▄█ █▄${reset} ${white}║
${white}║ ${boldon}${redfbright}▄█◄► ◄►█▄${reset} ${boldon}${greenfbright}▄█◄► ◄►█▄${reset} ${boldon}${yellowfbright}▄█◄► ◄►█▄${reset} ${boldon}${bluefbright}▄█◄► ◄►█▄${reset} ${boldon}${purplefbright}▄█◄► ◄►█▄${reset} ${boldon}${cyanfbright}▄█◄► ◄►█▄${reset} ${white}║
${white}║ ${boldon}${redfbright}▀█  █▀${reset} ${boldon}${greenfbright}▀█  █▀${reset} ${boldon}${yellowfbright}▀█  █▀${reset} ${boldon}${bluefbright}▀█  █▀${reset} ${boldon}${purplefbright}▀█  █▀${reset} ${boldon}${cyanfbright}▀█  █▀${reset} ${white}║
${white}║ ${redf} ▀█ █▀${reset} ${greenf} ▀█ █▀${reset} ${yellowf} ▀█ █▀${reset} ${bluef} ▀█ █▀${reset} ${purplef} ▀█ █▀${reset} ${cyanf} ▀█ █▀${reset} ${white}║
${white}╚══════════════════════════════════════════════════════════════════╝
EOF

45
local_bin/color-scripts/fade Executable file
View File

@@ -0,0 +1,45 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=127737#p127737
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[30m"; redfbright="${esc}[31m"; greenfbright="${esc}[32m"
yellowfbright="${esc}[33m" bluefbright="${esc}[34m"; purplefbright="${esc}[35m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${redf}▒▒▒▒${reset} ${boldon}${redfbright}▒▒${reset} ${greenf}▒▒▒▒${reset} ${boldon}${greenfbright}▒▒${reset} ${yellowf}▒▒▒▒${reset} ${boldon}${yellowfbright}▒▒${reset} ${bluef}▒▒▒▒${reset} ${boldon}${bluefbright}▒▒${reset} ${purplef}▒▒▒▒${reset} ${boldon}${purplefbright}▒▒${reset} ${cyanf}▒▒▒▒${reset} ${boldon}${cyanfbright}▒▒${reset}
${redf}▒▒ ■${reset} ${boldon}${redfbright}▒▒${reset} ${greenf}▒▒ ■${reset} ${boldon}${greenfbright}▒▒${reset} ${yellowf}▒▒ ■${reset} ${boldon}${yellowfbright}▒▒${reset} ${bluef}▒▒ ■${reset} ${boldon}${bluefbright}▒▒${reset} ${purplef}▒▒ ■${reset} ${boldon}${purplefbright}▒▒${reset} ${cyanf}▒▒ ■${reset} ${boldon}${cyanfbright}▒▒${reset}
${redf}▒▒ ${reset}${boldon}${redfbright}▒▒▒▒${reset} ${greenf}▒▒ ${reset}${boldon}${greenfbright}▒▒▒▒${reset} ${yellowf}▒▒ ${reset}${boldon}${yellowfbright}▒▒▒▒${reset} ${bluef}▒▒ ${reset}${boldon}${bluefbright}▒▒▒▒${reset} ${purplef}▒▒ ${reset}${boldon}${purplefbright}▒▒▒▒${reset} ${cyanf}▒▒ ${reset}${boldon}${cyanfbright}▒▒▒▒${reset}
EOF

33
local_bin/color-scripts/ghosts Executable file
View File

@@ -0,0 +1,33 @@
#!/bin/bash
# ANSI color scheme script by pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=157979#p157979
# Initializing mod by lolilolicon from Archlinux
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
for i in {0..7}; do
printf -v fbright$i %b "\e[9${i}m"
done
bld=$'\e[1m'
rst=$'\e[0m'
inv=$'\e[7m'
cat << EOF
$f1 ▄▄▄ $f2 ▄▄▄ $f3 ▄▄▄ $f4 ▄▄▄ $f5 ▄▄▄ $f6 ▄▄▄
$f1 ▀█▀██ ▄ $f2 ▀█▀██ ▄ $f3 ▀█▀██ ▄ $f4 ▀█▀██ ▄ $f5 ▀█▀██ ▄ $f6 ▀█▀██ ▄
$f1 ▀▄██████▀ $f2 ▀▄██████▀ $f3 ▀▄██████▀ $f4 ▀▄██████▀ $f5 ▀▄██████▀ $f6 ▀▄██████▀
$f1 ▀█████ $f2 ▀█████ $f3 ▀█████ $f4 ▀█████ $f5 ▀█████ $f6 ▀█████
$f1 ▀▀▀▀▄ $f2 ▀▀▀▀▄ $f3 ▀▀▀▀▄ $f4 ▀▀▀▀▄ $f5 ▀▀▀▀▄ $f6 ▀▀▀▀▄
$bld
$fbright1 ▄▄▄ $fbright2 ▄▄▄ $fbright3 ▄▄▄ $fbright4 ▄▄▄ $fbright5 ▄▄▄ $fbright6 ▄▄▄
$fbright1 ▀█▀██ ▄ $fbright2 ▀█▀██ ▄ $fbright3 ▀█▀██ ▄ $fbright4 ▀█▀██ ▄ $fbright5 ▀█▀██ ▄ $fbright6 ▀█▀██ ▄
$fbright1 ▀▄██████▀ $fbright2 ▀▄██████▀ $fbright3 ▀▄██████▀ $fbright4 ▀▄██████▀ $fbright5 ▀▄██████▀ $fbright6 ▀▄██████▀
$fbright1 ▀█████ $fbright2 ▀█████ $fbright3 ▀█████ $fbright4 ▀█████ $fbright5 ▀█████ $fbright6 ▀█████
$fbright1 ▀▀▀▀▄ $fbright2 ▀▀▀▀▄ $fbright3 ▀▀▀▀▄ $fbright4 ▀▀▀▀▄ $fbright5 ▀▀▀▀▄ $fbright6 ▀▀▀▀▄
$rst
EOF

34
local_bin/color-scripts/guns Executable file
View File

@@ -0,0 +1,34 @@
#!/bin/bash
# ANSI color scheme script by pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=151602#p151602
# Initializing mod by lolilolicon from Archlinux
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
for i in {0..7}; do
printf -v fbright$i %b "\e[9${i}m"
done
bld=$'\e[1m'
rst=$'\e[0m'
inv=$'\e[7m'
cat << EOF
$f1 ▀▄▄███████████ $f2 ▀▄▄███████████ $f3 ▀▄▄███████████ $f4 ▀▄▄███████████ $f5 ▀▄▄███████████ $f6 ▀▄▄███████████
$f1 ▄███▀█▀▀▀ $f2 ▄███▀█▀▀▀ $f3 ▄███▀█▀▀▀ $f4 ▄███▀█▀▀▀ $f5 ▄███▀█▀▀▀ $f6 ▄███▀█▀▀▀
$f1 ▐███▄▀ $f2▐███▄▀ $f3▐███▄▀ $f4▐███▄▀ $f5▐███▄▀ $f6▐███▄▀
$f1 ▐███ $f2▐███ $f3▐███ $f4▐███ $f5▐███ $f6▐███
$f1 ▀▀▀ $f2 ▀▀▀ $f3 ▀▀▀ $f4 ▀▀▀ $f5 ▀▀▀ $f6 ▀▀▀
$bld
$fbright1 ▀▄▄███████████ $fbright2 ▀▄▄███████████ $fbright3 ▀▄▄███████████ $fbright4 ▀▄▄███████████ $fbright5 ▀▄▄███████████ $fbright6 ▀▄▄███████████
$fbright1 ▄███▀█▀▀▀ $fbright2 ▄███▀█▀▀▀ $fbright3 ▄███▀█▀▀▀ $fbright4 ▄███▀█▀▀▀ $fbright5 ▄███▀█▀▀▀ $fbright6 ▄███▀█▀▀▀
$fbright1 ▐███▄▀ $fbright2▐███▄▀ $fbright3▐███▄▀ $fbright4▐███▄▀ $fbright5▐███▄▀ $fbright6▐███▄▀
$fbright1 ▐███ $fbright2▐███ $fbright3▐███ $fbright4▐███ $fbright5▐███ $fbright6▐███
$fbright1 ▀▀▀ $fbright2 ▀▀▀ $fbright3 ▀▀▀ $fbright4 ▀▀▀ $fbright5 ▀▀▀ $fbright6 ▀▀▀
$rst
EOF

View File

@@ -0,0 +1,23 @@
#!/bin/sh
# Author: venam
# Source: https://nixers.net/showthread.php?tid=1921
cat << EOF
._________________________________. 
|       | 
|   _   | 
|  //\  | 
|  //-- // \ ========,  | 
|  // // \ /  | 
|  // // \ /  | 
|  __________ ___  __ _________ | 
|  / \    // //  | 
|  / \ // //  | 
|  /__________________//  | 
|  \ //  | 
|  \//  | 
|   "   | 
|        | 
'---------------------------------' 
EOF

View File

@@ -0,0 +1,55 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=129265#p129265
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
# ****************************** Building blocks: █ ▓ ▒ ░ ▄ ▀ ▐ ▌ ● ═ ║ ╔ ╦ ╗ ╚ ╩ ╝ ■ ▬ ▲ ▼ ◄ ►
initializeANSI
cat << EOF
${redf} ▄█████▄ ${greenf} ▄█████▄ ${yellowf} ▄█████▄ ${bluef} ▄█████▄ ${purplef} ▄█████▄ ${cyanf} ▄█████▄
${redf} █▄▄ ▄▄█ ${greenf} █▄▄ ▄▄█ ${yellowf} █▄▄ ▄▄█ ${bluef} █▄▄ ▄▄█ ${purplef} █▄▄ ▄▄█ ${cyanf} █▄▄ ▄▄█
${redf} ███ ███ ${greenf} ███ ███ ${yellowf} ███ ███ ${bluef} ███ ███ ${purplef} ███ ███ ${cyanf} ███ ███
${redf} ▀██ ██▀ ${greenf} ▀██ ██▀ ${yellowf} ▀██ ██▀ ${bluef} ▀██ ██▀ ${purplef} ▀██ ██▀ ${cyanf} ▀██ ██▀
${redf} ▀ ▀ ${greenf} ▀ ▀ ${yellowf} ▀ ▀ ${bluef} ▀ ▀ ${purplef} ▀ ▀ ${cyanf} ▀ ▀
${boldon}
${redfbright} ▄█████▄ ${greenfbright} ▄█████▄ ${yellowfbright} ▄█████▄ ${bluefbright} ▄█████▄ ${purplefbright} ▄█████▄ ${cyanfbright} ▄█████▄
${redfbright} █▄▄ ▄▄█ ${greenfbright} █▄▄ ▄▄█ ${yellowfbright} █▄▄ ▄▄█ ${bluefbright} █▄▄ ▄▄█ ${purplefbright} █▄▄ ▄▄█ ${cyanfbright} █▄▄ ▄▄█
${redfbright} ███ ███ ${greenfbright} ███ ███ ${yellowfbright} ███ ███ ${bluefbright} ███ ███ ${purplefbright} ███ ███ ${cyanfbright} ███ ███
${redfbright} ▀██ ██▀ ${greenfbright} ▀██ ██▀ ${yellowfbright} ▀██ ██▀ ${bluefbright} ▀██ ██▀ ${purplefbright} ▀██ ██▀ ${cyanfbright} ▀██ ██▀
${redfbright} ▀ ▀ ${greenfbright} ▀ ▀ ${yellowfbright} ▀ ▀ ${bluefbright} ▀ ▀ ${purplefbright} ▀ ▀ ${cyanfbright} ▀ ▀
${reset}
EOF

63
local_bin/color-scripts/kaisen Executable file
View File

@@ -0,0 +1,63 @@
#!/bin/sh
# Author: Ivo
# Source: http://crunchbang.org/forums/viewtopic.php?pid=237794#p237794
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m";
cyanf="${esc}[36m"; purplef="${esc}[35m"
redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m";
cyanfbright="${esc}[96m"; purplefbright="${esc}[95m"
boldon="${esc}[1m";
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${boldon}${redfbright} ░▓▓
${boldon}${redfbright} ▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓░ ▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓ ▓▓▓ ▓▒ ░▓▓▓▓▓
${boldon}${redfbright} ▒▓▓ ▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒
${boldon}${redfbright} ▓▓▓ ▓▓▓▓▓ ▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▒▓▓▓▓▓ ▓▓▓▓▒ ▓▓░ ▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓ ▓
${boldon}${redfbright} ▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▒▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ░▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▒ ▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓ ░▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓░ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓ ▓▓ ▒ ▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒
${boldon}${redfbright} ▓▓▓ ▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓▓▓ ▒▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓
${boldon}${redfbright} ▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${boldon}${redfbright} ░▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
${reset}
EOF

38
local_bin/color-scripts/manjaro Executable file
View File

@@ -0,0 +1,38 @@
#!/bin/sh
# Author: ishaanbhimwal@gmail.com
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m";
cyanf="${esc}[36m"; purplef="${esc}[35m"
redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m";
cyanfbright="${esc}[96m"; purplefbright="${esc}[95m"
boldon="${esc}[1m";
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${reset}${redf} ███████ ███ ${greenf} ███████ ███ ${yellowf} ███████ ███ ${bluef} ███████ ███ ${purplef} ███████ ███ ${cyanf} ███████ ███
${reset}${redf} ███ ${boldon}${redfbright}▄▄▄${reset}${redf} ███ ${greenf} ███ ${boldon}${greenfbright}▄▄▄${reset}${greenf} ███ ${yellowf} ███ ${boldon}${yellowfbright}▄▄▄${reset}${yellowf} ███ ${bluef} ███ ${boldon}${bluefbright}▄▄▄${reset}${bluef} ███ ${purplef} ███ ${boldon}${purplefbright}▄▄▄${reset}${purplef} ███ ${cyanf} ███ ${boldon}${cyanfbright}▄▄▄${reset}${cyanf} ███
${reset}${redf} ███ ${boldon}${redfbright}███${reset}${redf} ███ ${greenf} ███ ${boldon}${greenfbright}███${reset}${greenf} ███ ${yellowf} ███ ${boldon}${yellowfbright}███${reset}${yellowf} ███ ${bluef} ███ ${boldon}${bluefbright}███${reset}${bluef} ███ ${purplef} ███ ${boldon}${purplefbright}███${reset}${purplef} ███ ${cyanf} ███ ${boldon}${cyanfbright}███${reset}${cyanf} ███
${reset}${redf} ███ ${boldon}${redfbright}███${reset}${redf} ███ ${greenf} ███ ${boldon}${greenfbright}███${reset}${greenf} ███ ${yellowf} ███ ${boldon}${yellowfbright}███${reset}${yellowf} ███ ${bluef} ███ ${boldon}${bluefbright}███${reset}${bluef} ███ ${purplef} ███ ${boldon}${purplefbright}███${reset}${purplef} ███ ${cyanf} ███ ${boldon}${cyanfbright}███${reset}${cyanf} ███
${reset}${redf} ▀▀▀ ${boldon}${redfbright}▀▀▀${reset}${redf} ▀▀▀ ${greenf} ▀▀▀ ${boldon}${greenfbright}▀▀▀${reset}${greenf} ▀▀▀ ${yellowf} ▀▀▀ ${boldon}${yellowfbright}▀▀▀${reset}${yellowf} ▀▀▀ ${bluef} ▀▀▀ ${boldon}${bluefbright}▀▀▀${reset}${bluef} ▀▀▀ ${purplef} ▀▀▀ ${boldon}${purplefbright}▀▀▀${reset}${purplef} ▀▀▀ ${cyanf} ▀▀▀ ${boldon}${cyanfbright}▀▀▀${reset}${cyanf} ▀▀▀
${reset}
EOF

42
local_bin/color-scripts/monster Executable file
View File

@@ -0,0 +1,42 @@
#!/bin/sh
# Author: gutterslob
# Source: http://crunchbang.org/forums/viewtopic.php?pid=130590#p130590
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
initializeANSI
cat << EOF
${reset}${blackf}| | | | |${reset}
${redf}█ █${reset} ${blackf}|${reset} ${greenf}█ █${reset} ${blackf}|${reset} ${yellowf}█ █${reset} ${blackf}|${reset} ${bluef}█ █${reset} ${blackf}|${reset} ${purplef}█ █${reset} ${blackf}|${reset} ${cyanf}█ █${reset}
${redf}███████${reset} ${blackf}|${reset} ${greenf}███████${reset} ${blackf}|${reset} ${yellowf}███████${reset} ${blackf}|${reset} ${bluef}███████${reset} ${blackf}|${reset} ${purplef}███████${reset} ${blackf}|${reset} ${cyanf}███████${reset}
${redf}███${boldon}${redfbright}██${reset}${redf}█${boldon}${redfbright}██${reset}${redf}███${reset} ${blackf}|${reset} ${greenf}███${boldon}${greenfbright}██${reset}${greenf}█${boldon}${greenfbright}██${reset}${greenf}███${reset} ${blackf}|${reset} ${yellowf}███${boldon}${yellowfbright}██${reset}${yellowf}█${boldon}${yellowfbright}██${reset}${yellowf}███${reset} ${blackf}|${reset} ${bluef}███${boldon}${bluefbright}██${reset}${bluef}█${boldon}${bluefbright}██${reset}${bluef}███${reset} ${blackf}|${reset} ${purplef}███${boldon}${purplefbright}██${reset}${purplef}█${boldon}${purplefbright}██${reset}${purplef}███${reset} ${blackf}|${reset} ${cyanf}███${boldon}${cyanfbright}██${reset}${cyanf}█${boldon}${cyanfbright}██${reset}${cyanf}███${reset}
${redf}████${boldon}${redfbright}█${reset}${redf}████${reset} ${blackf}|${reset} ${greenf}████${boldon}${greenfbright}█${reset}${greenf}████${reset} ${blackf}|${reset} ${yellowf}████${boldon}${yellowfbright}█${reset}${yellowf}████${reset} ${blackf}|${reset} ${bluef}████${boldon}${bluefbright}█${reset}${bluef}████${reset} ${blackf}|${reset} ${purplef}████${boldon}${purplefbright}█${reset}${purplef}████${reset} ${blackf}|${reset} ${cyanf}████${boldon}${cyanfbright}█${reset}${cyanf}████${reset}
${redf}█ █ ${boldon}${redfbright}█${reset} ${redf}█ █${reset} ${blackf}|${reset} ${greenf}█ █ ${boldon}${greenfbright}█${reset} ${greenf}█ █${reset} ${blackf}|${reset} ${yellowf}█ █ ${boldon}${yellowfbright}█${reset} ${yellowf}█ █${reset} ${blackf}|${reset} ${bluef}█ █ ${boldon}${bluefbright}█${reset} ${bluef}█ █${reset} ${blackf}|${reset} ${purplef}█ █ ${boldon}${purplefbright}█${reset} ${purplef}█ █${reset} ${blackf}|${reset} ${cyanf}█ █ ${boldon}${cyanfbright}█${reset} ${cyanf}█ █${reset}
${redf}█ █${reset} ${blackf}|${reset} ${greenf}█ █${reset} ${blackf}|${reset} ${yellowf}█ █${reset} ${blackf}|${reset} ${bluef}█ █${reset} ${blackf}|${reset} ${purplef}█ █${reset} ${blackf}|${reset} ${cyanf}█ █${reset}
${blackf}| | | | |${reset}
EOF

View File

@@ -0,0 +1,50 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: ivo
# Source: http://crunchbang.org/forums/viewtopic.php?pid=130522#p130522
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${boldon}${redfbright} █ █ ${reset} ${boldon}${greenfbright}█ █ ${reset} ${boldon}${yellowfbright}█ █ ${reset} ${boldon}${bluefbright}█ █ ${reset} ${boldon}${purplefbright}█ █ ${reset} ${boldon}${cyanfbright}█ █ ${reset}
${boldon}${redfbright} ■ ■ ${reset} ${boldon}${greenfbright} ■ ■ ${reset} ${boldon}${yellowfbright} ■ ■ ${reset} ${boldon}${bluefbright} ■ ■ ${reset} ${boldon}${purplefbright} ■ ■ ${reset} ${boldon}${cyanfbright} ■ ■ ${reset}
${boldon}${redfbright} =■= ${reset} ${boldon}${greenfbright} =■= ${reset} ${boldon}${yellowfbright} =■= ${reset} ${boldon}${bluefbright} =■= ${reset} ${boldon}${purplefbright} =■= ${reset} ${boldon}${cyanfbright} =■= ${reset}
${redf} █=@=█ ${reset} ${greenf}█=@=█ ${reset} ${yellowf}█=@=█ ${reset} ${bluef}█=@=█ ${reset} ${purplef}█=@=█ ${reset} ${cyanf}█=@=█ ${reset}
${redf} ■ ■ ${reset} ${greenf} ■ ■ ${reset} ${yellowf} ■ ■ ${reset} ${bluef} ■ ■ ${reset} ${purplef} ■ ■ ${reset} ${cyanf} ■ ■ ${reset}
${redf} =■= ${reset} ${greenf} =■= ${reset} ${yellowf} =■= ${reset} ${bluef} =■= ${reset} ${purplef} =■= ${reset} ${cyanf} =■= ${reset}
EOF

View File

@@ -0,0 +1,49 @@
#!/bin/sh
#
# Author: Ivo
# Source: http://crunchbang.org/forums/viewtopic.php?pid=150114#p150114
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m" whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m" whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${boldon}${redfbright} ██ ██ ${reset} ${boldon}${greenfbright} ██ ██ ${reset} ${boldon}${yellowfbright} ██ ██ ${reset} ${boldon}${bluefbright} ██ ██ ${reset} ${boldon}${purplefbright} ██ ██ ${reset} ${boldon}${cyanfbright} ██ ██ ${reset}
${boldon}${redfbright} █${whitef} ■${reset}${boldon}${redfbright}█ █${whitef}■${reset}${boldon}${redfbright} █${reset} ${boldon}${greenfbright} █${whitef} ■${reset}${boldon}${greenfbright}█ █${whitef}■${reset}${boldon}${greenfbright} █${reset} ${boldon}${yellowfbright} █${whitef} ■${reset}${boldon}${yellowfbright}█ █${whitef}■${reset}${boldon}${yellowfbright} █${reset} ${boldon}${bluefbright} █${whitef} ■${reset}${boldon}${bluefbright}█ █${whitef}■${reset}${boldon}${bluefbright} █${reset} ${boldon}${purplefbright} █${whitef} ■${reset}${boldon}${purplefbright}█ █${whitef}■${reset}${boldon}${purplefbright} █${reset} ${boldon}${cyanfbright} █${whitef} ■${reset}${boldon}${cyanfbright}█ █${whitef}■${reset}${boldon}${cyanfbright} █${reset}
${redf} █ █ █ █ ${reset} ${greenf} █ █ █ █ ${reset} ${yellowf} █ █ █ █ ${reset} ${bluef} █ █ █ █ ${reset} ${purplef} █ █ █ █ ${reset} ${cyanf} █ █ █ █ ${reset}
${redf} █ █ █ ${reset} ${greenf} █ █ █ ${reset} ${yellowf} █ █ █ ${reset} ${bluef} █ █ █ ${reset} ${purplef} █ █ █ ${reset} ${cyanf} █ █ █ ${reset}
${redf} =■= ${reset} ${greenf} =■= ${reset} ${yellowf} =■= ${reset} ${bluef} =■= ${reset} ${purplef} =■= ${reset} ${cyanf} =■= ${reset}
EOF

View File

@@ -0,0 +1,39 @@
#!/bin/bash
# ANSI color scheme script featuring PACMAN
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=144481#p144481
# Initializing procedure by lolilolicon
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
for i in {0..7}; do
printf -v fbright$i %b "\e[9${i}m"
done
bld=$'\e[1m'
rst=$'\e[0m'
inv=$'\e[7m'
cat << EOF
$rst
$f3 ▄███████▄ $f1 ▄██████▄ $f2 ▄██████▄ $f4 ▄██████▄ $f5 ▄██████▄ $f6 ▄██████▄
$f3▄█████████▀▀ $f1▄$f7█▀█$f1██$f7█▀█$f1██▄ $f2▄█$f7███$f2██$f7███$f2█▄ $f4▄█$f7███$f4██$f7███$f4█▄ $f5▄█$f7███$f5██$f7███$f5█▄ $f6▄██$f7█▀█$f6██$f7█▀█$f6▄
$f3███████▀ $f7▄▄ ▄▄ ▄▄ $f1█$f7▄▄█$f1██$f7▄▄█$f1███ $f2██$f7█ █$f2██$f7█ █$f2██ $f4██$f7█ █$f4██$f7█ █$f4██ $f5██$f7█ █$f5██$f7█ █$f5██ $f6███$f7█▄▄$f6██$f7█▄▄$f6█
$f3███████▄ $f7▀▀ ▀▀ ▀▀ $f1████████████ $f2████████████ $f4████████████ $f5████████████ $f6████████████
$f3▀█████████▄▄ $f1██▀██▀▀██▀██ $f2██▀██▀▀██▀██ $f4██▀██▀▀██▀██ $f5██▀██▀▀██▀██ $f6██▀██▀▀██▀██
$f3 ▀███████▀ $f1▀ ▀ ▀ ▀ $f2▀ ▀ ▀ ▀ $f4▀ ▀ ▀ ▀ $f5▀ ▀ ▀ ▀ $f6▀ ▀ ▀ ▀
$bld
$fbright3 ▄███████▄ $fbright1 ▄██████▄ $fbright2 ▄██████▄ $fbright4 ▄██████▄ $fbright5 ▄██████▄ $fbright6 ▄██████▄
$fbright3▄█████████▀▀ $fbright1▄$fbright7█▀█$fbright1██$fbright7█▀█$fbright1██▄ $fbright2▄█$fbright7█ █$fbright2██$fbright7█ █$fbright2█▄ $fbright4▄█$fbright7█ █$fbright4██$fbright7█ █$fbright4█▄ $fbright5▄█$fbright7█ █$fbright5██$fbright7█ █$fbright5█▄ $fbright6▄██$fbright7█▀█$fbright6██$fbright7█▀█$fbright6▄
$fbright3███████▀ $fbright7▄▄ ▄▄ ▄▄ $fbright1█$fbright7▄▄█$fbright1██$fbright7▄▄█$fbright1███ $fbright2██$fbright7███$fbright2██$fbright7███$fbright2██ $fbright4██$fbright7███$fbright4██$fbright7███$fbright4██ $fbright5██$fbright7███$fbright5██$fbright7███$fbright5██ $fbright6███$fbright7█▄▄$fbright6██$fbright7█▄▄$fbright6█
$fbright3███████▄ $fbright7▀▀ ▀▀ ▀▀ $fbright1████████████ $fbright2████████████ $fbright4████████████ $fbright5████████████ $fbright6████████████
$fbright3▀█████████▄▄ $fbright1██▀██▀▀██▀██ $fbright2██▀██▀▀██▀██ $fbright4██▀██▀▀██▀██ $fbright5██▀██▀▀██▀██ $fbright6██▀██▀▀██▀██
$fbright3 ▀███████▀ $fbright1▀ ▀ ▀ ▀ $fbright2▀ ▀ ▀ ▀ $fbright4▀ ▀ ▀ ▀ $fbright5▀ ▀ ▀ ▀ $fbright6▀ ▀ ▀ ▀
$rst
EOF

25
local_bin/color-scripts/panes Executable file
View File

@@ -0,0 +1,25 @@
#!/bin/bash
# Author: GekkoP
# Source: http://linuxbbq.org/bbs/viewtopic.php?f=4&t=1656#p33189
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
for i in {0..7}; do
printf -v fbright$i %b "\e[9${i}m"
done
d=$'\e[1m'
t=$'\e[0m'
v=$'\e[7m'
cat <<EOF
$f1███$d$fbright$fbright1▄$t $f2███$d$fbright$fbright2▄$t $f3███$d$fbright3▄$t $f4███$d$fbright4▄$t $f5███$d$fbright5▄$t $f6███$d$fbright6▄$t $f7███$d$fbright7▄$t
$f1███$d$fbright$fbright1█$t $f2███$d$fbright$fbright2█$t $f3███$d$fbright3█$t $f4███$d$fbright4█$t $f5███$d$fbright5█$t $f6███$d$fbright6█$t $f7███$d$fbright7█$t
$f1███$d$fbright$fbright1█$t $f2███$d$fbright$fbright2█$t $f3███$d$fbright3█$t $f4███$d$fbright4█$t $f5███$d$fbright5█$t $f6███$d$fbright6█$t $f7███$d$fbright7█$t
$d$fbright1 ▀▀▀ $fbright2▀▀▀ $fbright3▀▀▀ $fbright4▀▀▀ $fbright5▀▀▀ $fbright6▀▀▀ $fbright7▀▀▀ $t
EOF

40
local_bin/color-scripts/pinguco Executable file
View File

@@ -0,0 +1,40 @@
#!/bin/sh
# Author: lantlos
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
initializeANSI
cat << EOF
${boldon}${blackf} ██████${reset}
${boldon}${blackf}██${reset}██${reset}${bluef}██${reset}${boldon}${blackf}██${reset}${bluef}██${reset}
${boldon}${blackf}██${reset}██${bluef}██${reset}${boldon}${blackf}██${reset}${bluef}██${reset}
${boldon}${blackf}██████${reset}${purplef}██████${reset}
${boldon}${blackf}████${reset}████${boldon}${blackf}██${reset}
${boldon}${blackf}████${reset}████████${boldon}${blackf}██${reset}
${boldon}${blackf}████${reset}████████${boldon}${blackf}██${reset}
${boldon}${blackf}████${reset}████████${boldon}${blackf}██${reset}
${boldon}${blackf}████${reset}████${boldon}${blackf}██${reset}
${boldon}${blackf}███${reset}${purplef}███ ████${reset}
EOF

48
local_bin/color-scripts/rails Executable file
View File

@@ -0,0 +1,48 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=127064#p127064
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${redf}╔╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╗ ${greenf}╔╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╗ ${yellowf}╔╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╗
${boldon}${redfbright}╚╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╝ ${greenfbright}╚╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╝ ${yellowfbright}╚╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╝${reset}
■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■ ■
${bluef}╔╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╗ ${purplef}╔╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╗ ${cyanf}╔╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╦╗
${boldon}${bluefbright}╚╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╝ ${purplefbright}╚╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╝ ${cyanfbright}╚╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╩╝${reset}
EOF

38
local_bin/color-scripts/rally-x Executable file
View File

@@ -0,0 +1,38 @@
#!/bin/bash
# ANSI color scheme script by pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=143700#p143700
# Initializing mod by lolilolicon from Archlinux
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
for i in {0..7}; do
printf -v fbright$i %b "\e[9${i}m"
done
bld=$'\e[1m'
rst=$'\e[0m'
inv=$'\e[7m'
cat <<EOF
$f3 ▄ $f1 ▄▄ $f2 ▄▄ $f4 ▄▄ $f5 ▄▄ $f6 ▄▄
$f3 ███▄▄ $f1 ██▬██▬██ $f2 ██▬██▬██ $f4 ██▬██▬██ $f5 ██▬██▬██ $f6 ██▬██▬██
$f3 █████▀▀$f1 ████ $f2 ████ $f4 ████ $f5 ████ $f6 ████
$f3 █▀▀ $f1 ▄██ ██▄ $f2 ▄██ ██▄ $f4 ▄██ ██▄ $f5 ▄██ ██▄ $f6 ▄██ ██▄
$f3 █ $f1 ▄▄▄▀█ █▀▄▄▄ $f2 ▄▄▄▀█ █▀▄▄▄ $f4 ▄▄▄▀█ █▀▄▄▄ $f5 ▄▄▄▀█ █▀▄▄▄ $f6 ▄▄▄▀█ █▀▄▄▄
$f3▄█▄ $f1 ███▀████▀███ $f2 ███▀████▀███ $f4 ███▀████▀███ $f5 ███▀████▀███ $f6 ███▀████▀███
$f1 ▀ ▀ $f2 ▀ ▀ $f4 ▀ ▀ $f5 ▀ ▀ $f6 ▀ ▀
$bld
$fbright3 ▄ $fbright1 ▄▄ $fbright2 ▄▄ $fbright4 ▄▄ $fbright5 ▄▄ $fbright6 ▄▄
$fbright3 ███▄▄ $fbright1 ██▬██▬██ $fbright2 ██▬██▬██ $fbright4 ██▬██▬██ $fbright5 ██▬██▬██ $fbright6 ██▬██▬██
$fbright3 █████▀▀$fbright1 ████ $fbright2 ████ $fbright4 ████ $fbright5 ████ $fbright6 ████
$fbright3 █▀▀ $fbright1 ▄██ ██▄ $fbright2 ▄██ ██▄ $fbright4 ▄██ ██▄ $fbright5 ▄██ ██▄ $fbright6 ▄██ ██▄
$fbright3 █ $fbright1 ▄▄▄▀█ █▀▄▄▄ $fbright2 ▄▄▄▀█ █▀▄▄▄ $fbright4 ▄▄▄▀█ █▀▄▄▄ $fbright5 ▄▄▄▀█ █▀▄▄▄ $fbright6 ▄▄▄▀█ █▀▄▄▄
$fbright3▄█▄ $fbright1 ███▀████▀███ $fbright2 ███▀████▀███ $fbright4 ███▀████▀███ $fbright5 ███▀████▀███ $fbright6 ███▀████▀███
$fbright1 ▀ ▀ $fbright2 ▀ ▀ $fbright4 ▀ ▀ $fbright5 ▀ ▀ $fbright6 ▀ ▀
$rst
EOF

49
local_bin/color-scripts/rupees Executable file
View File

@@ -0,0 +1,49 @@
#!/bin/sh
initializeANSI()
{
esc=""
Bf="${esc}[30m"; rf="${esc}[31m"; gf="${esc}[32m"
yf="${esc}[33m" bf="${esc}[34m"; pf="${esc}[35m"
cf="${esc}[36m"; wf="${esc}[37m"
Bfbright="${esc}[90m"; rfbright="${esc}[91m"; gfbright="${esc}[92m"
yfbright="${esc}[93m" bfbright="${esc}[94m"; pfbright="${esc}[95m"
cfbright="${esc}[96m"; wfbright="${esc}[97m"
Bb="${esc}[40m"; rb="${esc}[41m"; gb="${esc}[42m"
yb="${esc}[43m" bb="${esc}[44m"; pb="${esc}[45m"
cb="${esc}[46m"; wb="${esc}[47m"
ON="${esc}[1m"; OFF="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
initializeANSI
cat << EOF
${Bf}██ ${Bf}████ ${Bf}████ ${Bf}████ ${Bf}████ ${Bf}████
${Bf}██${yf}██${Bf}██ ${Bf}██${gf}${ON}${gfbright}██${OFF}${gf}██${Bf}██ ${Bf}██${bf}${ON}${bfbright}██${OFF}${bf}██${Bf}██ ${Bf}██${rf}${ON}${rfbright}██${OFF}${rf}██${Bf}██ ${Bf}██${pf}${ON}${pfbright}██${OFF}${pf}██${Bf}██ ${Bf}██${cf}${ON}${cfbright}██${OFF}${cf}██${Bf}██
${Bf}██${yf}██████${Bf}██ ${Bf}██${gf}${ON}${gfbright}████${OFF}${gf}████${Bf}██ ${Bf}██${bf}${ON}${bfbright}████${OFF}${bf}████${Bf}██ ${Bf}██${rf}${ON}${rfbright}████${OFF}${rf}████${Bf}██ ${Bf}██${pf}${ON}${pfbright}████${OFF}${pf}████${Bf}██ ${Bf}██${cf}${ON}${cfbright}████${OFF}${cf}████${Bf}██
${Bf}██${yf}${ON}${yfbright}██${OFF}${yf}████${Bf}██ ${Bf}██${gf}${ON}${gfbright}██████${OFF}${gf}██████${Bf}██ ${Bf}██${bf}${ON}${bfbright}██████${OFF}${bf}██████${Bf}██ ${Bf}██${rf}${ON}${rfbright}██████${OFF}${rf}██████${Bf}██ ${Bf}██${pf}${ON}${pfbright}██████${OFF}${pf}██████${Bf}██ ${Bf}██${cf}${ON}${cfbright}██████${OFF}${cf}██████${Bf}██
${Bf}██${yf}██${ON}${yfbright}████${OFF}${yf}████${Bf}██ ${Bf}██${gf}${ON}${gfbright}██${OFF}${gf}██${ON}${gfbright}██${OFF}${gf}██${Bf}██${gf}██${Bf}██${gf}██${Bf}██ ${Bf}██${bf}${ON}${bfbright}██${OFF}${bf}██${ON}${bfbright}██${OFF}${bf}██${Bf}██${bf}██${Bf}██${bf}██${Bf}██ ${Bf}██${rf}${ON}${rfbright}██${OFF}${rf}██${ON}${rfbright}██${OFF}${rf}██${Bf}██${rf}██${Bf}██${rf}██${Bf}██ ${Bf}██${pf}${ON}${pfbright}██${OFF}${pf}██${ON}${pfbright}██${OFF}${pf}██${Bf}██${pf}██${Bf}██${pf}██${Bf}██ ${Bf}██${cf}${ON}${cfbright}██${OFF}${cf}██${ON}${cfbright}██${OFF}${cf}██${Bf}██${cf}██${Bf}██${cf}██${Bf}██
${Bf}██${yf}████${ON}${yfbright}██${OFF}${yf}████${Bf}██ ${Bf}██${gf}${ON}${gfbright}████${OFF}${gf}██████${Bf}██${gf}████${Bf}██ ${Bf}██${bf}${ON}${bfbright}████${OFF}${bf}██████${Bf}██${bf}████${Bf}██ ${Bf}██${rf}${ON}${rfbright}████${OFF}${rf}██████${Bf}██${rf}████${Bf}██ ${Bf}██${pf}${ON}${pfbright}████${OFF}${pf}██████${Bf}██${pf}████${Bf}██ ${Bf}██${cf}${ON}${cfbright}████${OFF}${cf}██████${Bf}██${cf}████${Bf}██
${Bf}██${yf}██████${ON}${yfbright}████${OFF}${yf}████${Bf}██ ${Bf}██${gf}${ON}${gfbright}████${OFF}${gf}██████${Bf}██${gf}████${Bf}██ ${Bf}██${bf}${ON}${bfbright}████${OFF}${bf}██████${Bf}██${bf}████${Bf}██ ${Bf}██${rf}${ON}${rfbright}████${OFF}${rf}██████${Bf}██${rf}████${Bf}██ ${Bf}██${pf}${ON}${pfbright}████${OFF}${pf}██████${Bf}██${pf}████${Bf}██ ${Bf}██${cf}${ON}${cfbright}████${OFF}${cf}██████${Bf}██${cf}████${Bf}██
${Bf}██${yf}████████${ON}${yfbright}██${OFF}${yf}████${Bf}██ ${Bf}██${gf}${ON}${gfbright}████${OFF}${gf}██████${Bf}██${gf}████${Bf}██ ${Bf}██${bf}${ON}${bfbright}████${OFF}${bf}██████${Bf}██${bf}████${Bf}██ ${Bf}██${rf}${ON}${rfbright}████${OFF}${rf}██████${Bf}██${rf}████${Bf}██ ${Bf}██${pf}${ON}${pfbright}████${OFF}${pf}██████${Bf}██${pf}████${Bf}██ ${Bf}██${cf}${ON}${cfbright}████${OFF}${cf}██████${Bf}██${cf}████${Bf}██
${Bf}██████████████████████ ${Bf}██${gf}${ON}${gfbright}████${OFF}${gf}██████${Bf}██${gf}████${Bf}██ ${Bf}██${bf}${ON}${bfbright}████${OFF}${bf}██████${Bf}██${bf}████${Bf}██ ${Bf}██${rf}${ON}${rfbright}████${OFF}${rf}██████${Bf}██${rf}████${Bf}██ ${Bf}██${pf}${ON}${pfbright}████${OFF}${pf}██████${Bf}██${pf}████${Bf}██ ${Bf}██${cf}${ON}${cfbright}████${OFF}${cf}██████${Bf}██${cf}████${Bf}██
${Bf}██${yf}██${Bf}██ ██${yf}██${Bf}██ ${Bf}██${gf}${ON}${gfbright}████${OFF}${gf}██████${Bf}██${gf}████${Bf}██ ${Bf}██${bf}${ON}${bfbright}████${OFF}${bf}██████${Bf}██${bf}████${Bf}██ ${Bf}██${rf}${ON}${rfbright}████${OFF}${rf}██████${Bf}██${rf}████${Bf}██ ${Bf}██${pf}${ON}${pfbright}████${OFF}${pf}██████${Bf}██${pf}████${Bf}██ ${Bf}██${cf}${ON}${cfbright}████${OFF}${cf}██████${Bf}██${cf}████${Bf}██
${Bf}██${yf}██████${Bf}██ ██${yf}██████${Bf}██ ${Bf}██${gf}${ON}${gfbright}████${OFF}${gf}██████${Bf}██${gf}████${Bf}██ ${Bf}██${bf}${ON}${bfbright}████${OFF}${bf}██████${Bf}██${bf}████${Bf}██ ${Bf}██${rf}${ON}${rfbright}████${OFF}${rf}██████${Bf}██${rf}████${Bf}██ ${Bf}██${pf}${ON}${pfbright}████${OFF}${pf}██████${Bf}██${pf}████${Bf}██ ${Bf}██${cf}${ON}${cfbright}████${OFF}${cf}██████${Bf}██${cf}████${Bf}██
${Bf}██${yf}██████${Bf}██ ██${yf}${ON}${yfbright}██${OFF}${yf}████${Bf}██ ${Bf}██${gf}${ON}${gfbright}██${OFF}${gf}██${ON}${gfbright}██${OFF}${gf}████${Bf}██${gf}████${Bf}██ ${Bf}██${bf}${ON}${bfbright}██${OFF}${bf}██${ON}${bfbright}██${OFF}${bf}████${Bf}██${bf}████${Bf}██ ${Bf}██${rf}${ON}${rfbright}██${OFF}${rf}██${ON}${rfbright}██${OFF}${rf}████${Bf}██${rf}████${Bf}██ ${Bf}██${pf}${ON}${pfbright}██${OFF}${pf}██${ON}${pfbright}██${OFF}${pf}████${Bf}██${pf}████${Bf}██ ${Bf}██${cf}${ON}${cfbright}██${OFF}${cf}██${ON}${cfbright}██${OFF}${cf}████${Bf}██${cf}████${Bf}██
${Bf}██${yf}██████████${Bf}██ ██${yf}██${ON}${yfbright}████${OFF}${yf}████${Bf}██ ${Bf}██${gf}██████${ON}${gfbright}██${OFF}${gf}${Bf}██${gf}██${Bf}██${gf}██${Bf}██ ${Bf}██${bf}██████${ON}${bfbright}██${OFF}${bf}${Bf}██${bf}██${Bf}██${bf}██${Bf}██ ${Bf}██${rf}██████${ON}${rfbright}██${OFF}${rf}${Bf}██${rf}██${Bf}██${rf}██${Bf}██ ${Bf}██${pf}██████${ON}${pfbright}██${OFF}${pf}${Bf}██${pf}██${Bf}██${pf}██${Bf}██ ${Bf}██${cf}██████${ON}${cfbright}██${OFF}${cf}${Bf}██${cf}██${Bf}██${cf}██${Bf}██
${Bf}██${yf}${ON}${yfbright}██${OFF}${yf}████████${Bf}██ ██${yf}████${ON}${yfbright}██${OFF}${yf}████${Bf}██ ${Bf}██${gf}████████████${Bf}██ ${Bf}██${bf}████████████${Bf}██ ${Bf}██${rf}████████████${Bf}██ ${Bf}██${pf}████████████${Bf}██ ${Bf}██${cf}████████████${Bf}██
${Bf}██${yf}██${ON}${yfbright}████${OFF}${yf}████████${Bf}██ ██${yf}██████${ON}${yfbright}████${OFF}${yf}████${Bf}██ ${Bf}██${gf}████████${Bf}██ ${Bf}██${bf}████████${Bf}██ ${Bf}██${rf}████████${Bf}██ ${Bf}██${pf}████████${Bf}██ ${Bf}██${cf}████████${Bf}██
${Bf}██${yf}████${ON}${yfbright}██${OFF}${yf}████████${Bf}██ ██${yf}████████${ON}${yfbright}██${OFF}${yf}████${Bf}██ ${Bf}██${gf}████${Bf}██ ${Bf}██${bf}████${Bf}██ ${Bf}██${rf}████${Bf}██ ${Bf}██${pf}████${Bf}██ ${Bf}██${cf}████${Bf}██
${Bf}██████████████████████████████████████ ${Bf}████ ${Bf}████ ${Bf}████ ${Bf}████ ${Bf}████${reset}
EOF

41
local_bin/color-scripts/six Executable file
View File

@@ -0,0 +1,41 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[30m"; redfbright="${esc}[31m"; greenfbright="${esc}[32m"
yellowfbright="${esc}[33m" bluefbright="${esc}[34m"; purplefbright="${esc}[35m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${redf}▒▒▒▒${reset} ${boldon}${redfbright}▒▒${reset} ${greenf}▒▒▒▒${reset} ${boldon}${greenfbright}▒▒${reset} ${yellowf}▒▒▒▒${reset} ${boldon}${yellowfbright}▒▒${reset} ${bluef}▒▒▒▒${reset} ${boldon}${bluefbright}▒▒${reset} ${purplef}▒▒▒▒${reset} ${boldon}${purplefbright}▒▒${reset} ${cyanf}▒▒▒▒${reset} ${boldon}${cyanfbright}▒▒${reset}
${redf}▒▒ ■${reset} ${boldon}${redfbright}▒▒${reset} ${greenf}▒▒ ■${reset} ${boldon}${greenfbright}▒▒${reset} ${yellowf}▒▒ ■${reset} ${boldon}${yellowfbright}▒▒${reset} ${bluef}▒▒ ■${reset} ${boldon}${bluefbright}▒▒${reset} ${purplef}▒▒ ■${reset} ${boldon}${purplefbright}▒▒${reset} ${cyanf}▒▒ ■${reset} ${boldon}${cyanfbright}▒▒${reset}
${redf}▒▒ ${reset}${boldon}${redfbright}▒▒▒▒${reset} ${greenf}▒▒ ${reset}${boldon}${greenfbright}▒▒▒▒${reset} ${yellowf}▒▒ ${reset}${boldon}${yellowfbright}▒▒▒▒${reset} ${bluef}▒▒ ${reset}${boldon}${bluefbright}▒▒▒▒${reset} ${purplef}▒▒ ${reset}${boldon}${purplefbright}▒▒▒▒${reset} ${cyanf}▒▒ ${reset}${boldon}${cyanfbright}▒▒▒▒${reset}
EOF

View File

@@ -0,0 +1,41 @@
#!/bin/bash
# ANSI color scheme script featuring Space Invaders
# Original: http://crunchbanglinux.org/forums/post/126921/#p126921
# Modified by lolilolicon
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
for i in {0..7}; do
printf -v fbright$i %b "\e[9${i}m"
done
bld=$'\e[1m'
rst=$'\e[0m'
cat << EOF
$f1 ▀▄ ▄▀ $f2 ▄▄▄████▄▄▄ $f3 ▄██▄ $f4 ▀▄ ▄▀ $f5 ▄▄▄████▄▄▄ $f6 ▄██▄ $rst
$f1 ▄█▀███▀█▄ $f2███▀▀██▀▀███ $f3▄█▀██▀█▄ $f4 ▄█▀███▀█▄ $f5███▀▀██▀▀███ $f6▄█▀██▀█▄$rst
$f1█▀███████▀█ $f2▀▀███▀▀███▀▀ $f3▀█▀██▀█▀ $f4█▀███████▀█ $f5▀▀███▀▀███▀▀ $f6▀█▀██▀█▀$rst
$f1▀ ▀▄▄ ▄▄▀ ▀ $f2 ▀█▄ ▀▀ ▄█▀ $f3▀▄ ▄▀ $f4▀ ▀▄▄ ▄▄▀ ▀ $f5 ▀█▄ ▀▀ ▄█▀ $f6▀▄ ▄▀$rst
$bld$fbright1▄ ▀▄ ▄▀ ▄ $fbright2 ▄▄▄████▄▄▄ $fbright3 ▄██▄ $fbright4▄ ▀▄ ▄▀ ▄ $fbright5 ▄▄▄████▄▄▄ $fbright6 ▄██▄ $rst
$bld$fbright1█▄█▀███▀█▄█ $fbright2███▀▀██▀▀███ $fbright3▄█▀██▀█▄ $fbright4█▄█▀███▀█▄█ $fbright5███▀▀██▀▀███ $fbright6▄█▀██▀█▄$rst
$bld$fbright1▀█████████▀ $fbright2▀▀▀██▀▀██▀▀▀ $fbright3▀▀█▀▀█▀▀ $fbright4▀█████████▀ $fbright5▀▀▀██▀▀██▀▀▀ $fbright6▀▀█▀▀█▀▀$rst
$bld$fbright1 ▄▀ ▀▄ $fbright2▄▄▀▀ ▀▀ ▀▀▄▄ $fbright3▄▀▄▀▀▄▀▄ $fbright4 ▄▀ ▀▄ $fbright5▄▄▀▀ ▀▀ ▀▀▄▄ $fbright6▄▀▄▀▀▄▀▄$rst
$f7▌$rst
$f7▌$rst
$f7 ▄█▄ $rst
$f7▄█████████▄$rst
$f7▀▀▀▀▀▀▀▀▀▀▀$rst
EOF

View File

@@ -0,0 +1,21 @@
#!/bin/bash
# Author: crshd
# Source: http://crunchbang.org/forums/viewtopic.php?pid=128584#p128584
echo
for f in {0..6}; do
echo -en "\033[$((f+41))m\033[$((f+30))m██▓▒░"
done
echo -en "\033[37m██\n"
echo
for f in {0..6}; do
echo -en "\033[$((f+41))m\033[1;$((f+90))m██▓▒░"
done
echo -en "\033[1;37m██"
echo -e "\033[0m"
echo

44
local_bin/color-scripts/square Executable file
View File

@@ -0,0 +1,44 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: muzieca
# Source: http://crunchbang.org/forums/viewtopic.php?pid=127509#p127509
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${redf}▀ █${reset} ${boldon}${redfbright}█ ▀${reset} ${greenf}▀ █${reset} ${boldon}${greenfbright}█ ▀${reset} ${yellowf}▀ █${reset} ${boldon}${yellowfbright}█ ▀${reset} ${bluef}▀ █${reset} ${boldon}${bluefbright}█ ▀${reset} ${purplef}▀ █${reset} ${boldon}${purplefbright}█ ▀${reset} ${cyanf}▀ █${reset} ${boldon}${cyanfbright}█ ▀${reset}
${redf}██${reset} ${boldon}${redfbright} ██${reset} ${greenf}██${reset} ${boldon}${greenfbright}██${reset} ${yellowf}██${reset} ${boldon}${yellowfbright}██${reset} ${bluef}██${reset} ${boldon}${bluefbright}██${reset} ${purplef}██${reset} ${boldon}${purplefbright}██${reset} ${cyanf}██${reset} ${boldon}${cyanfbright}██${reset}
${redf}▄ █${reset}${boldon}${redfbright} █ ▄ ${reset} ${greenf}▄ █ ${reset}${boldon}${greenfbright}█ ▄${reset} ${yellowf}▄ █ ${reset}${boldon}${yellowfbright}█ ▄${reset} ${bluef}▄ █ ${reset}${boldon}${bluefbright}█ ▄${reset} ${purplef}▄ █ ${reset}${boldon}${purplefbright}█ ▄${reset} ${cyanf}▄ █ ${reset}${boldon}${cyanfbright}█ ▄${reset}
EOF

54
local_bin/color-scripts/tanks Executable file
View File

@@ -0,0 +1,54 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Nintendo's Battle Tank
# Author: muzieca
# Source: http://crunchbang.org/forums/viewtopic.php?pid=127023#p127023
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${boldon}${redfbright} █ ${reset} ${boldon}${greenfbright} █ ${reset} ${boldon}${yellowfbright} █ ${reset} ${boldon}${bluefbright} █ ${reset} ${boldon}${purplefbright} █ ${reset} ${boldon}${cyanfbright} █ ${reset}
${boldon}${redfbright}▄▄ █ ▄▄${reset} ${boldon}${greenfbright}▄▄ █ ▄▄${reset} ${boldon}${yellowfbright}▄▄ █ ▄▄${reset} ${boldon}${bluefbright}▄▄ █ ▄▄${reset} ${boldon}${purplefbright}▄▄ █ ▄▄${reset} ${boldon}${cyanfbright}▄▄ █ ▄▄${reset}
${boldon}${redfbright}███▀▀▀███${reset} ${boldon}${greenfbright}███▀▀▀███${reset} ${boldon}${yellowfbright}███▀▀▀███${reset} ${boldon}${bluefbright}███▀▀▀███${reset} ${boldon}${purplefbright}███▀▀▀███${reset} ${boldon}${cyanfbright}███▀▀▀███${reset}
${boldon}${redfbright}███ █ ███${reset} ${boldon}${greenfbright}███ █ ███${reset} ${boldon}${yellowfbright}███ █ ███${reset} ${boldon}${bluefbright}███ █ ███${reset} ${boldon}${purplefbright}███ █ ███${reset} ${boldon}${cyanfbright}███ █ ███${reset}
${boldon}${redfbright}██ ▀▀▀ ██${reset} ${boldon}${greenfbright}██ ▀▀▀ ██${reset} ${boldon}${yellowfbright}██ ▀▀▀ ██${reset} ${boldon}${bluefbright}██ ▀▀▀ ██${reset} ${boldon}${purplefbright}██ ▀▀▀ ██${reset} ${boldon}${cyanfbright}██ ▀▀▀ ██${reset}
${redf} █ ${reset} ${greenf} █ ${reset} ${yellowf} █ ${reset} ${bluef} █ ${reset} ${purplef} █ ${reset} ${cyanf} █ ${reset}
${redf}▄▄ █ ▄▄${reset} ${greenf}▄▄ █ ▄▄${reset} ${yellowf}▄▄ █ ▄▄${reset} ${bluef}▄▄ █ ▄▄${reset} ${purplef}▄▄ █ ▄▄${reset} ${cyanf}▄▄ █ ▄▄${reset}
${redf}███▀▀▀███${reset} ${greenf}███▀▀▀███${reset} ${yellowf}███▀▀▀███${reset} ${bluef}███▀▀▀███${reset} ${purplef}███▀▀▀███${reset} ${cyanf}███▀▀▀███${reset}
${redf}███ █ ███${reset} ${greenf}███ █ ███${reset} ${yellowf}███ █ ███${reset} ${bluef}███ █ ███${reset} ${purplef}███ █ ███${reset} ${cyanf}███ █ ███${reset}
${redf}██ ▀▀▀ ██${reset} ${greenf}██ ▀▀▀ ██${reset} ${yellowf}██ ▀▀▀ ██${reset} ${bluef}██ ▀▀▀ ██${reset} ${purplef}██ ▀▀▀ ██${reset} ${cyanf}██ ▀▀▀ ██${reset}
EOF

32
local_bin/color-scripts/thebat Executable file
View File

@@ -0,0 +1,32 @@
#!/bin/bash
# ANSI color scheme script by pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=151601#p151601
# Initializing mod by lolilolicon from Archlinux
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
bld=$'\e[1m'
rst=$'\e[0m'
inv=$'\e[7m'
cat << EOF
$f3 ██████████████████████████████████████
$f3 ██████████████████████████████████████████
$f3 ██████ ████████████████████████████ ██████
$f3 █████ ████████████ ████ ████████████ █████
$f3 ███ ████████████ ████████████ ███
$f3 ███ ███
$f3 ███ ███
$f3 ███ █████████ ████ ████ █████████ ███
$f3 █████ ███████████████ ███████████████ █████
$f3 ██████ ████████████████████████████ ██████
$f3 ██████████████████████████████████████████
$f3 ██████████████████████████████████████
$rst
EOF

52
local_bin/color-scripts/thebat2 Executable file
View File

@@ -0,0 +1,52 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=151601#p151601
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
initializeANSI
cat << EOF
${redf} ▄█▀ █ █ ▀█▄ ${greenf} ▄█▀ █ █ ▀█▄ ${yellowf} ▄█▀ █ █ ▀█▄ ${bluef} ▄█▀ █ █ ▀█▄ ${purplef} ▄█▀ █ █ ▀█▄ ${cyanf} ▄█▀ █ █ ▀█▄
${redf}███ ███ ███ ${greenf}███ ███ ███ ${yellowf}███ ███ ███ ${bluef}███ ███ ███ ${purplef}███ ███ ███ ${cyanf}███ ███ ███
${redf}█████████████ ${greenf}█████████████ ${yellowf}█████████████ ${bluef}█████████████ ${purplef}█████████████ ${cyanf}█████████████
${redf} ▀██▄ ▄██▀ ${greenf} ▀██▄ ▄██▀ ${yellowf} ▀██▄ ▄██▀ ${bluef} ▀██▄ ▄██▀ ${purplef} ▀██▄ ▄██▀ ${cyanf} ▀██▄ ▄██▀
${boldon}
${redfbright} ▄█▀ █ █ ▀█▄ ${greenfbright} ▄█▀ █ █ ▀█▄ ${yellowfbright} ▄█▀ █ █ ▀█▄ ${bluefbright} ▄█▀ █ █ ▀█▄ ${purplefbright} ▄█▀ █ █ ▀█▄ ${cyanfbright} ▄█▀ █ █ ▀█▄
${redfbright}███ ███ ███ ${greenfbright}███ ███ ███ ${yellowfbright}███ ███ ███ ${bluefbright}███ ███ ███ ${purplefbright}███ ███ ███ ${cyanfbright}███ ███ ███
${redfbright}█████████████ ${greenfbright}█████████████ ${yellowfbright}█████████████ ${bluefbright}█████████████ ${purplefbright}█████████████ ${cyanfbright}█████████████
${redfbright} ▀██▄ ▄██▀ ${greenfbright} ▀██▄ ▄██▀ ${yellowfbright} ▀██▄ ▄██▀ ${bluefbright} ▀██▄ ▄██▀ ${purplefbright} ▀██▄ ▄██▀ ${cyanfbright} ▀██▄ ▄██▀
${reset}
EOF

View File

@@ -0,0 +1,58 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=129265#p129265
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
# ****************************** Building blocks: █ ▓ ▒ ░ ▄ ▀ ▐ ▌ ● ═ ║ ╔ ╦ ╗ ╚ ╩ ╝ ■ ▬ ▲ ▼ ◄ ►
initializeANSI
cat << EOF
${invon}
${redf} ▄█ █▄ ${greenf} ▄▄ ▄▄ ${yellowf} ▄▄ ▄▄ ${bluef} ▄▄ ▄▄ ${purplef} ▄▄ ▄▄ ${cyanf} ▄█ █▄
${redf} ▄█▀ ▄▄▄ ▀█▄ ${greenf} ▄█▀ ▄▄▄ ▀█▄ ${yellowf} ▄█▀ ▄▄▄ ▀█▄ ${bluef} ▄█▀ ▄▄▄ ▀█▄ ${purplef} ▄█▀ ▄▄▄ ▀█▄ ${cyanf} ▄█▀ ▄▄▄ ▀█▄
${redf} ██▄▄██▀██▄▄██ ${greenf} ██▄▄██▀██▄▄██ ${yellowf} ██▄▄██▀██▄▄██ ${bluef} ██▄▄██▀██▄▄██ ${purplef} ██▄▄██▀██▄▄██ ${cyanf} ██▄▄██▀██▄▄██
${redf} ██▀▀█████▀▀██ ${greenf} ██▀▀█████▀▀██ ${yellowf} ██▀▀█████▀▀██ ${bluef} ██▀▀█████▀▀██ ${purplef} ██▀▀█████▀▀██ ${cyanf} ██▀▀█████▀▀██
${redf} ▀█▄ ▀▀▀ ▄█▀ ${greenf} ▀█▄ ▀▀▀ ▄█▀ ${yellowf} ▀█▄ ▀▀▀ ▄█▀ ${bluef} ▀█▄ ▀▀▀ ▄█▀ ${purplef} ▀█▄ ▀▀▀ ▄█▀ ${cyanf} ▀█▄ ▀▀▀ ▄█▀
${redf} ▀█ █▀ ${greenf} ▀▀ ▀▀ ${yellowf} ▀▀ ▀▀ ${bluef} ▀▀ ▀▀ ${purplef} ▀▀ ▀▀ ${cyanf} ▀█ █▀
${boldon}${invon}
${redfbright} ▄█ █▄ ${greenfbright} ▄▄ ▄▄ ${yellowfbright} ▄▄ ▄▄ ${bluefbright} ▄▄ ▄▄ ${purplefbright} ▄▄ ▄▄ ${cyanfbright} ▄█ █▄
${redfbright} ▄█▀ ▄▄▄ ▀█▄ ${greenfbright} ▄█▀ ▄▄▄ ▀█▄ ${yellowfbright} ▄█▀ ▄▄▄ ▀█▄ ${bluefbright} ▄█▀ ▄▄▄ ▀█▄ ${purplefbright} ▄█▀ ▄▄▄ ▀█▄ ${cyanfbright} ▄█▀ ▄▄▄ ▀█▄
${redfbright} ██▄▄██▀██▄▄██ ${greenfbright} ██▄▄██▀██▄▄██ ${yellowfbright} ██▄▄██▀██▄▄██ ${bluefbright} ██▄▄██▀██▄▄██ ${purplefbright} ██▄▄██▀██▄▄██ ${cyanfbright} ██▄▄██▀██▄▄██
${redfbright} ██▀▀█████▀▀██ ${greenfbright} ██▀▀█████▀▀██ ${yellowfbright} ██▀▀█████▀▀██ ${bluefbright} ██▀▀█████▀▀██ ${purplefbright} ██▀▀█████▀▀██ ${cyanfbright} ██▀▀█████▀▀██
${redfbright} ▀█▄ ▀▀▀ ▄█▀ ${greenfbright} ▀█▄ ▀▀▀ ▄█▀ ${yellowfbright} ▀█▄ ▀▀▀ ▄█▀ ${bluefbright} ▀█▄ ▀▀▀ ▄█▀ ${purplefbright} ▀█▄ ▀▀▀ ▄█▀ ${cyanfbright} ▀█▄ ▀▀▀ ▄█▀
${redfbright} ▀█ █▀ ${greenfbright} ▀▀ ▀▀ ${yellowfbright} ▀▀ ▀▀ ${bluefbright} ▀▀ ▀▀ ${purplefbright} ▀▀ ▀▀ ${cyanfbright} ▀█ █▀
${reset}
EOF

View File

@@ -0,0 +1,62 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Original Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=129265#p129265
# Further Modified by: Chef-Stark
# This is the same tiefighter1 color-script minus the inverted colors
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
# ****************************** Building blocks: █ ▓ ▒ ░ ▄ ▀ ▐ ▌ ● ═ ║ ╔ ╦ ╗ ╚ ╩ ╝ ■ ▬ ▲ ▼ ◄ ►
initializeANSI
cat << EOF
${redf} ▄█ █▄ ${greenf} ▄▄ ▄▄ ${yellowf} ▄▄ ▄▄ ${bluef} ▄▄ ▄▄ ${purplef} ▄▄ ▄▄ ${cyanf} ▄█ █▄
${redf} ▄█▀ ▄▄▄ ▀█▄ ${greenf} ▄█▀ ▄▄▄ ▀█▄ ${yellowf} ▄█▀ ▄▄▄ ▀█▄ ${bluef} ▄█▀ ▄▄▄ ▀█▄ ${purplef} ▄█▀ ▄▄▄ ▀█▄ ${cyanf} ▄█▀ ▄▄▄ ▀█▄
${redf} ██▄▄██▀██▄▄██ ${greenf} ██▄▄██▀██▄▄██ ${yellowf} ██▄▄██▀██▄▄██ ${bluef} ██▄▄██▀██▄▄██ ${purplef} ██▄▄██▀██▄▄██ ${cyanf} ██▄▄██▀██▄▄██
${redf} ██▀▀█████▀▀██ ${greenf} ██▀▀█████▀▀██ ${yellowf} ██▀▀█████▀▀██ ${bluef} ██▀▀█████▀▀██ ${purplef} ██▀▀█████▀▀██ ${cyanf} ██▀▀█████▀▀██
${redf} ▀█▄ ▀▀▀ ▄█▀ ${greenf} ▀█▄ ▀▀▀ ▄█▀ ${yellowf} ▀█▄ ▀▀▀ ▄█▀ ${bluef} ▀█▄ ▀▀▀ ▄█▀ ${purplef} ▀█▄ ▀▀▀ ▄█▀ ${cyanf} ▀█▄ ▀▀▀ ▄█▀
${redf} ▀█ █▀ ${greenf} ▀▀ ▀▀ ${yellowf} ▀▀ ▀▀ ${bluef} ▀▀ ▀▀ ${purplef} ▀▀ ▀▀ ${cyanf} ▀█ █▀
${boldon}
${redfbright} ▄█ █▄ ${greenfbright} ▄▄ ▄▄ ${yellowfbright} ▄▄ ▄▄ ${bluefbright} ▄▄ ▄▄ ${purplefbright} ▄▄ ▄▄ ${cyanfbright} ▄█ █▄
${redfbright} ▄█▀ ▄▄▄ ▀█▄ ${greenfbright} ▄█▀ ▄▄▄ ▀█▄ ${yellowfbright} ▄█▀ ▄▄▄ ▀█▄ ${bluefbright} ▄█▀ ▄▄▄ ▀█▄ ${purplefbright} ▄█▀ ▄▄▄ ▀█▄ ${cyanfbright} ▄█▀ ▄▄▄ ▀█▄
${redfbright} ██▄▄██▀██▄▄██ ${greenfbright} ██▄▄██▀██▄▄██ ${yellowfbright} ██▄▄██▀██▄▄██ ${bluefbright} ██▄▄██▀██▄▄██ ${purplefbright} ██▄▄██▀██▄▄██ ${cyanfbright} ██▄▄██▀██▄▄██
${redfbright} ██▀▀█████▀▀██ ${greenfbright} ██▀▀█████▀▀██ ${yellowfbright} ██▀▀█████▀▀██ ${bluefbright} ██▀▀█████▀▀██ ${purplefbright} ██▀▀█████▀▀██ ${cyanfbright} ██▀▀█████▀▀██
${redfbright} ▀█▄ ▀▀▀ ▄█▀ ${greenfbright} ▀█▄ ▀▀▀ ▄█▀ ${yellowfbright} ▀█▄ ▀▀▀ ▄█▀ ${bluefbright} ▀█▄ ▀▀▀ ▄█▀ ${purplefbright} ▀█▄ ▀▀▀ ▄█▀ ${cyanfbright} ▀█▄ ▀▀▀ ▄█▀
${redfbright} ▀█ █▀ ${greenfbright} ▀▀ ▀▀ ${yellowfbright} ▀▀ ▀▀ ${bluefbright} ▀▀ ▀▀ ${purplefbright} ▀▀ ▀▀ ${cyanfbright} ▀█ █▀
${reset}
EOF

View File

@@ -0,0 +1,46 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=129265#p129265
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
# ****************************** Building blocks: █ ▓ ▒ ░ ▄ ▀ ▐ ▌ ● ═ ║ ╔ ╦ ╗ ╚ ╩ ╝ ■ ▬ ▲ ▼ ◄ ►
initializeANSI
cat << EOF
${greenf}█ █ ${redf}█ █ ${bluef}█ █ ${purplef}█ █ ${cyanf}█ █
${greenf}█ ▄▄▄ █ ${redf}█ ▄▄▄ █ ${bluef}█ ▄▄▄ █ ${purplef}█ ▄▄▄ █ ${cyanf}█ ▄▄▄ █
${greenf}█▄▄██▀██▄▄█ ${redf}█▄▄██▀██▄▄█ ${bluef}█▄▄██▀██▄▄█ ${purplef}█▄▄██▀██▄▄█ ${cyanf}█▄▄██▀██▄▄█
${greenf}█▀▀█████▀▀█ ${redf}█▀▀█████▀▀█ ${bluef}█▀▀█████▀▀█ ${purplef}█▀▀█████▀▀█ ${cyanf}█▀▀█████▀▀█
${greenf}█ ▀▀▀ █ ${redf}█ ▀▀▀ █ ${bluef}█ ▀▀▀ █ ${purplef}█ ▀▀▀ █ ${cyanf}█ ▀▀▀ █
${greenf}█ █ ${redf}█ █ ${bluef}█ █ ${purplef}█ █ ${cyanf}█ █
${reset}
EOF

View File

@@ -0,0 +1,57 @@
#!/bin/sh
# ANSI Color -- use these variables to easily have different color
# and format output. Make sure to output the reset sequence after
# colors (f = foreground, b = background), and use the 'off'
# feature for anything you turn on.
# Author: pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=129265#p129265
initializeANSI()
{
esc=""
blackf="${esc}[30m"; redf="${esc}[31m"; greenf="${esc}[32m"
yellowf="${esc}[33m" bluef="${esc}[34m"; purplef="${esc}[35m"
cyanf="${esc}[36m"; whitef="${esc}[37m"
blackfbright="${esc}[90m"; redfbright="${esc}[91m"; greenfbright="${esc}[92m"
yellowfbright="${esc}[93m" bluefbright="${esc}[94m"; purplefbright="${esc}[95m"
cyanfbright="${esc}[96m"; whitefbright="${esc}[97m"
blackb="${esc}[40m"; redb="${esc}[41m"; greenb="${esc}[42m"
yellowb="${esc}[43m" blueb="${esc}[44m"; purpleb="${esc}[45m"
cyanb="${esc}[46m"; whiteb="${esc}[47m"
boldon="${esc}[1m"; boldoff="${esc}[22m"
italicson="${esc}[3m"; italicsoff="${esc}[23m"
ulon="${esc}[4m"; uloff="${esc}[24m"
invon="${esc}[7m"; invoff="${esc}[27m"
reset="${esc}[0m"
}
# note in this first use that switching colors doesn't require a reset
# first - the new color overrides the old one.
# ****************************** Building blocks: █ ▓ ▒ ░ ▄ ▀ ▐ ▌ ● ═ ║ ╔ ╦ ╗ ╚ ╩ ╝ ■ ▬ ▲ ▼ ◄ ►
initializeANSI
cat << EOF
${redf} █ █ ${greenf}█ █ ${yellowf}█ █ ${bluef}█ █ ${purplef}█ █ ${cyanf}█ █
${redf} █ ▄▄▄ █ ${greenf}█ ▄▄▄ █ ${yellowf}█ ▄▄▄ █ ${bluef}█ ▄▄▄ █ ${purplef}█ ▄▄▄ █ ${cyanf}█ ▄▄▄ █
${redf} █▄▄██▀██▄▄█ ${greenf}█▄▄██▀██▄▄█ ${yellowf}█▄▄██▀██▄▄█ ${bluef}█▄▄██▀██▄▄█ ${purplef}█▄▄██▀██▄▄█ ${cyanf}█▄▄██▀██▄▄█
${redf} █▀▀█████▀▀█ ${greenf}█▀▀█████▀▀█ ${yellowf}█▀▀█████▀▀█ ${bluef}█▀▀█████▀▀█ ${purplef}█▀▀█████▀▀█ ${cyanf}█▀▀█████▀▀█
${redf} █ ▀▀▀ █ ${greenf}█ ▀▀▀ █ ${yellowf}█ ▀▀▀ █ ${bluef}█ ▀▀▀ █ ${purplef}█ ▀▀▀ █ ${cyanf}█ ▀▀▀ █
${redf} █ █ ${greenf}█ █ ${yellowf}█ █ ${bluef}█ █ ${purplef}█ █ ${cyanf}█ █
${boldon}
${redfbright} █ █ ${greenfbright}█ █ ${yellowfbright}█ █ ${bluefbright}█ █ ${purplefbright}█ █ ${cyanfbright}█ █
${redfbright} █ ▄▄▄ █ ${greenfbright}█ ▄▄▄ █ ${yellowfbright}█ ▄▄▄ █ ${bluefbright}█ ▄▄▄ █ ${purplefbright}█ ▄▄▄ █ ${cyanfbright}█ ▄▄▄ █
${redfbright} █▄▄██▀██▄▄█ ${greenfbright}█▄▄██▀██▄▄█ ${yellowfbright}█▄▄██▀██▄▄█ ${bluefbright}█▄▄██▀██▄▄█ ${purplefbright}█▄▄██▀██▄▄█ ${cyanfbright}█▄▄██▀██▄▄█
${redfbright} █▀▀█████▀▀█ ${greenfbright}█▀▀█████▀▀█ ${yellowfbright}█▀▀█████▀▀█ ${bluefbright}█▀▀█████▀▀█ ${purplefbright}█▀▀█████▀▀█ ${cyanfbright}█▀▀█████▀▀█
${redfbright} █ ▀▀▀ █ ${greenfbright}█ ▀▀▀ █ ${yellowfbright}█ ▀▀▀ █ ${bluefbright}█ ▀▀▀ █ ${purplefbright}█ ▀▀▀ █ ${cyanfbright}█ ▀▀▀ █
${redfbright} █ █ ${greenfbright}█ █ ${yellowfbright}█ █ ${bluefbright}█ █ ${purplefbright}█ █ ${cyanfbright}█ █
${reset}
EOF

26
local_bin/color-scripts/zwaves Executable file
View File

@@ -0,0 +1,26 @@
#!/bin/bash
# ANSI color scheme script by pfh
# Source: http://crunchbang.org/forums/viewtopic.php?pid=141044#p141044
# Initializing mod by lolilolicon from Archlinux
f=3 b=4
for j in f b; do
for i in {0..7}; do
printf -v $j$i %b "\e[${!j}${i}m"
done
done
for i in {0..7}; do
printf -v fbright$i %b "\e[9${i}m"
done
bld=$'\e[1m'
rst=$'\e[0m'
inv=$'\e[7m'
cat << EOF
$f1▀■▄ $f2▀■▄ $f3▀■▄ $f4▀■▄ $f5▀■▄ $f6▀■▄
$bld$fbright1▀■▄ $fbright2▀■▄ $fbright3▀■▄ $fbright4▀■▄ $fbright5▀■▄ $fbright6▀■▄$rst
EOF

160
local_bin/colorscript Executable file
View File

@@ -0,0 +1,160 @@
#!/bin/bash
# Simple CLI for shell-color-scripts
if [[ "$DEV" -gt 0 ]]; then
DIR_COLORSCRIPTS="./colorscripts"
else
DIR_COLORSCRIPTS="$HOME/.local/bin/color-scripts/"
fi
if command -v find &>/dev/null; then
LS_CMD="$(command -v find) ${DIR_COLORSCRIPTS} -maxdepth 1 -type f"
LS_CMD_B="$(command -v find) ${DIR_COLORSCRIPTS}/blacklisted -maxdepth 1 -type f"
else
LS_CMD="$(command -v ls) ${DIR_COLORSCRIPTS}"
LS_CMD_B="$(command -v ls) ${DIR_COLORSCRIPTS}/blacklisted"
fi
list_colorscripts="$($LS_CMD | xargs -I $ basename $ | cut -d ' ' -f 1 | nl)"
length_colorscripts="$($LS_CMD | wc -l)"
list_blacklist="$($LS_CMD_B 2>/dev/null | xargs -I $ basename $ | cut -d ' ' -f 1 | nl || "")"
length_blacklist="$($LS_CMD_B 2>/dev/null | wc -l || 0)"
fmt_help=" %-20s\t%-54s\n"
function _help() {
echo "Description: A collection of terminal color scripts."
echo ""
echo "Usage: colorscript [OPTION] [SCRIPT NAME/INDEX]"
printf "${fmt_help}" \
"-h, --help, help" "Print this help." \
"-l, --list, list" "List all installed color scripts." \
"-r, --random, random" "Run a random color script." \
"-e, --exec, exec" "Run a specified color script by SCRIPT NAME or INDEX." \
"-b, --blacklist, blacklist" "Blacklist a color script by SCRIPT NAME or INDEX." \
"-u, --unblacklist, unblacklist" "Unblacklist a color script by SCRIPT NAME or INDEX." \
"-a, --all, all" "List the outputs of all colorscripts with their SCRIPT NAME"
}
function _list() {
echo "There are "$($LS_CMD | wc -l)" installed color scripts:"
echo "${list_colorscripts}"
}
function _list_blacklist() {
echo "There are $length_blacklist blacklisted color scripts:"
echo "${list_blacklist}"
}
function _random() {
declare -i random_index=$RANDOM%$length_colorscripts
[[ $random_index -eq 0 ]] && random_index=1
random_colorscript="$(echo "${list_colorscripts}" | sed -n ${random_index}p |
tr -d ' ' | tr '\t' ' ' | cut -d ' ' -f 2)"
# echo "${random_colorscript}"
exec "${DIR_COLORSCRIPTS}/${random_colorscript}"
}
function ifhascolorscipt() {
[[ -e "${DIR_COLORSCRIPTS}/$1" ]] && echo "Has this color script."
}
function _run_by_name() {
if [[ "$1" == "random" ]]; then
_random
elif [[ -n "$(ifhascolorscipt "$1")" ]]; then
exec "${DIR_COLORSCRIPTS}/$1"
else
echo "Input error, Don't have color script named $1."
exit 1
fi
}
function _run_by_index() {
if [[ "$1" -gt 0 && "$1" -le "${length_colorscripts}" ]]; then
colorscript="$(echo "${list_colorscripts}" | sed -n ${1}p |
tr -d ' ' | tr '\t' ' ' | cut -d ' ' -f 2)"
exec "${DIR_COLORSCRIPTS}/${colorscript}"
else
echo "Input error, Don't have color script indexed $1."
exit 1
fi
}
function _run_colorscript() {
if [[ "$1" =~ ^[0-9]+$ ]]; then
_run_by_index "$1"
else
_run_by_name "$1"
fi
}
function _run_all() {
for s in $DIR_COLORSCRIPTS/*; do
echo "$(echo $s | awk -F '/' '{print $NF}'):"
echo "$($s)"
echo
done
}
function _blacklist_colorscript() { # by name only
if [ ! -d "${DIR_COLORSCRIPTS}/blacklisted" ]; then
sudo mkdir "${DIR_COLORSCRIPTS}/blacklisted"
fi
sudo mv "${DIR_COLORSCRIPTS}/$1" "${DIR_COLORSCRIPTS}/blacklisted"
}
function _unblacklist_colorscript() { # by name only
if [ -f "${DIR_COLORSCRIPTS}/blacklisted/$1" ]; then
sudo mv "${DIR_COLORSCRIPTS}/blacklisted/$1" "${DIR_COLORSCRIPTS}"
else
echo "Input error. Script $1 is not blacklisted!"
fi
}
case "$#" in
0)
_help
;;
1)
case "$1" in
-h | --help | help)
_help
;;
-l | --list | list)
_list
;;
-b | --blacklist | blacklist)
_list_blacklist
;;
-r | --random | random)
_random
;;
-a | --all | all)
_run_all
;;
*)
echo "Input error."
exit 1
;;
esac
;;
2)
if [[ "$1" == "-e" || "$1" == "--exec" || "$1" == "exec" ]]; then
_run_colorscript "$2"
elif [[ "$1" == "-b" || "$1" == "--blacklist" || "$1" == "blacklist" ]]; then
_blacklist_colorscript "$2"
elif [[ "$1" == "-u" || "$1" == "--unblacklist" || "$1" == "unblacklist" ]]; then
_unblacklist_colorscript "$2"
else
echo "Input error."
exit 1
fi
;;
*)
echo "Input error, too many arguments."
exit 1
;;
esac

2
local_bin/deleteOrphans Executable file
View File

@@ -0,0 +1,2 @@
#!/bin/bash
sudo pacman -Qtdq | sudo pacman -Rns -

105
local_bin/dev Executable file
View File

@@ -0,0 +1,105 @@
#!/bin/bash
# Constants
gfetch="gfetch -d churn contributors --no-color-palette --no-title"
ls="eza --header --icons --all --color=always --group-directories-first --hyperlink"
projects_dir="$HOME/dev"
projects_command="find $projects_dir -mindepth 2 -maxdepth 2 -type d"
fzf_command="fzf --height=100%"
yaml_config() {
local yaml_file="$1"
local dest_dir="$2"
local dest_yaml_file="$dest_dir/.tmuxp.yaml"
cp "$yaml_file" "$dest_yaml_file"
sed -i "1i start_directory: $dest_dir\nsession_name: $tab_title" "$dest_yaml_file"
}
tmuxp_load() {
if [[ -n "$TMUX" ]]; then
tmuxp load -d "$selected_dir"
zoxide_score
else
tmuxp load "$selected_dir"
zoxide_score
fi
tmux switch-client -t "$tab_title"
}
handle_tmuxp() {
if [[ -f "$selected_dir/.tmuxp.yaml" ]]; then
tmuxp_load
else
if [[ -d "$XDG_CONFIG_HOME/tmuxp" ]]; then
local yaml_file=$(find "$XDG_CONFIG_HOME/tmuxp" -name "*.yaml" -print0 |
xargs -0 -n 1 basename | sed 's/\.yaml$//' |
fzf --preview "bat --style=numbers --color=always $XDG_CONFIG_HOME/tmuxp/{}.yaml" \
--prompt="Select a session file: ")
if [[ -n "$yaml_file" ]]; then
yaml_config "$XDG_CONFIG_HOME/tmuxp/$yaml_file.yaml" "$selected_dir"
tmuxp_load
else
handle_tmux
fi
fi
fi
}
handle_tmux() {
if [[ -n "$TMUX" ]]; then
tmux new-session -ds "$tab_title" -c "$selected_dir"
tmux switch-client -t "$tab_title"
else
tmux new-session -s "$tab_title" -c "$selected_dir"
fi
zoxide_score
}
handle_kitty() {
kitty @ set-tab-title "$tab_title"
cd "$selected_dir"
zoxide_score
$gfetch
$ls
}
handle_editor() {
if [[ "$EDITOR" == "nvim" || "$EDITOR" == "vim" ]]; then
echo "terminal"
elif [[ "$EDITOR" == "code" || "$EDITOR" == "codium" ]]; then
echo "gui"
fi
}
zoxide_score() {
if command -v zoxide &>/dev/null; then
zoxide add "$selected_dir"
fi
}
selected_dir=$($projects_command | $fzf_command --prompt='Select a directory: ' \
--header='CTRL-P: Projects / CTRL-Z: Zoxide' \
--bind "ctrl-p:reload($projects_command)" \
--bind "ctrl-z:reload(zoxide query -l)" \
--preview "$gfetch {} 2>&1 | grep -v 'Error: Could not find a git repository in' || true && $ls {} || $ls {}")
tab_title=$(basename "$selected_dir")
if [[ -n "$selected_dir" ]]; then
editor_type=$(handle_editor)
if [[ $editor_type == "terminal" ]]; then
if command -v tmux &>/dev/null; then
if command -v tmuxp &>/dev/null; then
handle_tmuxp
else
handle_tmux
fi
elif [[ "$TERM" == "xterm-kitty" ]]; then
handle_kitty
fi
else
$EDITOR -r "$selected_dir"
zoxide_score
fi
fi

87
local_bin/downloadMedia Executable file
View File

@@ -0,0 +1,87 @@
#!/bin/bash
image_folder="$HOME/pictures/"
video_folder="$HOME/videos/"
# Utils
notify() {
notify-send "Media Download" "$1" -i ~/.local/share/icons/Catppuccin-SE/64x64/mimetypes/application-x-partial-download.svg --app-name=gallery-dl
}
notify_error() {
notify-send "Media Download" "$1" -u critical -i ~/.local/share/icons/Catppuccin-SE/64x64/mimetypes/application-x-partial-download.svg --app-name=gallery-dl
}
download_images() {
gallery-dl -d "$image_folder" --download-archive "$image_folder/{$1}/archive.sqlite3" "$2" --filter "$3"
}
download_videos() {
gallery-dl -d "$video_folder" --download-archive "$video_folder/{$1}/archive.sqlite3" "$2" --filter "$3"
}
# Download Sites
download_pinterest() {
download_images "pinterest" "$1" "extension not in ('mp4', 'gif')"
download_videos "pinterest" "$1" "extension in ('mp4', 'gif')"
notify "Pinterest ($1) Complete"
}
download_pixiv() {
download_images "pixiv" "$1" "extension not in ('mp4', 'gif')"
notify "Pixiv ($1) Complete"
}
download_twitter() {
download_images "twitter" "$1" "extension not in ('mp4', 'gif')"
download_videos "twitter" "$1" "extension in ('mp4', 'gif')"
notify "Twitter ($1) Complete"
}
download_reddit() {
download_images "reddit" "$1" "extension not in ('mp4')"
download_videos "reddit" "$1" "extension in ('mp4')"
notify "Reddit ($1) Complete"
}
download_unknown_site() {
download_images "$1" "extension not in ('mp4', 'gif')"
download_videos "$1" "extension in ('mp4', 'gif')"
notify "$1 Complete"
}
if ! command -v gallery-dl &>/dev/null; then
notify_error "gallery-dl is not installed"
exit 1
fi
url_file="$HOME/.gallery-dl/urls.txt"
if [ ! -f "$url_file" ]; then
notify_error "URl file does not exist"
exit 1
fi
notify "Started Download..."
while IFS= read -r url; do
case "$url" in
*pinterest.com*)
download_pinterest "$url"
;;
*pixiv.net*)
download_pixiv "$url"
;;
*x.com*)
download_twitter "$url"
;;
*reddit.com*)
download_reddit "$url"
;;
*)
download_unknown_site "$url"
;;
esac
done <"$url_file"
notify "Media Download Complete"

25
local_bin/downloadSpotify Executable file
View File

@@ -0,0 +1,25 @@
#!/bin/bash
notify() {
notify-send "Spotdl Sync" "$1" --icon=spotify --app-name=Spotify
}
if ! command -v spotdl &>/dev/null; then
notify "Error: spotdl is not installed"
exit 1
fi
MUSIC_FOLDER="$HOME/music/listen-to"
notify "Started syncing..."
while IFS= read -r -d '' SPOTDL_FILE; do
if [[ -f "$SPOTDL_FILE" && "$SPOTDL_FILE" == *.spotdl ]]; then
FOLDER_NAME=$(basename "$(dirname "$SPOTDL_FILE")")
cd "$(dirname "$SPOTDL_FILE")" || continue
spotdl sync --user-auth "$(basename "$SPOTDL_FILE")"
notify "Synced $FOLDER_NAME"
fi
done < <(find "$MUSIC_FOLDER" -mindepth 1 -maxdepth 3 -type f -name '*.spotdl' -print0)
notify "Spotdl Sync Complete"

BIN
local_bin/genact Executable file

Binary file not shown.

13
local_bin/gitignore Executable file
View File

@@ -0,0 +1,13 @@
#!/bin/bash
function __gi() {
curl -L -s https://www.gitignore.io/api/"$@"
}
IFS=","
selected_profiles=$(for item in $(__gi list); do echo $item; done | fzf --multi --ansi | paste -s -d "," -)
if [ -n "$selected_profiles" ]; then
echo "$selected_profiles" | { read result && __gi "$result" > .gitignore; echo "Created .gitignore"; }
fi

20
local_bin/ignore Executable file
View File

@@ -0,0 +1,20 @@
#!/bin/sh
function __gi() {
curl -L -s https://www.gitignore.io/api/"$@"
}
if [ "$#" -eq 0 ]; then
IFS+=","
result=$(for item in $(__gi list); do
echo $item
done | fzf --multi --ansi | paste -s -d "," -)
if [ -n "$result" ]; then
__gi "$result" > .gitignore
echo ".gitignore created: $result"
fi
else
__gi "$@" > .gitignore
echo ".gitignore created: $@"
fi

View File

@@ -0,0 +1,9 @@
#!/bin/bash
if [ -z "$1" ]; then
exit 1
fi
cat "$1" | while read extension || [[ -n $extension ]]; do
vscodium --install-extension "$extension" --force
done

12
local_bin/installYay Executable file
View File

@@ -0,0 +1,12 @@
#!/bin/bash
sudo pacman -Syu
mkdir /tmp/yay
cd /tmp/yay
curl -OJ 'https://aur.archlinux.org/cgit/aur.git/plain/PKGBUILD?h=yay'
makepkg -si
cd
rm -rf /tmp/yay
yay --version

385
local_bin/pipes Executable file
View File

@@ -0,0 +1,385 @@
#!/bin/bash
# pipes.sh: Animated pipes terminal screensaver.
# https://github.com/pipeseroni/pipes.sh
#
# Copyright (c) 2015-2018 Pipeseroni/pipes.sh contributors
# Copyright (c) 2013-2015 Yu-Jie Lin
# Copyright (c) 2010 Matthew Simpson
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in
# all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
VERSION=1.3.0
M=32768 # Bash RANDOM maximum + 1
p=1 # number of pipes
f=75 # frame rate
s=13 # probability of straight fitting
r=2000 # characters limit
t=0 # iteration counter for -r character limit
w=80 # terminal size
h=24
# ab -> sets[][idx] = a*4 + b
# 0: up, 1: right, 2: down, 3: left
# 00 means going up , then going up -> ┃
# 12 means going right, then going down -> ┓
sets=(
"┃┏ ┓┛━┓ ┗┃┛┗ ┏━"
"│╭ ╮╯─╮ ╰│╯╰ ╭─"
"│┌ ┐┘─┐ └│┘└ ┌─"
"║╔ ╗╝═╗ ╚║╝╚ ╔═"
"|+ ++-+ +|++ +-"
"|/ \/-\ \|/\ /-"
".. .... .... .."
".o oo.o o.oo o."
"-\ /\|/ /-\/ \|" # railway
"╿┍ ┑┚╼┒ ┕╽┙┖ ┎╾" # knobby pipe
)
SETS=() # rearranged all pipe chars into individul elements for easier access
# pipes'
x=() # current position
y=()
l=() # current directions
# 0: up, 1: right, 2: down, 3: left
n=() # new directions
v=() # current types
c=() # current escape codes
# selected pipes'
V=() # types (indexes to sets[])
C=() # color indices for tput setaf
VN=0 # number of selected types
CN=0 # number of selected colors
E=() # pre-generated escape codes from BOLD, NOCOLOR, and C
# switches
RNDSTART=0 # randomize starting position and direction
BOLD=1
NOCOLOR=0
KEEPCT=0 # keep pipe color and type
# print help message in 72-char width
print_help() {
local cgap
printf -v cgap '%*s' $((15 - ${#COLORS})) ''
cat <<HELP
Usage: $(basename $0) [OPTION]...
Animated pipes terminal screensaver.
-p [1-] number of pipes (D=1)
-t [0-$((${#sets[@]} - 1))] pipe type (D=0)
-t c[16 chars] custom pipe type
-c [0-$COLORS]${cgap}pipe color INDEX (TERM=$TERM), can be
hexadecimal with '#' prefix
(D=-c 1 -c 2 ... -c 7 -c 0)
-f [20-100] framerate (D=75)
-s [5-15] going straight probability, 1 in (D=13)
-r [0-] reset after (D=2000) characters, 0 if no reset
-R randomize starting position and direction
-B no bold effect
-C no color
-K keep pipe color and type when crossing edges
-h print this help message
-v print version number
Note: -t and -c can be used more than once.
HELP
}
# parse command-line options
# It depends on a valid COLORS which is set by _CP_init_termcap_vars
parse() {
# test if $1 is a natural number in decimal, an integer >= 0
is_N() {
[[ -n $1 && -z ${1//[0-9]} ]]
}
# test if $1 is a hexadecimal string
is_hex() {
[[ -n $1 && -z ${1//[0-9A-Fa-f]} ]]
}
# print error message for invalid argument to standard error, this
# - mimics getopts error message
# - use all positional parameters as error message
# - has a newline appended
# $arg and $OPTARG are the option name and argument set by getopts.
pearg() {
printf "%s: -$arg invalid argument -- $OPTARG; %s\n" "$0" "$*" >&2
}
OPTIND=1
while getopts "p:t:c:f:s:r:RBCKhv" arg; do
case $arg in
p)
if is_N "$OPTARG" && ((OPTARG > 0)); then
p=$OPTARG
else
pearg 'must be an integer and greater than 0'
return 1
fi
;;
t)
if [[ "$OPTARG" = c???????????????? ]]; then
V+=(${#sets[@]})
sets+=("${OPTARG:1}")
elif is_N "$OPTARG" && ((OPTARG < ${#sets[@]})); then
V+=($OPTARG)
else
pearg 'must be an integer and from 0 to' \
"$((${#sets[@]} - 1)); or a custom type"
return 1
fi
;;
c)
if [[ $OPTARG == '#'* ]]; then
if ! is_hex "${OPTARG:1}"; then
pearg 'unrecognized hexadecimal string'
return 1
fi
if ((16$OPTARG >= COLORS)); then
pearg 'hexadecimal must be from #0 to' \
"#$(printf '%X' $((COLORS - 1)))"
return 1
fi
C+=($((16$OPTARG)))
elif is_N "$OPTARG" && ((OPTARG < COLORS)); then
C+=($OPTARG)
else
pearg "must be an integer and from 0 to $((COLORS - 1));" \
'or a hexadecimal string with # prefix'
return 1
fi
;;
f)
if is_N "$OPTARG" && ((OPTARG >= 20 && OPTARG <= 100)); then
f=$OPTARG
else
pearg 'must be an integer and from 20 to 100'
return 1
fi
;;
s)
if is_N "$OPTARG" && ((OPTARG >= 5 && OPTARG <= 15)); then
s=$OPTARG
else
pearg 'must be an integer and from 5 to 15'
return 1
fi
;;
r)
if is_N "$OPTARG"; then
r=$OPTARG
else
pearg 'must be a non-negative integer'
return 1
fi
;;
R) RNDSTART=1;;
B) BOLD=0;;
C) NOCOLOR=1;;
K) KEEPCT=1;;
h)
print_help
exit 0
;;
v) echo "$(basename -- "$0") $VERSION"
exit 0
;;
*)
return 1
esac
done
shift $((OPTIND - 1))
if (($#)); then
printf "$0: illegal arguments -- $*; no arguments allowed\n" >&2
return 1
fi
}
cleanup() {
# clear out standard input
read -t 0.001 && cat </dev/stdin>/dev/null
tput reset # fix for konsole, see pipeseroni/pipes.sh#43
tput rmcup
tput cnorm
stty echo
printf "$SGR0"
exit 0
}
resize() {
w=$(tput cols) h=$(tput lines)
}
init_pipes() {
# +_CP_init_pipes
local i
ci=$((KEEPCT ? 0 : CN * RANDOM / M))
vi=$((KEEPCT ? 0 : VN * RANDOM / M))
for ((i = 0; i < p; i++)); do
((
n[i] = 0,
l[i] = RNDSTART ? RANDOM % 4 : 0,
x[i] = RNDSTART ? w * RANDOM / M : w / 2,
y[i] = RNDSTART ? h * RANDOM / M : h / 2,
v[i] = V[vi]
))
c[i]=${E[ci]}
((ci = (ci + 1) % CN, vi = (vi + 1) % VN))
done
# -_CP_init_pipes
}
init_screen() {
stty -echo
tput smcup
tput civis
tput clear
trap cleanup HUP TERM
resize
trap resize SIGWINCH
}
main() {
# simple pre-check of TERM, tput's error message should be enough
tput -T "$TERM" sgr0 >/dev/null || return $?
# +_CP_init_termcap_vars
COLORS=$(tput colors) # COLORS - 1 == maximum color index for -c argument
SGR0=$(tput sgr0)
SGR_BOLD=$(tput bold)
# -_CP_init_termcap_vars
parse "$@" || return $?
# +_CP_init_VC
# set default values if not by options
((${#V[@]})) || V=(0)
VN=${#V[@]}
((${#C[@]})) || C=(1 2 3 4 5 6 7 0)
CN=${#C[@]}
# -_CP_init_VC
# +_CP_init_E
# generate E[] based on BOLD (SGR_BOLD), NOCOLOR, and C for each element in
# C, a corresponding element in E[] =
# SGR0
# + SGR_BOLD, if BOLD
# + tput setaf C, if !NOCOLOR
local i
for ((i = 0; i < CN; i++)) {
E[i]=$SGR0
((BOLD)) && E[i]+=$SGR_BOLD
((NOCOLOR)) || E[i]+=$(tput setaf ${C[i]})
}
# -_CP_init_E
# +_CP_init_SETS
local i j
for ((i = 0; i < ${#sets[@]}; i++)) {
for ((j = 0; j < 16; j++)) {
SETS+=("${sets[i]:j:1}")
}
}
unset i j
# -_CP_init_SETS
init_screen
init_pipes
# any key press exits the loop and this script
trap 'break 2' INT
local i
while REPLY=; do
read -t 0.0$((1000 / f)) -n 1 2>/dev/null
case "$REPLY" in
P) ((s = s < 15 ? s + 1 : s));;
O) ((s = s > 3 ? s - 1 : s));;
F) ((f = f < 100 ? f + 1 : f));;
D) ((f = f > 20 ? f - 1 : f));;
B) ((BOLD = (BOLD + 1) % 2));;
C) ((NOCOLOR = (NOCOLOR + 1) % 2));;
K) ((KEEPCT = (KEEPCT + 1) % 2));;
?) break;;
esac
for ((i = 0; i < p; i++)); do
# New position:
# l[] direction = 0: up, 1: right, 2: down, 3: left
# +_CP_newpos
((l[i] % 2)) && ((x[i] += -l[i] + 2, 1)) || ((y[i] += l[i] - 1))
# -_CP_newpos
# Loop on edges (change color on loop):
# +_CP_warp
((!KEEPCT && (x[i] >= w || x[i] < 0 || y[i] >= h || y[i] < 0))) \
&& { c[i]=${E[CN * RANDOM / M]}; ((v[i] = V[VN * RANDOM / M])); }
((x[i] = (x[i] + w) % w,
y[i] = (y[i] + h) % h))
# -_CP_warp
# new turning direction:
# $((s - 1)) in $s, going straight, therefore n[i] == l[i];
# and 1 in $s that pipe makes a right or left turn
#
# s * RANDOM / M - 1 == 0
# n[i] == -1
# => n[i] == l[i] + 1 or l[i] - 1
# +_CP_newdir
((
n[i] = s * RANDOM / M - 1,
n[i] = n[i] >= 0 ? l[i] : l[i] + (2 * (RANDOM % 2) - 1),
n[i] = (n[i] + 4) % 4
))
# -_CP_newdir
# Print:
# +_CP_print
printf '\e[%d;%dH%s%s' \
$((y[i] + 1)) $((x[i] + 1)) ${c[i]} \
"${SETS[v[i] * 16 + l[i] * 4 + n[i]]}"
# -_CP_print
l[i]=${n[i]}
done
((r > 0 && t * p >= r)) && tput reset && tput civis && t=0 || ((t++))
done
cleanup
}
# when being sourced, $0 == bash, only invoke main when they are the same
[[ "$0" != "$BASH_SOURCE" ]] || main "$@"

10
local_bin/restartAudio Executable file
View File

@@ -0,0 +1,10 @@
#!/bin/bash
pkill easyeffects
wait
systemctl --user restart wireplumber pipewire pipewire-pulse
notify-send "Audio restarted" "Audio services have been restarted" -i ~/.local/share/icons/Catppuccin-SE/64x64/mimetypes/audio-x-generic.svg --app-name=Audio
easyeffects --gapplication-service &

BIN
local_bin/speedtest Executable file

Binary file not shown.

BIN
local_bin/tty-clock Executable file

Binary file not shown.

766
local_bin/unimatrix Executable file
View File

@@ -0,0 +1,766 @@
#!/usr/bin/env python3
#
# unimatrix.py
# <https://github.com/will8211/unimatrix>
#
# Python script to simulate the display from "The Matrix" in terminal. Uses
# half-width katakana unicode characters by default, but can use custom
# character sets. Accepts keyboard controls while running.
#
# Based on CMatrix by Chris Allegretta and Abishek V. Ashok. The following
# option should produce virtually the same output as CMatrix:
# $ unimatrix -n -s 96 -l o
#
# Unimatrix is free software: you can redistribute it and/or modify it under
# the terms of the GNU General Public License as published by the Free Software
# Foundation, either version 3 of the License, or (at your option) any later
# version.
#
# Unimatrix is distributed in the hope that it will be useful, but WITHOUT ANY
# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
# A PARTICULAR PURPOSE. See the GNU General Public License at
# <http://www.gnu.org/licenses/> for more details.
#
# Created by William Mannard
# 2018/01/19
import argparse
import curses
import time
from random import choice, randint
help_msg = '''
USAGE
unimatrix [-a] [-b] [-c COLOR] [-f] [-g COLOR] [-h] [-l CHARACTER_LIST] [-n]
[-o] [-s SPEED] [-u CUSTOM_CHARACTERS]
OPTIONAL ARGUMENTS
-a Asynchronous scroll. Lines will move at varied speeds.
-b Use only bold characters
-c COLOR One of: green (default), red, blue, white, yellow, cyan,
magenta, black
-f Enable "flashers," characters that continuously change.
-g COLOR Background color (See -c). Defaults to keeping
terminal's current background.
-h Show this help message and exit
-i Ignore keyboard
-l CHARACTER_LIST Select character set(s) using a string over letter
codes (see CHARACTER SETS below.)
-n Do not use bold characters (overrides -b)
-o Disable on-screen status
-s SPEED Integer up to 100. 0 uses a one-second delay before
refreshing, 100 uses none. Use negative numbers for
even lower speeds. Default=85
-t TIME Exit the process after TIME seconds
-u CUSTOM_CHARACTERS Your own string of characters to display. Enclose in
single quotes ('') to escape special characters. For
example: -u '#$('
-w Single-wave mode: Does a single burst of green rain,
exits. You can put in a .bashrc file to run when your
terminal launches. Works well with speed at 95.
LONG ARGUMENTS
-a --asynchronous
-b --all-bold
-c --color=COLOR
-f --flashers
-g --bg-color=COLOR
-h --help
-i --ignore-keyboard
-l --character-list=CHARACTER_LIST
-s --speed=SPEED
-n --no-bold
-o --status-off
-t --time
-u --custom-characters=CUSTOM_CHARACTERS
-w --single-wave
CHARACTER SETS
When using '-l' or '--character-list=' option, follow it with one or more of
the following letters:
a Lowercase alphabet
A Uppercase alphabet
c Lowercase Russian Cyrillic alphabet
C Uppercase Russian Cyrillic alphabet
e A few common emoji ( ☺☻✌♡♥❤⚘❀❃❁✼☀✌♫♪☃❄❅❆☕☂★ )
g Lowercase Greek alphabet
G Uppercase Greek alphabet
k Japanese katakana (half-width)
m Default 'Matrix' set, equal to 'knnssss'
n Numbers 0-9
o 'Old' style non-unicode set, like cmatrix. Equal to 'AaSn'
p Klingon pIqaD (requires 'Horta' family font)*
P Klingon pIqaD (requires 'Klingon-pIqaD' or 'Code2000' family font)*
r Lowercase Roman numerals ( mcclllxxxxvvvvviiiiii )
R Uppercase Roman numerals ( MCCLLLXXXXVVVVVIIIIII )
s A subset of symbols actually used in the Matrix films ( -=*_+|:<>" )
S All common keyboard symbols ( `-=~!z#$%^&*()_+[]{}|\;':",./<>?" )
u Custom characters selected using -u switch
For example: '-l naAS' or '--character-list=naAS' will give something similar
to the output of the original cmatrix program in its default mode.
'-l ACG' will use all the upper-case character sets. Use the same
letter multiple times to increase the frequency of the character set. For
example, the default setting is equal to '-l knnssss'.
* With most modern Linux terminals (gnome-terminal, konsole, lxterminal,
xfce4-terminal, mate-terminal) simply having the font installed system-wide
is enough. The terminal will fall back to it for the Klingon, meaning that
you don't have to select the font in your terminal settings. 'Horta' seems
not to work in Konsole. Fonts may need to be set manually as fallbacks in
.Xresources for older terminals, such as urxvt and xterm.
KEYBOARD CONTROL
SPACE, CTRL-c or q exit
- or LEFT decrease speed by 1
+ or RIGHT increase speed by 1
[ or DOWN decrease speed by 10
] or UP increase speed by 10
a toggle asynchronous scrolling
b cycle through bold character options
(bold off-->bold on-->all bold)
f toggle flashing characters
o toggle on-screen status
1 to 9 set color: (1) Green (2) Red (3) Blue (4) White
(5) Yellow (6) Cyan (7) Magenta (8) Black
(9) Terminal default
! to ( set background color (same colors as above, but pressing
shift + number)
EXAMPLES
Mimic default output of cmatrix (no unicode characters, works in TTY):
$ unimatrix -n -s 96 -l o
Use the letters from the name of your favorite operating system in bold blue:
$ unimatrix -B -u Linux -c blue
Use default character set, plus dollar symbol (note single quotes around
special character):
$ unimatrix -l knnssssu -u '$'
No bold characters, slowly, using emojis, numbers and a few symbols:
$ unimatrix -n -l ens -s 50
'''
### Set up parser and apply arguments settings
parser = argparse.ArgumentParser(add_help=False)
parser.add_argument('-a', '--asynchronous',
action='store_true',
help='use asynchronous scrolling')
parser.add_argument('-b', '--all-bold',
action='store_true',
help='use all bold characters')
parser.add_argument('-c', '--color',
default='green',
help='one of: green (default), red, blue, white, yellow, \
cyan, magenta, black',
type=str)
parser.add_argument('-f', '--flashers',
action='store_true',
help='some characters will continuously change in place')
parser.add_argument('-g', '--bg-color',
default='default',
help='background color (see -c)',
type=str)
parser.add_argument('-h', '--help',
help='display extended usage information and exit.',
action='store_true')
parser.add_argument('-i', '--ignore-keyboard',
help='ignore all keyboard input.',
action='store_true')
parser.add_argument('-l', '--character-list',
help='character set. See details below',
type=str)
parser.add_argument('-n', '--no-bold',
action='store_true',
help='do not use bold characters')
parser.add_argument('-o', '--status-off',
action='store_true',
help='Disable on-screen status')
parser.add_argument('-s', '--speed',
help='speed, integer up to 100. Default=85',
default=85,
type=int)
parser.add_argument('-t', '--time',
help='time. See details below',
type=int)
parser.add_argument('-u', '--custom-characters',
help='your own string of characters to display',
default='',
type=str)
parser.add_argument('-w', '--single-wave',
help='runs a single "wave" of green rain then exits',
action='store_true')
args = parser.parse_args()
if args.help:
print(help_msg)
exit()
char_set = {
'a': 'qwertyuiopasdfghjklzxcvbnm',
'A': 'QWERTYUIOPASDFGHJKLZXCVBNM',
'c': 'абвгдежзиклмнопрстуфхцчшщъыьэюя',
'C': 'АБВГДЕЖЗИКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ',
'e': '☺☻✌♡♥❤⚘❀❃❁✼☀✌♫♪☃❄❅❆☕☂★',
'g': 'αβγδεζηθικλμνξοπρστυφχψως',
'G': 'ΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩ',
'k': 'ヲァィゥェォャュョッーアイウエオカキクケコサシスセソタチツテトナニヌネノハヒフヘホマミムメモヤユヨラリルレロワン',
'm': 'ヲァィゥェォャュョッーアイウエオカキクケコサシスセソタチツテトナニヌネノハヒフヘホマミムメモヤユヨラリルレロワン1234567890'
'1234567890-=*_+|:<>"-=*_+|:<>"-=*_+|:<>"-=*_+|:<>"',
'n': '1234567890',
'o': 'qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM1234567890'
'`-=~!@#$%^&*()_+[]{}|\;\':",./<>?"',
'p': '',
'P': '',
'r': 'mcclllxxxxvvvvviiiiii',
'R': 'MCCLLLXXXXVVVVVIIIIII',
's': '-=*_+|:<>"',
'S': '`-=~!@#$%^&*()_+[]{}|\;\':",./<>?"',
'u': args.custom_characters}
colors_str = {
'green': curses.COLOR_GREEN,
'red': curses.COLOR_RED,
'blue': curses.COLOR_BLUE,
'white': curses.COLOR_WHITE,
'yellow': curses.COLOR_YELLOW,
'cyan': curses.COLOR_CYAN,
'magenta': curses.COLOR_MAGENTA,
'black': curses.COLOR_BLACK,
'default': -1}
start_color = colors_str[args.color]
start_bg = colors_str[args.bg_color]
speed = args.speed
start_delay = (100 - speed) * 10
runtime = None
if args.time:
runtime = args.time
# "-l" option has been used
if args.character_list:
chars = ''
for letter in args.character_list:
try:
chars += char_set[letter]
except KeyError:
print("Letter '%s' does not represent a valid character list."
% letter)
exit()
# "-l" not used, but "-u" is set
elif args.custom_characters:
chars = args.custom_characters
# Neither "-l" nor "-u" has been set, use default characters
else:
chars = char_set['m']
if args.no_bold:
args.all_bold = False
chars_len = len(chars) - 1
### Classes
class Canvas:
"""
Represents the whole screen and stores its height and width. Gets
overwritten whenever the screen resizes. Serves as a container for columns.
"""
def __init__(self, screen):
screen.clear()
rows, cols = screen.getmaxyx()
self.col_count = cols
self.row_count = rows
self.size_changed = False
self.columns = []
for col in range(0, cols, 2):
self.columns.append(Column(col, self.row_count))
self.nodes = []
self.flashers = set()
# Draw a background
for x in range(self.row_count):
try:
screen.addstr(x, 0, ' ' * self.col_count, curses.color_pair(1))
except curses.error:
pass
class Status:
"""
Displays a status message at top left when a setting is changed.
"""
def __init__(self, screen):
curses.init_pair(3, curses.COLOR_BLACK, curses.COLOR_WHITE)
self.screen = screen
self.countdown = 0
self.last_message = ''
def update(self, message, delay):
"""
Writes new message to the status area
"""
if not args.status_off:
message_str = message.ljust(11)
self.screen.addstr(0, 0, message_str, curses.color_pair(3))
self.last_message = message_str
# More frames for faster speeds:
self.countdown = (100 // (delay // 10 + 1)) + 2
def refresh(self):
"""
Used to keep refreshing status message until countdown runs out
"""
message_str = self.last_message
self.screen.addstr(0, 0, message_str, curses.color_pair(3))
def clear(self):
"""
Erases message with spaces when the countdown runs out
"""
self.screen.addstr(0, 0, ' ' * 11, curses.color_pair(1))
class Column:
"""
Creates nodes (points that move down the screen) that are then stored in
canvas.nodes. Countdown timer determines time to spawn new node.
"""
def __init__(self, x_coord, row_count):
self.drawing = None # None means not yet. Later will be True or False
self.x_coord = x_coord
self.timer = randint(1, row_count)
self.async_speed = randint(1, 3)
if args.single_wave:
# Speeds it up a bit
self.timer = int(0.6 * self.timer)
def spawn_node(self, canvas):
"""
Creates nodes: points that move down the screen either writing or
erasing characters as they go down
"""
if args.single_wave and self.drawing is False:
return
self.drawing = not self.drawing
# Multiplier (mult) is for spawning slow-moving asynchronous nodes
# less frequently in order to maintain their length
if args.asynchronous:
mult = self.async_speed
else:
mult = 1
if self.drawing:
# "max_range" prevents crash with very small terminal height
max_range = max((3 * mult), ((canvas.row_count - 3) * mult))
self.timer = randint(3 * mult, max_range)
if args.single_wave:
# A bit faster for single wave mode
self.timer = int(0.8 * self.timer)
else:
self.timer = randint(1 * mult, canvas.row_count * mult)
x = self.x_coord
n_type = 'eraser'
async_speed = self.async_speed
white = False
if self.drawing:
n_type = 'writer'
if randint(0, 2) == 0:
white = True
canvas.nodes.append(Node(x, n_type, async_speed, white))
class Node:
"""
A point that runs down the screen drawing or erasing characters.
n_type -> 'writer' or 'eraser'
white -> Bool. If True, a white char is written before the green one.
last_char -> Stores last character, since white characters have to be
overwritten with the same one in green one.
expired -> Bool. If True, node is marked for deletion
"""
def __init__(self, x_coord, n_type, async_speed, white=False):
self.x_coord = x_coord
self.y_coord = 0
self.n_type = n_type
self.white = white
self.last_char = None
self.expired = False
self.async_speed = async_speed
class KeyHandler:
"""
Handles keyboard input.
"""
def __init__(self, screen, stat):
self.screen = screen
self.stat = stat
self.screen.nodelay(True)
self.delay = start_delay
self.fg = start_color
self.bg = start_bg
def cycle_bold(self):
"""
Called on 'b' press. Cycles though Bold options:
off -> on -> all bold
"""
if args.all_bold:
args.no_bold = True
args.all_bold = False
self.stat.update('Bold: off', self.delay)
elif args.no_bold:
args.no_bold = False
args.all_bold = False
self.stat.update('Bold: on', self.delay)
else:
args.no_bold = False
args.all_bold = True
self.stat.update('Bold: all', self.delay)
def get(self):
"""
Handles key presses. Returns True if a key was found, False otherwise.
"""
if args.ignore_keyboard:
return False;
kp = self.screen.getch()
if kp == -1:
return False
elif kp == ord(" ") or kp == ord("q") or kp == 27: # 27 = ESC
exit()
elif kp == ord('a'):
args.asynchronous = not args.asynchronous
on_off = 'on' if args.asynchronous else 'off'
self.stat.update('Async: %s' % on_off, self.delay)
elif kp == ord('b'):
self.cycle_bold()
elif kp == ord('f'):
args.flashers = not args.flashers
on_off = 'on' if args.flashers else 'off'
self.stat.update('Flash: %s' % on_off, self.delay)
elif kp == ord('o'):
self.toggle_status()
# Speed control
elif kp == ord('-') or kp == ord('_') or kp == curses.KEY_LEFT:
self.delay = min(self.delay + 10, 10990)
self.show_speed()
elif kp == ord('=') or kp == ord('+') or kp == curses.KEY_RIGHT:
self.delay = max(self.delay - 10, 0)
self.show_speed()
elif kp == ord('[') or kp == curses.KEY_DOWN:
self.delay = min(self.delay + 100, 10990)
self.show_speed()
elif kp == ord(']') or kp == curses.KEY_UP:
self.delay = max(self.delay - 100, 0)
self.show_speed()
# Foreground color control
elif kp == ord('1'):
self.set_fg_color('Green')
elif kp == ord('2'):
self.set_fg_color('Red')
elif kp == ord('3'):
self.set_fg_color('Blue')
elif kp == ord('4'):
self.set_fg_color('White')
elif kp == ord('5'):
self.set_fg_color('Yellow')
elif kp == ord('6'):
self.set_fg_color('Cyan')
elif kp == ord('7'):
self.set_fg_color('Magenta')
elif kp == ord('8'):
self.set_fg_color('Black')
elif kp == ord('9'):
self.set_fg_color('default')
# Background color control
elif kp == ord('!'):
self.set_bg_color('Green')
elif kp == ord('@'):
self.set_bg_color('Red')
elif kp == ord('#'):
self.set_bg_color('Blue')
elif kp == ord('$'):
self.set_bg_color('White')
elif kp == ord('%'):
self.set_bg_color('Yellow')
elif kp == ord('^'):
self.set_bg_color('Cyan')
elif kp == ord('&'):
self.set_bg_color('Magenta')
elif kp == ord('*'):
self.set_bg_color('Black')
elif kp == ord('('):
self.set_bg_color('default')
return True
def set_fg_color(self, name):
"""
Set foreground color
"""
self.fg = colors_str[name.lower()]
curses.init_pair(1, self.fg, self.bg)
if name == 'default':
name = "Def't color"
self.stat.update(name, self.delay)
def set_bg_color(self, name):
"""
Set background color
"""
self.bg = colors_str[name.lower()]
curses.init_pair(1, self.fg, self.bg)
curses.init_pair(2, curses.COLOR_WHITE, self.bg)
self.stat.update('BG: %s' % name, self.delay)
def show_speed(self):
"""
Display current speed (-999 to 100) when it is changed by keypress
"""
self.stat.update('Speed: %d' % (100 - self.delay // 10), self.delay)
def toggle_status(self):
"""
On 'o' keypress, turn status display on or off
"""
args.status_off = not args.status_off
on_off = 'off' if args.status_off else 'on'
self.stat.update('Status: %s' % on_off, self.delay)
class Writer:
"""
Initializes character writing options and contains methods for writing and
erasing characters from the screen.
"""
def __init__(self, screen):
self.screen = screen
self.screen.scrollok(0)
curses.curs_set(0)
curses.use_default_colors()
curses.init_pair(1, start_color, start_bg)
curses.init_pair(2, curses.COLOR_WHITE, start_bg)
curses.init_pair(3, curses.COLOR_BLACK, curses.COLOR_WHITE)
self.white = curses.color_pair(2)
@staticmethod
def get_char():
"""
Returns a random character from the active character set
"""
return chars[randint(0, chars_len)]
@staticmethod
def get_attr(node, above=False):
"""
Returns either A_BOLD attribute or A_NORMAL based on Bold setting
"above=True" means it an extra green character used to overwrite the
while head character.
"""
if args.no_bold:
return curses.A_NORMAL
elif args.all_bold:
return curses.A_BOLD
else:
if node.white and not above:
return curses.A_BOLD
else:
return choice([curses.A_BOLD, curses.A_NORMAL])
def draw(self, node):
"""
Draws characters, included spaces to overwrite/erase characters.
"""
y = node.y_coord
x = node.x_coord
character = ' '
attr = self.get_attr(node)
color = curses.color_pair(1)
if node.n_type == 'writer':
if not node.white and node.last_char:
# Special green character for overwriting last white one
# at bottom of column that was not being overwritten.
character = node.last_char
else:
character = self.get_char()
if node.white:
color = curses.color_pair(2)
try:
# Draw the character
self.screen.addstr(y, x, character, color | attr)
if node.white:
if node.last_char:
# If it's a white node, also write a green character above
# to overwrite last white character
attr = self.get_attr(node, above=True)
self.screen.addstr(y - 1, x, node.last_char,
curses.color_pair(1) | attr)
node.last_char = character
except curses.error:
# Override scrolling error if characters pushed off the screen.
pass
def draw_flasher(self, flasher):
"""
Draws characters, included spaces to overwrite/erase characters.
"""
color = curses.color_pair(1)
attr = choice([curses.A_BOLD, curses.A_NORMAL])
y = flasher[0]
x = flasher[1]
try:
self.screen.addstr(y, x, self.get_char(), color | attr)
except curses.error:
pass
### Main loop
def _main(screen):
writer = Writer(screen)
stat = Status(screen)
key = KeyHandler(screen, stat)
# Prevent single_wave mode from shutting down too early:
if args.single_wave:
wave_delay = 10
else:
wave_delay = 0
starttime = time.time()
# Keep restarting however many times the screen resizes
while True:
canvas = Canvas(screen)
# Set a rhythm for asynchronous movement
async_clock = 5
# Loop to draw the green rain
while not canvas.size_changed:
if runtime and time.time() - starttime > runtime:
exit()
# Catch keypress
if key.get():
continue
# Spawn new nodes
for col in canvas.columns:
if col.timer == 0:
col.spawn_node(canvas)
col.timer -= 1
for node in canvas.nodes:
if args.flashers:
if node.n_type == 'writer' and not randint(0, 9):
canvas.flashers.add((node.y_coord, node.x_coord))
elif node.n_type == 'eraser':
try:
canvas.flashers.remove((node.y_coord, node.x_coord))
except KeyError:
pass
if args.asynchronous:
if async_clock % node.async_speed == 0:
writer.draw(node)
node.y_coord += 1
else:
writer.draw(node)
node.y_coord += 1
# Mark old nodes for deletion
if node.y_coord >= canvas.row_count:
if node.white:
# Stop white nodes from staying 'stuck' on last row.
# Creates a special green node with a last_char
# attribute to overwrite last white node.
node.white = False
node.y_coord -= 1
else:
node.expired = True
if args.flashers and (not async_clock % 3):
for f in canvas.flashers:
writer.draw_flasher(f)
# Rewrite nodes list without expired nodes
canvas.nodes = [node for node in canvas.nodes if not node.expired]
if args.single_wave:
if len(canvas.nodes) == 0 and wave_delay < 0:
exit()
wave_delay -= 1
# End of loop, refresh screen
if stat.countdown > 0:
if stat.countdown == 1:
stat.clear()
else:
stat.refresh()
stat.countdown -= 1
screen.refresh()
# Check for screen resize
if screen.getmaxyx() != (canvas.row_count, canvas.col_count):
canvas.size_changed = True
# Add delay before next loop
curses.napms(key.delay)
# update async clock
if async_clock:
async_clock -= 1
else:
async_clock = 5
def main():
# Wrapper to allow CTRL-C to exit smoothly:
try:
curses.wrapper(_main)
except KeyboardInterrupt:
pass
if __name__ == '__main__':
main()

235
local_bin/wttr Executable file
View File

@@ -0,0 +1,235 @@
#!/bin/bash
#
#Author : Amirreza Firoozi
#Author : Carsten Brueggenolte
#name : wttr
#Update 1.30: change config dir to $HOME/.config/wttr to go in line with other configuration files
#Update 1.30: changed default city filename to 'default-city.txt'
#Update 1.40: add v2.wttr.in feature and did some clean up
#Update 1.41: add spaces in between city and url
#Update 1.42: reverse changes with the space between url and city
#Update 1.50: add v3.wttr.in - thanks to dok-ock for the inspiration and the fixes
#Update 1.51: update about section and add it to the help screen
#Update 1.52: move help and about into their own variables for better maintanance
#Update 1.53: add a parameters '-t' current forecast and '-n' current weather
#Update 1.54: spell check and added some optional parameters for -help, -today, -now
wttr_ver="1.54_2021-09-03" #define script version
GITHUB_REPO_URL="https://github.com/cblte/bash-script-wttr"
URL="https://wttr.in/"
URLv2="https://v2.wttr.in/"
URLv3="https://v3.wttr.in/"
About()
{
echo -e ="
About the
██╗ ██╗████████╗████████╗██████╗ ██╗███╗ ██╗
██║ ██║╚══██╔══╝╚══██╔══╝██╔══██╗ ██║████╗ ██║
██║ █╗ ██║ ██║ ██║ ██████╔╝ ██║██╔██╗ ██║
██║███╗██║ ██║ ██║ ██╔══██╗ ██║██║╚██╗██║
╚███╔███╔╝ ██║ ██║ ██║ ██║██╗██║██║ ╚████║
╚══╝╚══╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝╚═╝╚═╝╚═╝ ╚═══╝
script by Carsten Brueggenolte
This is a simple bash script to check weather condition
with the help of wttr.in. The script 'wttr' is under GPL3 License.
Source is available on Github: $GITHUB_REPO_URL
Big THANK YOU goes to
- 'Amirreza Firoozi' (https://github.com/AmirrezaFiroozi/wttr)
for creating the initial script
- 'doc-ock' (https://github.com/doc-ock/) for the idea to add
version 3 of wttr.in and some other useful parameters.
"
}
Help()
{
echo -e "
Write 'wttr {your+city+name}' to check the weather condition of your city.
Surround city name with single- or double-quotes if city name contains more than one word.
You can also put a '+' (plus-sign) in beetween words when you do not want to surround with quotes.
Examples:
wttr cologne
wttr \"Den Haag, Netherland\"
wttr Den+Haag
wttr \"Den Haag Street, South Africa\"
wttr New+York
You can type 'wttr' only if you have defined a standard city.
Parameters:
-a show some information about this script
-h for some help (this page)
-hh for the official wttr.in/:help page
-i to install curl which is necessary for script to run correctly
-m for photo of moon
-n show current weather only
-rm to remove the script :(
-sdef to define a city as your default city
-t show today's forecast
-v show script version
-v2 to fetch different weather report view for the standard city
-v2 {your city name} to fetch different weather report view for city mentioned
-v3 {your city name} to fetch an in-terminal graphic for the given region.
Hint:
When using '-v3' you do not need to add the '.sxl' to the
end of the region/city name. The script will add it automatically.
Any bugs? Any suggestions? Contact information at https://cbrueggenolte.de/impressum
"
}
# ------------------------
# ----- Script starts here
# ------------------------
# Check if a standard city has been set
if [ -f "$HOME/.config/wttr/default-city.txt" ];then #check if user set default city or not . if user did load it to variable def
cd $HOME/.config/wttr
def=$(cat default-city.txt)
elif [ ! -d $HOME/.config/wttr ];then #if he/she didn`t make a blank file
mkdir "$HOME/.config/wttr" 2>/dev/null
cd $HOME/.config/wttr
echo "" > default-city.txt
def=""
fi
# Print out some help if no arguments provided and no standard city been set
if [ "$#" == "0" ] && [ "$def" == "" ];then
echo -e "You have not entered any parameters and no standard city set yet.\nNeed help? try 'wttr -h'"
elif [ "$#" -gt "2" ];then
echo -e "too many parameters. \nNeed help? try 'wttr -h'"
else
case $1 in
# currently doesn't work: upgrade. There is some permissions problem
# "-u" | "-upgrade")
# echo -e "Checking for upgrades..."
# git clone $GITHUB_REPO_URL /tmp/wttr
# bash /tmp/wttr/installer.sh
# ;;
"-a") # about
About
;;
"-h" | "-help") #showing help
Help
;;
"-hh")
curl https://wttr.in/:help
;;
"-i")
sudo apt install curl
;;
"-m")
curl http://wttr.in/moon
;;
"-n" | "-now")
echo -e "Fetching current weather"
if [ "$#" == "2" ];then
city="$2"
city=${city// /+}
city=${city//[^a-zA-Z0-9+]}
curl $URL"$city?0n"
else
curl $URL"$def?0n"
fi
cd $HOME
;;
"-rm")
read -p "Do you really want to remove wttr? (y/n)" response
if [ "$response" == "y" ];then
cd /usr/bin
sudo rm -R "wttr" 2>/dev/null
if [ -d "$HOME/.config/wttr" ];then
sudo rm -d "$HOME/.config/wttr" 2>/dev/null
fi
echo -e "Script has deleted :("
else
echo -e "Opration canceled"
fi
;;
"-sdef") # set the default city
if [ ! -d $HOME/.config/wttr ];then
cd $HOME
mkdir -p ".config/wttr" 2>/dev/null
fi
if [ "$#" == "2" ];then
cd $HOME/.config/wttr
echo "$2" > default-city.txt
echo -e ""
echo -e "Done. Set '$2' as your default city. You can check its weather condition by typing only 'wttr' now :)"
else
read -p "Enter your city name to set as the default city (example : cologne) : " def
# replacing spaces with + signes and removing non wanted chars
def=${def// /+}
def=${def//[^a-zA-Z0-9+]}
if [ "$def" == "" ] && [ "$#" -ne "2" ];then
echo "you did NOT enter anything ..."
else
cd $HOME/.config/wttr
echo $def > default-city.txt
echo -e ""
echo -e "Done. Set '$def' as your default city. You can check its weather condition by typing only 'wttr' now :)"
fi
fi #end of the second if
;;
"-t" | "-today")
echo -e "Fetching today's forecast"
if [ "$#" == "2" ];then
city="$2"
city=${city// /+}
city=${city//[^a-zA-Z0-9+]}
curl $URL"$city?1n"
else
curl $URL"$def?1n"
fi
cd $HOME
;;
"-v")
echo -e "wttr_VERSION is: "$wttr_ver" "
;;
"-v2")
echo -e "Fetching v2 of wttr.in"
if [ "$#" == "2" ];then
city="$2"
city=${city// /+}
city=${city//[^a-zA-Z0-9+]}
curl $URLv2"$city"
else
curl $URLv2"$def"
fi
cd $HOME
;;
"-v3")
echo -e "Fetching v3 of wttr.in"
if [ "$#" == "2" ];then
city="$2"
city=${city// /+}
city=${city//[^a-zA-Z0-9+]}
curl $URLv3"$city".sxl
else
curl $URLv3"$def".sxl
fi
cd $HOME
;;
"")
cd $HOME
curl $URL"$def"
;;
*)
city=$1
city=${city// /+}
city=${city//[^a-zA-Z0-9+]}
curl $URL"$city"
;;
esac
fi