Last active
July 29, 2020 14:18
-
-
Save elmerehbi/9e125f0b526c2cc3015aa75d75c9c386 to your computer and use it in GitHub Desktop.
This file contains 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
# https://pre-commit.com | https://pre-commit.com/hooks.html | |
default_language_version: | |
python: python3.7 | |
repos: | |
- repo: https://github.com/pre-commit/pre-commit-hooks | |
rev: v2.5.0 | |
hooks: | |
- id: detect-private-key | |
- id: trailing-whitespace | |
types: [python] | |
- id: check-yaml | |
- id: check-added-large-files | |
- id: end-of-file-fixer | |
types: [python] | |
- id: trailing-whitespace | |
- id: check-json | |
- id: check-toml | |
- id: check-yaml | |
- id: check-merge-conflict | |
- id: mixed-line-ending | |
- id: check-docstring-first | |
- repo: https://github.com/ambv/black | |
rev: stable | |
hooks: | |
- id: black | |
args: ["-l 80", "--diff"] | |
stages: [commit, push] | |
- repo: https://github.com/humitos/mirrors-autoflake | |
rev: v1.1 | |
hooks: | |
- id: autoflake | |
args: ['--in-place', '--remove-all-unused-imports', '--remove-unused-variable'] | |
stages: [push] | |
- repo: local | |
hooks: | |
- id: pytest | |
name: pytest | |
stages: [push] | |
entry: .venv/bin/pytest | |
language: script | |
pass_filenames: false | |
types: [python] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment