Skip to content
/ spinny Public

Another spinner written in bash. Customizable and pretty 💄

License

Notifications You must be signed in to change notification settings

hschne/spinny

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spinny

Yet another terminal spinner written in Bash. Customizable and pretty 💄


How do I use this?

Simple. First download spinny:

wget https://raw.githubusercontent.com/hschne/spinny/master/spinny.sh

To use it in your shell scripts import it, and you are good to go:

source spinny.sh

printf "Starting some long running process now... "
spinny::start
sleep 3
spinny::stop
printf "Done!\n"

Spinny is versatile and can animate pretty much anything you throw at it. The variables SPINNY_FRAMES and SPINNY_DELAY can be used to change the look of the spinner. The code below will render three dots instead:

SPINNY_FRAMES=(. .. ...)
SPINNY_DELAY=0.1
printf "Fancy spinners right here: "
spinny::start
sleep 3
spinny::stop
printf " \n"

Have a look at the demo for more examples or run it yourself:

chmod +x demo.sh && ./demo.sh

Contributing

I'm new to this entire bash thing. While I try and keep things portable and dependencies to a minimum, I can't guarantee that Spinny will work on your particular machine.

If you encounter any errors or have ideas for improvements feel free to file an issue! ❤️

License

MIT (c) @hschne

About

Another spinner written in bash. Customizable and pretty 💄

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages