# Path: googkit/lib/i18n.py



import difflib
from googkit.lib.i18n import _


class Help(object):
    """A class that prints a help message."""

    """A threshold of a similarity ratio for command candidates"""
    CANDIDATE_RATIO_THRSHOLD = 0.5

    def __init__(self, tree, argument):
        """Creates a help message builder with the command tree and the Argument instance.
        """
        self._tree = tree
        self._argument = argument
        self._correct_commands = tree.right_commands(argument.commands)
        self._available_commands = tree.available_commands(self._correct_commands)

    def _is_valid_commands(self):
        commands = self._argument.commands
        return (not commands) or (commands == self._correct_commands)

    def _print_usage(self):
        commands_mark = _('<commands>') if self._available_commands else ''

        if self._correct_commands:
            print(_('Usage: googkit {cmd} {cmds_mark}').format(
                cmd=' '.join(self._correct_commands),
                cmds_mark=commands_mark))
        else:

# Path: googkit/lib/i18n.py



# Path: googkit/lib/help.py
import difflib
from googkit.lib.i18n import _



class Help(object):
    """A class that prints a help message."""

    """A threshold of a similarity ratio for command candidates"""
    CANDIDATE_RATIO_THRSHOLD = 0.5

    def __init__(self, tree, argument):
        """Creates a help message builder with the command tree and the Argument instance.
        """
        self._tree = tree
        self._argument = argument
        self._correct_commands = tree.right_commands(argument.commands)
        self._available_commands = tree.available_commands(self._correct_commands)

    def _is_valid_commands(self):
        commands = self._argument.commands
        return (not commands) or (commands == self._correct_commands)

    def _print_usage(self):
        commands_mark = _('<commands>') if self._available_commands else ''

        if self._correct_commands:
            print(_('Usage: googkit {cmd} {cmds_mark}').format(
                cmd=' '.join(self._correct_commands),
                cmds_mark=commands_mark))
        else:

            print(_('Usage: googkit {cmds_mark}').format(