Last active
September 6, 2018 18:56
-
-
Save efi-mk/80b65fc6985ed72c09356d6cca43374d to your computer and use it in GitHub Desktop.
pre-commit config file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fail_fast: true | |
repos: | |
- repo: https://github.com/ambv/black | |
rev: 18.6b4 | |
hooks: | |
- id: black | |
language_version: python3.6 | |
- repo: https://github.com/pre-commit/mirrors-mypy | |
rev: v0.610-1 | |
hooks: | |
- id: mypy | |
- repo: https://github.com/pre-commit/pre-commit-hooks | |
rev: master | |
hooks: | |
- id: flake8 | |
args: ["--ignore","E501, W503, E203", "--exclude=00*,manage.py,settings.py"] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -e | |
default_command=( mypy flake8 ) | |
for command in ${@:-"${default_command[@]}"} | |
do | |
pre-commit run ${command} --all-files | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
As used in my medium post https://medium.com/@fooshm/development-flow-in-serverless-environment-from-the-trenches-d42021b7aef0