Go to the first, previous, next, last section, table of contents.


Flags for Argp Options

The following flags may be or'd together in the flags field of a struct argp_option, and control various aspects of how that option is parsed or displayed in help messages:

OPTION_ARG_OPTIONAL
The argument associated with this option is optional.
OPTION_HIDDEN
This option isn't displayed in any help messages.
OPTION_ALIAS
This option is an alias for the closest previous non-alias option. This means that it will be displayed in the same help entry, and will inherit fields other than name and key from the aliased option.
OPTION_DOC
This option isn't actually an option (and so should be ignored by the actual option parser), but rather an arbitrary piece of documentation that should be displayed in much the same manner as the options (known as a documentation option). If this flag is set, then the option name field is displayed unmodified (e.g., no `--' prefix is added) at the left-margin (where a short option would normally be displayed), and the documentation string in the normal place. For purposes of sorting, any leading whitespace and punctuation is ignored, except that if the first non-whitespace character is not `-', this entry is displayed after all options (and OPTION_DOC entries with a leading `-') in the same group.
OPTION_NO_USAGE
This option shouldn't be included in `long' usage messages (but is still included in help messages). This is mainly intended for options that are completely documented in an argp's args_doc field (see section Specifying Argp Parsers), in which case including the option in the generic usage list would be redundant. For instance, if args_doc is "FOO BAR\n-x BLAH", and the `-x' option's purpose is to distinguish these two cases, `-x' should probably be marked OPTION_NO_USAGE.


Go to the first, previous, next, last section, table of contents.