Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/developerstoolbox/bash-spinner
Display a small progress spinner in bash while running your commands with optional message.
https://github.com/developerstoolbox/bash-spinner
progress-spinner spinner wolfsoftware
Last synced: about 2 months ago
JSON representation
Display a small progress spinner in bash while running your commands with optional message.
- Host: GitHub
- URL: https://github.com/developerstoolbox/bash-spinner
- Owner: DevelopersToolbox
- License: mit
- Created: 2021-02-15T13:42:55.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2024-11-25T04:25:01.000Z (about 2 months ago)
- Last Synced: 2024-11-25T05:22:04.063Z (about 2 months ago)
- Topics: progress-spinner, spinner, wolfsoftware
- Language: Shell
- Homepage:
- Size: 99.6 KB
- Stars: 7
- Watchers: 3
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: .github/CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE.md
- Code of conduct: .github/CODE_OF_CONDUCT.md
- Citation: CITATION.cff
- Codeowners: .github/CODEOWNERS
- Security: .github/SECURITY.md
Awesome Lists containing this project
README
## Overview
Display a small progress spinner in bash while running your commands with optional message.
This can be used for anything that takes time.
## Simple (Static) Example
This example passes a static string to start_spinner which remains in place until stop_spinner is called.
```shell
source spinner.shstart_spinner "This is my cool spinner message"
sleep 10stop_spinner
```## Dynamic Example
This example passes a command to start_spinner_eval which will be re-evaluated each time the spinner is drawn until stop_spinner is called.
```shell
source spinner.shstart_spinner_eval 'cat log | tail -1'
for i in {1..10}; do
echo "Iteration number ${i}" >> log
sleep 1
donestop_spinner
```## Config
You can set an environment value called SPINNER_DELAY to change the default (0.25 seconds) delay used when drawing the spinner.