Improve usage when base command has no arguments
This commit is contained in:
parent
ba4fc26ea7
commit
cfa831c463
1 changed files with 2 additions and 0 deletions
|
@ -189,6 +189,8 @@ class CommandHandler:
|
|||
@property
|
||||
def __mb_usage_without_subcommands__(self) -> str:
|
||||
if not self.__mb_arg_fallthrough__:
|
||||
if not self.__mb_arguments__:
|
||||
return f"**Usage:** {self.__mb_prefix__} [subcommand] [...]"
|
||||
return (f"**Usage:** {self.__mb_prefix__} {self.__mb_usage_args__}"
|
||||
f" _OR_ {self.__mb_prefix__} {self.__mb_usage_subcommand__}")
|
||||
return f"**Usage:** {self.__mb_prefix__} {self.__mb_usage_args__}"
|
||||
|
|
Loading…
Reference in a new issue