This commit is contained in:
2026-07-14 20:30:55 +02:00
parent 400022a2ff
commit 8e0b5d4b64
+21 -19
View File
@@ -1,11 +1,14 @@
#!/bin/bash #!/bin/bash
STD=true STD=true
shaw=false
ghost=false
while getopts "atg" flag; do while getopts "atg" flag; do
case "$flag" in case "$flag" in
a) a)
shaw=true shaw=true
STD=false
;; ;;
t) t)
text=$(date) text=$(date)
@@ -23,6 +26,23 @@ while getopts "atg" flag; do
esac esac
done done
if [ $shaw = true ]
then
if [ $ghost = true ]
then
text=" "
else
shaws=("SHAW!" "HEAGALE" "GIT GUD" "Fren." "HahAH" "EDINO!" "Mejina Fora.")
length=${#shaws[@]}
random_index=$(( RANDOM % length ))
text=${shaws[$random_index]}
STD=false
fi
fi
if [ $STD = true ] if [ $STD = true ]
then then
read text read text
@@ -34,14 +54,7 @@ for (( i=0; i<${#text}+4; i++ )); do
line="$line-" line="$line-"
done done
if [ $ghost = true ]; then
if [ $ghost ];
then
if [ $shaw ];
then
text=" "
fi
echo $line echo $line
echo "| $text |" echo "| $text |"
echo $line echo $line
@@ -57,16 +70,6 @@ then
echo ⠀⠀⠀⠀⠘⢻⣯⠟⢺⡟⠋⠀⠀⠀⠀⠀⠀⠀ echo ⠀⠀⠀⠀⠘⢻⣯⠟⢺⡟⠋⠀⠀⠀⠀⠀⠀⠀
echo ⠀⠁⠀⠀⠁⠀ echo ⠀⠁⠀⠀⠁⠀
else else
if [ $shaw ];
then
shaws=("SHAW!" "HEAGALE" "GIT GUD" "Fren." "HahAH" "EDINO!")
length=${#shaws[@]}
random_index=$(( RANDOM % length ))
text=${shaws[$random_index]}
STD=false
fi
echo $line echo $line
echo "| $text |" echo "| $text |"
echo $line echo $line
@@ -81,5 +84,4 @@ else
echo ⠀⠀⠀⠀⠈⣻⠿⣿⣿⣿⡿⠛⠃⠀⠀⠀⠀ echo ⠀⠀⠀⠀⠈⣻⠿⣿⣿⣿⡿⠛⠃⠀⠀⠀⠀
echo ⠀⠀⣤⣔⠎⠇⠙⠀⢧⢸⠀⠀⠀⠀⠀⠀⠀ echo ⠀⠀⣤⣔⠎⠇⠙⠀⢧⢸⠀⠀⠀⠀⠀⠀⠀
echo ⠐⠊⠁⠁⠀⠀⠀⠀⠸⢸⠀⠀⠀⠀⠀⠀⠀ echo ⠐⠊⠁⠁⠀⠀⠀⠀⠸⢸⠀⠀⠀⠀⠀⠀⠀
fi fi