Created
July 23, 2025 23:40
-
-
Save mitchellh/73777dc99c3ba6d3393690d01a6bd93a to your computer and use it in GitHub Desktop.
This file contains hidden or 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
#!/usr/bin/env bash | |
counter=1 | |
echo "demo: error state" | |
while [ $counter -le 25 ]; do | |
printf "\x1b]9;4;2;${counter}\x07" | |
((counter++)) | |
sleep 0.1 | |
done | |
echo "demo: normal state" | |
while [ $counter -le 50 ]; do | |
printf "\x1b]9;4;1;${counter}\x07" | |
((counter++)) | |
sleep 0.1 | |
done | |
echo "demo: pulsing" | |
while [ $counter -le 75 ]; do | |
printf "\x1b]9;4;3\x07" | |
((counter++)) | |
sleep 0.1 | |
done | |
echo "demo: normal state" | |
while [ $counter -le 100 ]; do | |
printf "\x1b]9;4;1;${counter}\x07" | |
((counter++)) | |
sleep 0.1 | |
done | |
printf "\x1b]9;4;0\x07" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment