From a0722abe80c416e0c174f3ff861566834402d43b Mon Sep 17 00:00:00 2001 From: Scott Gasch Date: Thu, 2 Jun 2022 08:23:18 -0700 Subject: Initial stab at a smarter doc/unit/integration/coverage test runner. --- config.py | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'config.py') diff --git a/config.py b/config.py index 7bf812e..c7c686d 100644 --- a/config.py +++ b/config.py @@ -254,6 +254,19 @@ def _reorder_arg_action_groups_before_help(entry_module: Optional[str]): return reordered_action_groups +def print_usage() -> None: + """Prints the normal help usage message out.""" + ARGS.print_help() + + +def usage() -> str: + """ + Returns: + program usage help text as a string. + """ + return ARGS.format_usage() + + def _augment_sys_argv_from_environment_variables(): """Internal. Look at the system environment for variables that match arg names. This is done via some munging such that: @@ -269,7 +282,7 @@ def _augment_sys_argv_from_environment_variables(): """ - usage_message = ARGS.format_usage() + usage_message = usage() optional = False var = '' for x in usage_message.split(): -- cgit v1.3