bash-cli-spinners offers a collection of over 80 visually appealing spinners for terminal applications, inspired by cli-spinners. With features like color support, clean output management, and an interactive web gallery, this library enhances the user experience in Bash and Zsh scripts, making command-line interfaces more dynamic and engaging.
The bash-cli-spinners project is a comprehensive library offering over 80 vibrant spinners designed specifically for terminal applications using Bash or Zsh. This library draws inspiration from the well-known cli-spinners and provides a straightforward way to enhance scripts with engaging loading indicators.
cli-spinners package.Effortlessly incorporate spinners into your scripts with simple commands:
# List all available spinners
./spinner.sh list
# Display a spinner for 5 seconds
./spinner.sh show dots 5 "Loading data" blue
# Run a command with an accompanying spinner
./spinner.sh run pong "Installing packages" bright_green sleep 10
The library supports a straightforward command structure:
./spinner.sh show <spinner_name> <duration> [message] [color]
./spinner.sh run <spinner_name> [message] [color] <command>
./spinner.sh show dots 3
./spinner.sh run weather "Downloading files" cyan curl -O https://example.com/file.zip
Utilize a diverse palette for your spinners:
Each spinner configuration is structured in the spinners.json file, following this format:
{
"spinner_name": {
"interval": 80,
"frames": ["frame1", "frame2", "frame3"]
}
}
For further enhancements and integrations, refer to the cli-spinners project.
No comments yet.
Sign in to be the first to comment.