Indicators is a project that has code ready for you to implement when creating progress bars in the terminal.
- Thread-safe progress bars and spinners
- Header-only library. Take a copy to include.
- Single header version in
- The source of the GIF
- MIT License
Creating a Basic Progress Bar
To implement a progress bar in your app, add
indicators/progress_bar.hpp and create a ProgressBar object. This is the general structure of a progress bar:
The amount of progress in ProgressBar is kept as a
size_t in the range [0, 100]. When the progress reaches 100, the progression is complete.
In application-level code, there are two ways to update this progress: Update progress using
Indeterminate progress bar
Blocked progress bar
Implemented in real life
If you have an iso of say 5GB and you want to copy it to another directory, the code would be;
Installing indicators and compiling your code
Just clone and use CMake and Make
For more examples and with the code ready visit the official Indicators repository: