Exemplo n.º 1
0
def _help(command):
    """
    :param command: the command name for which you want to see a help
    :type command: str
    :returns: process return code
    :rtype: int
    """

    if command is not None:
        _help_command(command)
    else:
        emitter.publish(default_command_documentation("dcos"))
        return 0
Exemplo n.º 2
0
def _help(command):
    """
    :param command: the command name for which you want to see a help
    :type command: str
    :returns: process return code
    :rtype: int
    """

    if command is not None:
        _help_command(command)
    else:
        emitter.publish(default_command_documentation("dcos"))
        return 0
Exemplo n.º 3
0
def _help_command(command):
    """
    :param command: the command name for which you want to see a help
    :type command: str
    :returns: process return code
    :rtype: int
    """

    if command in subcommand.default_subcommands():
        emitter.publish(default_command_documentation(command))
        return 0
    else:
        executable = subcommand.command_executables(command)
        return subprocess.call([executable, command, '--help'])
Exemplo n.º 4
0
def _help_command(command):
    """
    :param command: the command name for which you want to see a help
    :type command: str
    :returns: process return code
    :rtype: int
    """

    if command in subcommand.default_subcommands():
        emitter.publish(default_command_documentation(command))
        return 0
    else:
        executable = subcommand.command_executables(command)
        return subprocess.Subproc().call([executable, command, '--help'])