[package] name = "yield-progress" version = "0.1.7" edition = "2021" rust-version = "1.63.0" description = "Combined progress reporting and cooperative task yielding." repository = "https://github.com/kpreid/yield-progress" license = "MIT OR Apache-2.0" categories = ["asynchronous", "gui", "wasm", "no-std"] keywords = ["yield", "progressbar"] publish = true exclude = [".github", ".vscode"] [features] default = ["sync"] # Implements `YieldProgress: Send + Sync` for use with multi-threaded executors. # Requires `std` to be available for the compilation target. sync = [] # Log intervals between yields longer than 100 ms. # Requires `std` to be available for the compilation target. # This might be removed in favor of something more configurable in future versions, # in which case the feature flag may still exist but do nothing. log_hiccups = ["dep:log", "dep:web-time"] [[example]] name = "interactive-cancel" required-features = ["sync"] test = false [dependencies] # Used for logging over-long intervals between yields. TODO: This should be pluggable instead log = { version = "0.4.17", optional = true, default-features = false } # Used for reading the current time on wasm. TODO: This should be pluggable instead web-time = { version = "1.0.0", optional = true } [dev-dependencies.tokio] version = "1.28.0" default-features = false features = [ "rt", "sync", # for gathering data in tests "macros", # for tokio::main and tokio::test in tests and examples "signal", # for interactive cancellation example "time", # for examples ]