def validate(config, hash, options)
      @options = options.dup
      @log = options[:logger]

      hash = convert_nils_to_empty_hashes(hash)
      ensure_hook_type_sections_exist(hash)
      check_hook_name_format(hash)
      check_hook_env(hash)
      check_for_missing_enabled_option(hash) unless @options[:default]
      check_for_too_many_processors(config, hash)
      check_for_verify_plugin_signatures_option(hash)

      hash
    end
def validate(config, hash, options)
      @options = options.dup
      @log = options[:logger]

      hash = convert_nils_to_empty_hashes(hash)
      ensure_hook_type_sections_exist(hash)
      check_hook_name_format(hash)
      check_hook_env(hash)
      check_for_missing_enabled_option(hash) unless @options[:default]
      check_for_too_many_processors(config, hash)
      check_for_verify_plugin_signatures_option(hash)

      hash
    end
Validates hash for any invalid options, normalizing where possible.

 @param config [Overcommit::Configuration]
 @param hash [Hash] hash representation of YAML config
 @param options[Hash]
 @option default [Boolean] whether hash represents the default built-in config
 @option logger [Overcommit::Logger] logger to output warnings to
 @return [Hash] validated hash (potentially modified)