Skip to content

feat: support --total-size on Windows#1714

Open
Charlie-XIAO wants to merge 2 commits intoeza-community:mainfrom
Charlie-XIAO:feat/windows-total-size
Open

feat: support --total-size on Windows#1714
Charlie-XIAO wants to merge 2 commits intoeza-community:mainfrom
Charlie-XIAO:feat/windows-total-size

Conversation

@Charlie-XIAO
Copy link
Copy Markdown

Closes #647.

This PR implements the --total-size option for Windows, which was previously supported only for Unix. According to the comment on the recursive_directory_size method, the major reason Windows was not supported is that volume_serial_number and file_index are only available on nightly channel. But with same-file crate we can get a hashable Handle to uniquely identify a file cross platform. The same-file crate is very lightweight and has over 300M+ downloads so I believe it makes sense to add it as a new dependency.

To test the change, try cargo run -- -l --total-size. I didn't find a test for Unix about --total-size, so I didn't add one for Windows either.

Signed-off-by: Charlie-XIAO <yx2436@nyu.edu>
Signed-off-by: Charlie-XIAO <yx2436@nyu.edu>
@Charlie-XIAO Charlie-XIAO force-pushed the feat/windows-total-size branch from 63fdfbf to e9cce25 Compare February 11, 2026 04:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat: Support --total-size option on Windows

1 participant