10 stable releases

1.5.0 Oct 9, 2020
1.4.0 Oct 4, 2020
1.3.0 Sep 14, 2020
1.1.1 Aug 26, 2020
0.0.0 May 10, 2019

#416 in Asynchronous

Download history 4009/week @ 2020-10-30 4182/week @ 2020-11-06 3852/week @ 2020-11-13 4677/week @ 2020-11-20 4215/week @ 2020-11-27 3670/week @ 2020-12-04 5162/week @ 2020-12-11 7234/week @ 2020-12-18 5706/week @ 2020-12-25 8542/week @ 2021-01-01 8294/week @ 2021-01-08 6617/week @ 2021-01-15 7013/week @ 2021-01-22 5966/week @ 2021-01-29 5811/week @ 2021-02-05 6034/week @ 2021-02-12

4,668 downloads per month
Used in 87 crates (10 directly)

Apache-2.0 OR MIT

61KB
481 lines

async-fs

Build License Cargo Documentation

Async filesystem primitives.

This crate is an async version of std::fs.

Implementation

This crate uses blocking to offload blocking I/O onto a thread pool.

Examples

Create a new file and write some bytes to it:

use async_fs::File;
use futures_lite::io::AsyncWriteExt;

let mut file = File::create("a.txt").await?;
file.write_all(b"Hello, world!").await?;
file.flush().await?;

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.

Dependencies

~725KB
~12K SLoC