Last active
April 7, 2023 20:33
-
-
Save alismx/83356d96cf13b233743234e44baa31a9 to your computer and use it in GitHub Desktop.
I put this in my profile so when I open a new tab I get some random ascii ¯\_(ツ)_/¯
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function generate_ascii_art() { | |
local chars=("@" "#" "%" "*" "+" "-" "=", "¯\_(ツ)_/¯") | |
local num_chars=${#chars[@]} | |
local rows=$(($RANDOM % 10 + 25)) | |
local cols=$(($RANDOM % 10 + 100)) | |
for ((i=0; i<$rows; i++)); do | |
for ((j=0; j<$cols; j++)); do | |
local char_idx=$(($RANDOM % $num_chars)) | |
printf "%s" "${chars[$char_idx]}" | |
done | |
printf "\n" | |
done | |
} | |
generate_ascii_art |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment