datrs / random-access-disk

Continuously read/write to disk using random offsets and lengths .
Apache License 2.0
27 stars 13 forks source link

del(), sparse files, support RAS 5.0.0, clippy & documentation #48

Closed ttiurani closed 1 year ago

ttiurani commented 1 year ago

del() with support for sparse files

Using the default sparse feature flag, this holepunches files to save space on linux, OSX and Windows. This mirrors the implementation in javascript (https://github.com/holepunchto/fs-native-extensions) and produces an identical sparse file as that.

&mut to len(), remove (unimplemented) read_to_writer()

These changes add compatible with the upcoming 5.0.0 random-access-storage.

Add support for tokio

The crate now supports also the tokio runtime, while async-std is still default.

Bump edition from 2018 to 2021

Because this is a breaking change, this is a good place to also bump the rust edition to the latest.

Switch from quickcheck to proptest

To enable testing on Windows, switch property tests from quickcheck to proptest.

Fix clippy lints

Clippy now passes on all code.

Comprehensive documentation

Move (broken) documentation from README to lib.rs and document usage with two examples.

Checklist

Context

https://github.com/datrs/random-access-storage/pull/26

Semver Changes

3.0.0