osc94 0.1.0

Library for handling progress bar sequences (OSC 9;4).
Documentation
  • Coverage
  • 100%
    13 out of 13 items documented2 out of 4 items with examples
  • Size
  • Source code size: 14.19 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.02 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 9s Average build duration of successful builds.
  • all releases: 10s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • PRO-2684/osc94
    1 0 1
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • PRO-2684

osc94

GitHub License GitHub Workflow Status GitHub Release GitHub Downloads (all assets, all releases) Crates.io Version Crates.io Total Downloads docs.rs

Library for handling progress bar sequences (OSC 9;4).

💡 Example

use osc94::Progress;
use std::io::Result;

# fn work() {}
#
fn main() -> Result<()> {
    let mut progress = Progress::default();
    progress.start();

    for i in 0..=100 {
        work();
        progress.increment(1).flush()?;
    }

    Ok(())
}

📖 Usage

Usually, you'll only need the Progress struct, which provides a high-level interface and handles clean up job for you when dropped. If you need finer control, you can use the OSC94 struct and ProgressState enum. See the documentation of respective API for more details.

📥 Demo Binary

Using binstall

cargo binstall osc94

Downloading from Releases

Navigate to the Releases page and download respective binary for your platform. Make sure to give it execute permissions.

Compiling from Source

cargo install osc94

🎉 Credits