A Rust derive-based argument parser optimized for code size and Fuchsia command-line tool conformance.
Argh is a Rust library for parsing command-line arguments using derive macros, optimized to minimize code size in compiled binaries. It provides a declarative way to define command-line interfaces with support for switches, options, positional arguments, and subcommands while conforming to Fuchsia's command-line tool specifications.
Rust developers building command-line applications who prioritize binary size efficiency and need Fuchsia compatibility or prefer a derive-based API over traditional parsing approaches.
Developers choose Argh for its exceptionally small code footprint, derive-based ergonomics that reduce boilerplate, and guaranteed compliance with Fuchsia's command-line tool standards, making it ideal for embedded or resource-constrained environments.
Rust derive-based argument parsing optimized for code size
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Argh is explicitly designed to optimize code size, producing smaller binaries than many alternatives, which is ideal for embedded or resource-constrained environments.
Using Rust's derive macros, Argh reduces boilerplate by allowing argument structures to be defined declaratively with attributes like #[argh(switch)] or #[argh(option)].
Conforms to the Fuchsia command-line tools specification, ensuring consistent behavior and compatibility for Fuchsia development without extra configuration.
Allows custom deserialization via the FromArgValue trait or from_str_fn attribute, enabling handling of complex value types with user-defined logic.
Due to its focus on minimalism and Fuchsia spec, Argh lacks features like automatic shell completions, advanced validation, or colored output common in parsers like clap.
Debugging derive macro expansions requires using cargo-expand with nightly Rust, adding setup overhead and complexity for troubleshooting issues.
The project is not an officially supported Google product, which may result in slower updates, limited maintenance, or less community-driven support compared to alternatives.