Beispiel #1
0
def run(command, parser, command_args, unknown_args):
    '''
  Run the command
  :param command:
  :param parser:
  :param command_args:
  :param unknown_args:
  :return:
  '''
    status = 1
    if command == 'activate':
        status = activate.run(command, parser, command_args, unknown_args)

    elif command == 'deactivate':
        status = deactivate.run(command, parser, command_args, unknown_args)

    elif command == 'kill':
        status = kill.run(command, parser, command_args, unknown_args)

    elif command == 'restart':
        status = restart.run(command, parser, command_args, unknown_args)

    elif command == 'submit':
        status = submit.run(command, parser, command_args, unknown_args)

    elif command == 'help':
        status = cli_help.run(command, parser, command_args, unknown_args)

    elif command == 'version':
        status = version.run(command, parser, command_args, unknown_args)

    return status
Beispiel #2
0
def run(command, parser, command_args, unknown_args):
  '''
  Run the command
  :param command:
  :param parser:
  :param command_args:
  :param unknown_args:
  :return:
  '''
  status = True
  if command == 'activate':
    status = activate.run(command, parser, command_args, unknown_args)

  elif command == 'deactivate':
    status = deactivate.run(command, parser, command_args, unknown_args)

  elif command == 'kill':
    status = kill.run(command, parser, command_args, unknown_args)

  elif command == 'restart':
    status = restart.run(command, parser, command_args, unknown_args)

  elif command == 'submit':
    status = submit.run(command, parser, command_args, unknown_args)

  elif command == 'help':
    status = cli_help.run(command, parser, command_args, unknown_args)

  elif command == 'version':
    status = version.run(command, parser, command_args, unknown_args)

  return status
Beispiel #3
0
def run(command, parser, command_args, unknown_args):
  if command == 'activate':
    return activate.run(command, parser, command_args, unknown_args)

  elif command == 'deactivate':
    return deactivate.run(command, parser, command_args, unknown_args)

  elif command == 'kill':
    return kill.run(command, parser, command_args, unknown_args)

  elif command == 'restart':
    return restart.run(command, parser, command_args, unknown_args)
  
  elif command == 'submit':
    return submit.run(command, parser, command_args, unknown_args)

  elif command == 'help':
    return help.run(command, parser, command_args, unknown_args)

  elif command == 'version':
    return version.run(command, parser, command_args, unknown_args)

  return 1
Beispiel #4
0
def run(command, parser, command_args, unknown_args):
  if command == 'activate':
    return activate.run(command, parser, command_args, unknown_args)

  elif command == 'deactivate':
    return deactivate.run(command, parser, command_args, unknown_args)

  elif command == 'kill':
    return kill.run(command, parser, command_args, unknown_args)

  elif command == 'restart':
    return restart.run(command, parser, command_args, unknown_args)
  
  elif command == 'submit':
    return submit.run(command, parser, command_args, unknown_args)

  elif command == 'help':
    return help.run(command, parser, command_args, unknown_args)

  elif command == 'version':
    return version.run(command, parser, command_args, unknown_args)

  return 1