spinoff/examples/all_spinners.rs

13 lines
306 B
Rust
Raw Normal View History

2022-07-15 12:59:22 -05:00
use spinoff::Spinners;
use std::thread::sleep;
use std::time::Duration;
use strum::IntoEnumIterator;
fn main() {
for spinner in Spinners::iter() {
2022-07-16 08:32:08 -05:00
let spin = spinoff::new(spinner, "Spinning...", None);
2022-07-15 12:59:22 -05:00
sleep(Duration::from_secs(1));
spin.clear();
}
println!("Done!");
}