untokio: pretend tokio doesn't exist

GitHub crates.io docs.rs License Build Status

Do you struggle with any of the following symptoms?

Struggle no more, with untokio! untokio will automatically create a runtime so you don't have to.

example: tokio = "0.2", reqwest = "0.10"

toml [dependencies] untokio = { version = "0.1", features = ["v02"] } rust untokio::v02::spawn(async { // code requiring a tokio 0.2 runtime reqwest::get("http://example.com/").await?.text().await }).await.unwrap()

example: tokio = "0.3"

toml [dependencies] untokio = { version = "0.1", features = ["v03"] } rust untokio::v03::spawn(async{ // code requiring a tokio 0.3 runtime tokio::fs::read_to_string("Cargo.toml").await }).await.unwrap()

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.