Enable map configurations (config v2).

This commit is contained in:
Anthony Sottile 2017-09-05 14:04:08 -07:00
parent ef8347cf2d
commit 3e76cdaf25
11 changed files with 70 additions and 52 deletions

View file

@ -109,7 +109,7 @@ def autoupdate(runner, tags_only):
input_configs = load_config(runner.config_file_path)
for repo_config in input_configs:
for repo_config in input_configs['repos']:
if is_local_repo(repo_config):
output_configs.append(repo_config)
continue

View file

@ -10,8 +10,9 @@ from __future__ import unicode_literals
SAMPLE_CONFIG = '''\
# See http://pre-commit.com for more information
# See http://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
sha: v0.9.1
sha: v0.9.2
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer