Install local hooks in the ~/.pre-commit folder

This commit is contained in:
Thierry Deo 2017-02-14 23:47:02 +01:00
parent 377cffbd27
commit 9a8fb17070
15 changed files with 103 additions and 75 deletions

View file

@ -70,6 +70,7 @@ def validate_config_extra(config):
raise InvalidConfigError(
'"sha" property provided for local hooks'
)
repo['sha'] = 'local'
elif 'sha' not in repo:
raise InvalidConfigError(
'Missing "sha" field for repository {}'.format(repo['repo'])