docs: def parse_plugin_args(command_args, config_args):
      """Parse command line arguments based on the plugin's parameters config.
  
      :param command_args: Command line arguments as provided by the user in `key=value` format.
      :param config_args: Plugin parameters parsed from config.json.
  
      :returns: Validated dictionary of parameters that will be passed to plugin class
      """
      parsed_args = dict()
      for arg in command_args:
          kv = arg.split("=")
          if len(kv) != 2:
              raise click.UsageError("Invalid parameter '{}', must be in key=value format".format(arg))
          parsed_args[kv[0]] = config_utils.get_truetype(kv[1])
  
      for arg in config_args:
          value = arg[defs.VALUE]
          value_type = arg[defs.TYPE]
          if value in parsed_args:
              # will raise if invalid
              config_utils.validate_field_matches_type(value, parsed_args[value], value_type,
                                                       arg.get(defs.ITEMS), arg.get(defs.MIN), arg.get(defs.MAX))
          elif defs.DEFAULT in arg:  # Has a default field
              # return default values for unset parameters
              parsed_args[value] = arg[defs.DEFAULT]
          elif arg[defs.REQUIRED]:  # requires field is true
              """parameter was not supplied by user, but it's required and has no default value"""
              raise exceptions.RequiredFieldMissing(value)
      return parsed_args