Skip to content

Instantly share code, notes, and snippets.

@bitmvr
Created June 17, 2018 17:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bitmvr/63698d3d049b8af2b952c19d6204ced5 to your computer and use it in GitHub Desktop.
Save bitmvr/63698d3d049b8af2b952c19d6204ced5 to your computer and use it in GitHub Desktop.
Animated Pride Flag written in Bash
#!/usr/bin/env bash
sleepSpeed=0.001
line=$(printf ' %.0s' {1..50})
paintBucket=( '196' '214' '226' '28' '27' '90' )
for paint in "${paintBucket[@]}"; do
swipe=1
length=1
while [ $swipe -le 2 ]; do
while [ $length -le 50 ]; do
printf "\\033[48;5;${paint}m \\033[0m"
sleep "${sleepSpeed}"
((length++))
done
length=1
((swipe++))
printf '\n'
done
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment