diff --git a/.gitignore b/.gitignore index 1505b271..5e7efc06 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,7 @@ __pycache__/ .*.sw? .sw? .vscode +.vstags \#*\# DEADJOE diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 00000000..2d520baa --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,38 @@ +--- +repos: + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v3.2.0 + hooks: + - id: trailing-whitespace + - id: end-of-file-fixer + - id: check-yaml + - id: check-added-large-files + - repo: https://github.com/jumanjihouse/pre-commit-hook-yamlfmt + rev: 0.0.11 # or specific tag + hooks: + - id: yamlfmt + args: [--mapping, '2', --sequence, '4', --offset, '2', --width, '150'] + exclude: | + (?x)^(.yamllint)$ + - repo: https://github.com/adrienverge/yamllint.git + rev: v1.26.3 + hooks: + - id: yamllint + args: [--format, parsable, --strict] + - repo: https://github.com/asottile/reorder_python_imports + rev: v2.6.0 + hooks: + - id: reorder-python-imports + args: [--py37-plus] + - repo: https://github.com/psf/black + rev: 21.8b0 + hooks: + - id: black + - repo: https://gitlab.com/PyCQA/flake8 + rev: 3.9.2 + hooks: + - id: flake8 + - repo: https://github.com/jumanjihouse/pre-commit-hooks + rev: 2.1.5 + hooks: + - id: shellcheck diff --git a/.yamllint b/.yamllint new file mode 100644 index 00000000..2618a8f1 --- /dev/null +++ b/.yamllint @@ -0,0 +1,9 @@ +--- +extends: default +rules: + line-length: + max: 150 + allow-non-breakable-words: true + allow-non-breakable-inline-mappings: false + truthy: + allowed-values: ['yes', 'no', 'true', 'false']