repos: ## GENERAL - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.3.0 hooks: - id: check-merge-conflict - id: check-yaml args: ['--unsafe'] - id: check-json - id: end-of-file-fixer - id: trailing-whitespace - id: no-commit-to-branch - id: pretty-format-json args: ['--autofix'] exclude: .metadata.json ## BASH - repo: https://github.com/koalaman/shellcheck-precommit rev: v0.8.0 hooks: - id: shellcheck ## PYTHON - repo: https://github.com/myint/autoflake rev: v1.4 hooks: - id: autoflake args: ['--in-place', '--remove-all-unused-imports', '--remove-unused-variable'] - repo: https://github.com/timothycrosley/isort rev: 5.10.1 hooks: - id: isort args: ["--profile", "black"] - repo: https://github.com/psf/black rev: 22.3.0 hooks: - id: black - repo: https://github.com/haizaar/check-pipfile-lock rev: v0.0.5 hooks: - id: check-pipfile-lock - repo: local hooks: - id: pytest-check name: pytest-check entry: bash -c 'pytest' language: system - id: bandit name: bandit description: 'Bandit is a tool for finding common security issues in Python code' entry: bash -c 'bandit -q -lll -x '*_test.py,./contrib/' -r .' language: system - id: safety name: bandit description: 'Safety is a tool that checks your installed dependencies for known security vulnerabilities' entry: bash -c 'safety check' language: system - id: vulture name: vulture description: 'Vulture finds unused code in Python programs.' entry: bash -c 'vulture --exclude "contrib" --min-confidence 100 .' language: system