feat: add basic functionality

This commit is contained in:
cătălin 2022-08-10 18:34:41 +02:00
commit 376b9d6877
Signed by: catalin
GPG key ID: 0178DF42F43E5FD2
11 changed files with 1168 additions and 0 deletions

69
.pre-commit-config.yaml Normal file
View file

@ -0,0 +1,69 @@
default_language_version:
python: python3.10
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
hooks:
- id: trailing-whitespace
args: [ --markdown-linebreak-ext=md ]
- id: end-of-file-fixer
- id: check-ast
- id: check-added-large-files
- id: check-byte-order-marker
- id: check-case-conflict
- id: check-docstring-first
- id: check-merge-conflict
- id: check-toml
- id: debug-statements
- id: mixed-line-ending
args: [ --fix=lf ]
- id: detect-private-key
- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.9.0
hooks:
- id: python-check-blanket-noqa
- id: python-use-type-annotations
- repo: https://github.com/psf/black
rev: 22.6.0
hooks:
- id: black
pass_filenames: false
args:
- "halig"
- repo: https://gitlab.com/pycqa/flake8
rev: 3.9.2
hooks:
- id: flake8
name: flake8 except __init__.py
exclude: /__init__\.py$
additional_dependencies: [ "flake8-bugbear==19.8.0" ]
- id: flake8
name: flake8 only __init__.py
args: [ "--extend-ignore=F401" ] # ignore unused imports in __init__.py
files: /__init__\.py$
additional_dependencies: [ "flake8-bugbear==19.8.0" ]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: 'v0.961'
hooks:
- id: mypy
files: ^halig/
additional_dependencies:
- types-deprecated==1.2.8
- types-pyyaml==6.0.11
- repo: https://github.com/asottile/pyupgrade
rev: v2.34.0
hooks:
- id: pyupgrade
- repo: https://github.com/PyCQA/bandit
rev: 1.7.4
hooks:
- id: bandit
files: ^darkroot/
args: [ -r ]