mini_arcade.cli.argument_type¶
Argument Type Definitions for Mini Arcade CLI
Attributes¶
Classes¶
Represents an argument for a command. |
Functions¶
|
Coerce a type to a callable that converts a string to that type. |
Module Contents¶
- mini_arcade.cli.argument_type.JSON¶
- mini_arcade.cli.argument_type.DataType¶
- class mini_arcade.cli.argument_type.ArgumentType[source]¶
Represents an argument for a command.
- Variables:
(str) (help_text) – The name of the argument.
(DataType) (data_type) – The data type of the argument.
(str) – The help text for the argument.
(bool) (required) – Whether the argument is required.
(Optional[DataType]) (default) – The default value for the argument.
(Optional[List[str]]) (choices) – The choices for the argument.
str]]) (nargs (Optional[Union[int,) – The number of arguments.
(Optional[str]) (env) – The metavar for the argument.
(Optional[str]) – The environment variable associated with the argument.
- name: str¶
- help_text: str¶
- required: bool = False¶
- choices: List[str] | None = None¶
- nargs: int | str | None = None¶
- metavar: str | None = None¶
- env: str | None = None¶