Skip to content

Clap args#25

Merged
AdamIsrael merged 6 commits intomainfrom
clap_args
Mar 27, 2026
Merged

Clap args#25
AdamIsrael merged 6 commits intomainfrom
clap_args

Conversation

@AdamIsrael
Copy link
Copy Markdown
Owner

Add a clap_args macro to dynamically generate an Args struct that includes the base and CLI-specific arguments in order to lighten the lift in making all CLI arguments more consistent without code duplication.

Updates arch and b2sum to use follow this new pattern.

Implement the `clap_args!` macro in stdlib so that we can follow a
consistent pattern while constructing the `clap` `Command`. We start
with the common `Command` and then dynamically create a struct with the
per-binary CLI.
Implemented output formats for b2sum.
Update the README to reflect that `b2sum` has been modernized, and add
the test data used for the command.
@AdamIsrael AdamIsrael merged commit 245dfac into main Mar 27, 2026
8 checks passed
@AdamIsrael AdamIsrael deleted the clap_args branch March 27, 2026 01:53
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.

1 participant