summaryrefslogtreecommitdiffstats
path: root/.pre-commit-config.yaml
diff options
context:
space:
mode:
Diffstat (limited to '.pre-commit-config.yaml')
-rw-r--r--.pre-commit-config.yaml58
1 files changed, 58 insertions, 0 deletions
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
new file mode 100644
index 0000000..9c9cf2f
--- /dev/null
+++ b/.pre-commit-config.yaml
@@ -0,0 +1,58 @@
+repos:
+- repo: https://github.com/Lucas-C/pre-commit-hooks
+ rev: 79b8e4f273301e412602c856ddbc0c066765c98c # frozen: v1.1.11
+ hooks:
+ - id: insert-license
+ files: '^src/.+\.py$|^tests/.+\.py$'
+ args: ['--license-filepath', 'LICENSE-HEADER']
+- repo: https://github.com/executablebooks/mdformat
+ rev: a5f167d00d7a1990e69ee02efacc15d6136ea1aa # frozen: 0.7.13
+ hooks:
+ - id: mdformat
+ additional_dependencies:
+ - mdformat-toc
+ - mdformat-gfm
+ - mdformat-black
+- repo: https://github.com/asottile/yesqa
+ rev: 35cf7dc24fa922927caded7a21b2a8cb04bf8e10 # frozen: v1.3.0
+ hooks:
+ - id: yesqa
+ additional_dependencies:
+ - flake8-bugbear
+ - flake8-builtins
+ - flake8-comprehensions
+- repo: https://github.com/PyCQA/isort
+ rev: c5e8fa75dda5f764d20f66a215d71c21cfa198e1 # frozen: 5.10.1
+ hooks:
+ - id: isort
+- repo: https://github.com/psf/black
+ rev: fc0be6eb1e2a96091e6f64009ee5e9081bf8b6c6 # frozen: 22.1.0
+ hooks:
+ - id: black
+- repo: https://github.com/myint/docformatter
+ rev: 67919ee01837761f2d954d7fbb08c12cdd38ec5a # frozen: v1.4
+ hooks:
+ - id: docformatter
+- repo: https://github.com/pre-commit/pre-commit-hooks
+ rev: 8fe62d14e0b4d7d845a7022c5c2c3ae41bdd3f26 # frozen: v4.1.0
+ hooks:
+ - id: check-yaml
+- repo: https://github.com/pre-commit/pygrep-hooks
+ rev: 6f51a66bba59954917140ec2eeeaa4d5e630e6ce # frozen: v1.9.0
+ hooks:
+ - id: python-use-type-annotations
+ - id: python-check-blanket-noqa
+ - id: python-check-blanket-type-ignore
+- repo: https://github.com/PyCQA/flake8
+ rev: cbeb4c9c4137cff1568659fcc48e8b85cddd0c8d # frozen: 4.0.1
+ hooks:
+ - id: flake8
+ additional_dependencies:
+ - flake8-bugbear
+ - flake8-builtins
+ - flake8-comprehensions
+- repo: https://github.com/pre-commit/mirrors-mypy
+ rev: f6f816c65d285f8a4a15e0e9965b3dd66ecddd79 # frozen: v0.931
+ hooks:
+ - id: mypy
+ args: ["--scripts-are-modules"]