illmatic-scheduling

Crates.ioillmatic-scheduling
lib.rsillmatic-scheduling
version0.1.2
sourcesrc
created_at2021-05-29 04:46:33.051817
updated_at2021-05-29 20:54:49.532018
descriptionScheduling library avoiding to dirturb someone.
homepagehttps://github.com/ledyba/illmatic-scheduling
repositoryhttps://github.com/ledyba/illmatic-scheduling
max_upload_size
id403404
size44,612
Kaede Fujisaki (ledyba)

documentation

README

Illmatic Scheduling: A scheduling library avoiding to dirturb someone.

How to use?

  let rt = tokio::runtime::Builder::new_multi_thread().enable_time().build().unwrap();
  rt.block_on(async move {
    let mut mgr = illmatic_scheduling::JobManager::new(&["firefox"], 10.0);
    for _i in 0..10 {
      if let Ok(count) = mgr.watch().await {
        // You have a `count` times to do something.
      }
      sleep(Duration::from_millis(1000)).await;
    }
  });

License

AGPL v3 or later

Commit count: 13

cargo fmt