#learning #learn #order #getopt #arguments-parser #sb

bin+lib du

Implementing du -sb in order to learn Rust

2 releases

Uses old Rust 2015

0.1.1 May 15, 2016
0.1.0 May 14, 2016

#21 in #getopt

Download history 1/week @ 2024-11-13 5/week @ 2024-11-20 12/week @ 2024-11-27 12/week @ 2024-12-04 22/week @ 2024-12-11 8/week @ 2024-12-18 14/week @ 2025-01-08 2/week @ 2025-01-15 8/week @ 2025-01-29 15/week @ 2025-02-05 18/week @ 2025-02-12 9/week @ 2025-02-19 22/week @ 2025-02-26

66 downloads per month
Used in whaledrive

MIT license

3KB

rust-du

This is just an implementation of du -sb in Rust so that I can play around with learning Rust.

Some things that doing this project allowed me touch on in Rust:

  • Error Handling

    • with the try! macro calls in lib.rs
    • with pattern matching inside the main function
    • and some unwraps, sprinkled around the place
  • Argument Parsing

  • Generic Code

  • Testing

  • Packaging

Dependencies

~1.5MB
~21K SLoC