dob.clickux package

Submodules

dob.clickux.add_fact_help_group module

Click Group wrapper tweaks usage for the dob add --help help.

class dob.clickux.add_fact_help_group.ClickAddFactHelpGroup(*args, **kwargs)[source]

Bases: dob.clickux.aliasable_bunchy_plugin.ClickAliasableBunchyPluginGroup

ADD_FACT_GROUP_HELP = 'add --help'
ADD_FACT_GROUP_NAME = 'add'
ADD_FACT_SKIP_ALIASED = ['on', 'until', 'next']
format_help_text(ctx, formatter)[source]

Writes the help text to the formatter if it exists.

help_usage_command_path_postfix(ctx)[source]

dob.clickux.aliasable_bunchy_plugin module

Click Group wrapper combines all our custom classes.

class dob.clickux.aliasable_bunchy_plugin.ClickAliasableBunchyPluginGroup(*args, **kwargs)[source]

Bases: dob.clickux.bunchy_group.ClickBunchyGroup, click_hotoffthehamster_alias.ClickAliasedGroup, dob.clickux.plugin_group.ClickPluginGroup, dob.clickux.better_format_usage.ClickBetterUsageGroup, dob.clickux.better_help_headers.ClickBetterHeadersGroup

command(*args, **kwargs)[source]

A shortcut decorator for declaring and attaching a command to the group. This takes the same arguments as command() but immediately registers the created command with this instance by calling into add_command().

dob.clickux.better_format_usage module

Click Group wrapper combines all our custom classes.

class dob.clickux.better_format_usage.ClickBetterUsageGroup(*args, **kwargs)[source]

Bases: click_hotoffthehamster.core.Group

USAGE_HINT_ALL_OPTS = '--GLOBAL...'
USAGE_HINT_CMD_ARGS = 'ARGS...'
USAGE_HINT_CMD_OPTS = '--OPTION...'
collect_usage_pieces(*args, **kwargs)[source]

Show ‘[OPTIONS]’ in usage unless command takes none.

format_help(ctx, formatter)[source]

Override Click.Command: shorter help for commandless root command action.

format_usage(ctx, formatter)[source]

Writes the usage line into the formatter.

This is a low-level method called by get_usage().

Overriden by dob to emphasize with _underline_ and bold.

help_usage_command_path_postfix(ctx)[source]

dob.clickux.better_help_headers module

Click Group wrapper combines all our custom classes.

class dob.clickux.better_help_headers.ClickBetterHeadersGroup(*args, **kwargs)[source]

Bases: click_hotoffthehamster.core.Group

help_header_commands
help_header_options

dob.clickux.bunchy_group module

Click Group wrapper adds plugin support.

class dob.clickux.bunchy_group.ClickBunchyGroup(*args, help_weight=10, **kwargs)[source]

Bases: click_hotoffthehamster.core.Group

add_command(cmd, name=None)[source]

Registers another Command with this group. If the name is not provided, the name of the command is used.

add_to_bunch(cmd, bunchy_name, sort_key=0)[source]
bunchies_regroup(cmd, bunchy_name)[source]
format_commands(ctx, formatter)[source]

Extra format methods for multi methods that adds all the commands after the options.

format_commands_fetch(ctx, bunchy_name)[source]
sortkeys_update(cmd, bunchy_name, sort_key)[source]

dob.clickux.bunchy_help module

Module to define command group decorators and section headers.

dob.clickux.bunchy_help.cmd_bunch_group_add_fact(cmd)[source]
dob.clickux.bunchy_help.cmd_bunch_group_dbms(cmd)[source]
dob.clickux.bunchy_help.cmd_bunch_group_edit(cmd)[source]
dob.clickux.bunchy_help.cmd_bunch_group_generate_report(cmd)[source]
dob.clickux.bunchy_help.cmd_bunch_group_get_meta(cmd)[source]
dob.clickux.bunchy_help.cmd_bunch_group_introducing(cmd)[source]
dob.clickux.bunchy_help.cmd_bunch_group_ongoing_fact(cmd)[source]
dob.clickux.bunchy_help.cmd_bunch_group_personalize(cmd)[source]
dob.clickux.bunchy_help.cmd_bunch_group_plugin(cmd)[source]

dob.clickux.cmd_options module

dob.clickux.cmd_options.cmd_options_edit_item(func)[source]
dob.clickux.cmd_options.cmd_options_fact_add(func)[source]
dob.clickux.cmd_options.cmd_options_fact_dryable(func)[source]
dob.clickux.cmd_options.cmd_options_fact_edit(func)[source]
dob.clickux.cmd_options.cmd_options_fact_import(func)[source]
dob.clickux.cmd_options.cmd_options_factoid(func)[source]
dob.clickux.cmd_options.cmd_options_factoid_verify_none(func)[source]
dob.clickux.cmd_options.cmd_options_factoid_verify_start(func)[source]
dob.clickux.cmd_options.cmd_options_factoid_verify_end(func)[source]
dob.clickux.cmd_options.cmd_options_factoid_verify_both(func)[source]
dob.clickux.cmd_options.cmd_options_rule_name(func)[source]
dob.clickux.cmd_options.cmd_options_styles_internal(func)[source]
dob.clickux.cmd_options.cmd_options_styles_named(func)[source]

dob.clickux.help_command module

dob.clickux.help_command.help_command_help(ctx, command=None)[source]

dob.clickux.help_detect module

dob.clickux.help_detect.show_help_finally(func)[source]

Click command callback decorator to show help if requested. This changes the behavior of option parsing: The old behavior of dob –help command would show the general help, i.e., it would show the same help as dob –help. By telling Click to cool it, we can show the help for the specified sub-command instead, i.e., dob –help command will now show the help for command.

dob.clickux.help_detect.show_help_if_no_command(func)[source]

dob.clickux.help_header module

dob.clickux.help_header.help_header_format(text)[source]

dob.clickux.help_string_add_fact module

Module to provide u18n friendly help text strings for our CLI commands.

dob.clickux.help_string_add_fact.ADD_FACT_COMMON(ctx)[source]

dob.clickux.help_strings module

Module to provide u18n friendly help text strings for our CLI commands.

dob.clickux.help_strings.ADD_FACT_AFTER(ctx)[source]
dob.clickux.help_strings.ADD_FACT_AT(ctx)[source]
dob.clickux.help_strings.ADD_FACT_FROM(ctx)[source]
dob.clickux.help_strings.ADD_FACT_REFERRAL()[source]
dob.clickux.help_strings.ADD_FACT_THEN(ctx)[source]
dob.clickux.help_strings.ADD_FACT_UNTIL(ctx)[source]
dob.clickux.help_strings.CONFIG_GROUP_HELP(ctx)[source]
dob.clickux.help_strings.DEMO_HELP(ctx)[source]
dob.clickux.help_strings.EXPORT_HELP(ctx)[source]
dob.clickux.help_strings.IGNORE_GROUP_HELP(ctx)[source]
dob.clickux.help_strings.INIT_HELP_OVERVIEW(ctx)[source]
dob.clickux.help_strings.NO_ACTIVE_FACT_HELP(ctx)[source]
dob.clickux.help_strings.REPORT_HELP(ctx)[source]
dob.clickux.help_strings.RULES_GROUP_HELP(ctx)[source]
dob.clickux.help_strings.RUN_HELP_COMPLETE()[source]
dob.clickux.help_strings.RUN_HELP_HEADER()[source]
dob.clickux.help_strings.RUN_HELP_OVERVIEW(ctx)[source]
dob.clickux.help_strings.RUN_HELP_QUICKIE()[source]
dob.clickux.help_strings.RUN_HELP_TLDR()[source]
dob.clickux.help_strings.RUN_HELP_TRYME()[source]
dob.clickux.help_strings.RUN_HELP_WHATIS()[source]
dob.clickux.help_strings.STYLES_GROUP_HELP(ctx)[source]
dob.clickux.help_strings.common_format()[source]

dob.clickux.induct_newbies module

dob.clickux.induct_newbies.induct_newbies(func)[source]
dob.clickux.induct_newbies.insist_germinated(func)[source]

dob.clickux.plugin_group module

Click Group wrapper adds plugin support.

dob.clickux.plugin_group.ensure_plugged_in(func)[source]
class dob.clickux.plugin_group.ClickPluginGroup(*args, **kwargs)[source]

Bases: click_hotoffthehamster.core.Group

ensure_plugged_in(controller)[source]
get_command(ctx, name)[source]

Given a context and a command name, this returns a Command object if it exists or returns None.

get_commands_from_plugins(ctx, name)[source]
list_commands(ctx)[source]

Return list of commands.

open_source_eval_and_poke_around(py_path, name)[source]
plugin_paths
probe_source_for_commands(eval_globals, name)[source]

dob.clickux.post_processor module

dob.clickux.post_processor.post_processor(func)[source]

dob.clickux.query_assist module

dob.clickux.query_assist.error_exit_no_results(item_type, more_msg=None)[source]

Module contents

Top-level package module for clickux modules.