#ipld #car #ipfs

rs-car

Rust implementation of the CAR v1 and v2 specifications

6 releases (breaking)

0.5.0 Mar 12, 2025
0.4.1 Mar 3, 2023
0.3.0 Mar 2, 2023
0.2.0 Feb 28, 2023
0.1.0 Feb 27, 2023

#7 in #car

Download history 2053/week @ 2025-08-19 997/week @ 2025-08-26 1335/week @ 2025-09-02 1079/week @ 2025-09-09 919/week @ 2025-09-16 691/week @ 2025-09-23 545/week @ 2025-09-30 1058/week @ 2025-10-07 834/week @ 2025-10-14 694/week @ 2025-10-21 956/week @ 2025-10-28 796/week @ 2025-11-04 571/week @ 2025-11-11 788/week @ 2025-11-18 481/week @ 2025-11-25 555/week @ 2025-12-02

2,460 downloads per month
Used in 4 crates (3 directly)

MIT/Apache

1.5MB
764 lines

Rust implementation of the CAR specifications, both CARv1 and CARv2.

Usage

  • To get a block streamer [CarReader::new()]
  • To read all blocks in memory [car_read_all]

rs-car

Rust implementation of the CAR specifications, both CARv1 and CARv2.

Usage

let mut file = async_std::fs::File::open(car_filepath).await.unwrap();
let block_stream = decode_car_async_stream(&mut file, true).await.unwrap();

while let Some(item) = block_stream.next().await {
    let (cid, block) = item.unwrap();
    // Do something with CAR block
}

Dependencies

~5MB
~108K SLoC