From e2a42d30272f872f28dd17c7991becf8fc6e932b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E0=AE=AE=E0=AE=A9=E0=AF=8B=E0=AE=9C=E0=AF=8D=E0=AE=95?= =?UTF-8?q?=E0=AF=81=E0=AE=AE=E0=AE=BE=E0=AE=B0=E0=AF=8D=20=E0=AE=AA?= =?UTF-8?q?=E0=AE=B4=E0=AE=A9=E0=AE=BF=E0=AE=9A=E0=AF=8D=E0=AE=9A=E0=AE=BE?= =?UTF-8?q?=E0=AE=AE=E0=AE=BF?= Date: Sun, 3 Apr 2022 18:57:58 +0530 Subject: [PATCH] added pre-commit --- .pre-commit-config.yaml | 15 +++++++++++++++ requirements-dev.txt | 2 ++ 2 files changed, 17 insertions(+) create mode 100644 .pre-commit-config.yaml diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 000000000..93583de50 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,15 @@ +# See https://pre-commit.com for more information +# See https://pre-commit.com/hooks.html for more hooks +repos: +- repo: https://github.com/pycqa/flake8 + rev: '4.0.1' + hooks: + - id: flake8 + args: + - max-line-length = 100, + - max-complexity = 12 +- repo: https://github.com/pre-commit/mirrors-mypy + rev: 'v0.942' + hooks: + - id: mypy + args: [--ignore-missing-imports] diff --git a/requirements-dev.txt b/requirements-dev.txt index 063cfaa45..5266ad003 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -3,10 +3,12 @@ -r requirements-plot.txt -r requirements-hyperopt.txt + coveralls==3.3.1 flake8==4.0.1 flake8-tidy-imports==4.6.0 mypy==0.942 +pre-commit==2.18.1 pytest==7.1.1 pytest-asyncio==0.18.3 pytest-cov==3.0.0