loading

Crates.ioloading
lib.rsloading
version0.4.0
sourcesrc
created_at2020-01-21 04:40:53.207926
updated_at2024-07-05 08:41:40.098687
descriptionShow loading in terminal
homepagehttps://github.com/wyhaya/loading
repositoryhttps://github.com/wyhaya/loading.git
max_upload_size
id200657
size12,474
(wyhaya)

documentation

README

loading

Crates.io docs.rs LICENSE

Used to display loading or progress in the terminal

Preview

Use

Add this in your Cargo.toml:

[dependencies]
loading = "*"

Example

use loading::Loading;
use std::thread;
use std::time::Duration;

fn main() {
    let loading = Loading::default();

    for i in 0..=100 {
        loading.text(format!("Loading {}", i));
        thread::sleep(Duration::from_millis(50));
    }

    loading.success("OK");

    loading.end();
}

Other example

cargo run --example loading
cargo run --example status
cargo run --example download
cargo run --example spinner

Commit count: 8

cargo fmt