A minimalist, frustration-free, single-header C++ library for command-line argument parsing.
Argh! is a minimalist, single-header C++ library for parsing command-line arguments. It provides a simple, expressive API without the complexity and external dependencies of alternatives like Boost.Program_options, making it perfect for quick prototyping and straightforward CLI tools.
C++ developers building command-line tools who need a lightweight, easy-to-integrate argument parser without the overhead of larger libraries.
Developers choose Argh! for its zero-friction integration, lack of dependencies, and straightforward API that doesn't dominate the codebase, offering just enough functionality for most use cases without unnecessary features.
Argh! A minimalist argument handler.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Single header file with no external dependencies allows trivial inclusion in any C++ project, as emphasized by the README's focus on 'no build system complexity.'
Uses only [] and () operators for argument access, enabling concise code like cmdl['verbose'] for flags and cmdl('scale') >> value for parameters without verbose getters.
Supports configurable modes such as PREFER_PARAM_FOR_UNREG_OPTION and SINGLE_DASH_IS_MULTIFLAG, allowing customization of argument interpretation without additional boilerplate.
Leverages std::istream for typed conversions, giving users direct control over error handling and type parsing after the initial parsing phase.
The library explicitly states it does not perform syntax validation or enforce argument rules, requiring developers to implement all checks manually, which can lead to boilerplate code.
Unlike many alternatives, Argh! does not generate help messages or usage summaries, shifting the burden to the user for documentation and increasing maintenance overhead.
Missing support for common CLI features like subcommands, argument groups, or automatic type coercion, making it unsuitable for complex applications without significant user effort.