Introduction
argparse
is a flexible parser of command line arguments that allows easy creation of terminal applications with rich command line interface.
Features
argparse
provides a lot of features to support different use cases:
Positional arguments
Named arguments
Argument grouping
Subcommands
Built-in help screen
ANSI colors and styles
Shell completion
Support for different types, for example: scalars, enums, arrays, associative arrays, callbacks
Example of help screen with ANSI colors and styles:

Last modified: 22 February 2025