Asib27's picture
try 1
065fee7 verified
raw
history blame
5.88 kB
---
ci:
autoupdate_schedule: quarterly
skip:
- actionlint-docker
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: 'v4.5.0'
hooks:
- id: check-merge-conflict
- repo: https://github.com/asottile/yesqa
rev: v1.5.0
hooks:
- id: yesqa
additional_dependencies:
- wemake-python-styleguide
- repo: https://github.com/PyCQA/isort
rev: '5.12.0'
hooks:
- id: isort
- repo: https://github.com/psf/black
rev: '23.11.0'
hooks:
- id: black
language_version: python3 # Should be a command that runs python3.8+
- repo: https://github.com/python-jsonschema/check-jsonschema.git
rev: 0.27.3
hooks:
- id: check-github-workflows
files: ^\.github/workflows/[^/]+$
types:
- yaml
- id: check-jsonschema
alias: check-github-workflows-timeout
name: Check GitHub Workflows set timeout-minutes
args:
- --builtin-schema
- github-workflows-require-timeout
files: ^\.github/workflows/[^/]+$
types:
- yaml
- id: check-readthedocs
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: 'v4.5.0'
hooks:
- id: end-of-file-fixer
exclude: >-
^docs/[^/]*\.svg$
- id: requirements-txt-fixer
exclude: >-
^requirements/constraints[.]txt$
- id: trailing-whitespace
- id: file-contents-sorter
args: ['--ignore-case']
files: |
CONTRIBUTORS.txt|
docs/spelling_wordlist.txt|
.gitignore|
.gitattributes
- id: check-case-conflict
- id: check-json
- id: check-xml
- id: check-executables-have-shebangs
- id: check-toml
- id: check-yaml
- id: debug-statements
- id: check-added-large-files
- id: check-symlinks
- id: fix-byte-order-marker
- id: fix-encoding-pragma
args: ['--remove']
- id: detect-aws-credentials
args: ['--allow-missing-credentials']
- id: detect-private-key
exclude: ^examples/
- repo: https://github.com/asottile/pyupgrade
rev: 'v3.15.0'
hooks:
- id: pyupgrade
args: ['--py36-plus']
- repo: https://github.com/PyCQA/flake8
rev: '6.1.0'
hooks:
- id: flake8
exclude: "^docs/"
- repo: https://github.com/codespell-project/codespell.git
rev: v2.2.6
hooks:
- id: codespell
- repo: https://github.com/adrienverge/yamllint.git
rev: v1.33.0
hooks:
- id: yamllint
args:
- --strict
- repo: https://github.com/MarcoGorelli/cython-lint.git
rev: v0.15.0
hooks:
- id: cython-lint
- repo: https://github.com/Lucas-C/pre-commit-hooks-markup
rev: v1.0.1
hooks:
- id: rst-linter
files: >-
^[^/]+[.]rst$
exclude: >-
^CHANGES\.rst$
- repo: local
hooks:
- id: changelogs-rst
name: changelog filenames
language: fail
entry: >-
Changelog files must be named
####.(
bugfix
| feature
| deprecation
| breaking
| doc
| packaging
| contrib
| misc
)(.#)?(.rst)?
exclude: >-
(?x)
^
CHANGES/(
\.gitignore
|\d+\.(
bugfix
|feature
|deprecation
|breaking
|doc
|packaging
|contrib
|misc
)(\.\d+)?(\.rst)?
|README\.rst
|\.TEMPLATE\.rst
)
$
files: ^CHANGES/
- id: changelogs-user-role
name: Changelog files should use a non-broken :user:`name` role
language: pygrep
entry: :user:([^`]+`?|`[^`]+[\s,])
pass_filenames: true
types: [file, rst]
- repo: https://github.com/pre-commit/mirrors-mypy.git
rev: v1.7.1
hooks:
- id: mypy
alias: mypy-py312
name: MyPy, for Python 3.12
additional_dependencies:
- lxml # dep of `--txt-report`, `--cobertura-xml-report` & `--html-report`
- pytest
- tomli # requirement of packaging/pep517_backend/
- types-setuptools # requirement of packaging/pep517_backend/
args:
- --show-error-codes
- --install-types
- --non-interactive
- --python-version=3.12
- --txt-report=.tox/.tmp/.mypy/python-3.12
- --cobertura-xml-report=.tox/.tmp/.mypy/python-3.12
- --html-report=.tox/.tmp/.mypy/python-3.12
- packaging/
- tests/
- frozenlist/
pass_filenames: false
- id: mypy
alias: mypy-py310
name: MyPy, for Python 3.10
additional_dependencies:
- lxml # dep of `--txt-report`, `--cobertura-xml-report` & `--html-report`
- pytest
- tomli # requirement of packaging/pep517_backend/
- types-setuptools # requirement of packaging/pep517_backend/
args:
- --show-error-codes
- --install-types
- --non-interactive
- --python-version=3.10
- --txt-report=.tox/.tmp/.mypy/python-3.10
- --cobertura-xml-report=.tox/.tmp/.mypy/python-3.10
- --html-report=.tox/.tmp/.mypy/python-3.10
- packaging/
- tests/
- frozenlist/
pass_filenames: false
- id: mypy
alias: mypy-py38
name: MyPy, for Python 3.8
additional_dependencies:
- lxml # dep of `--txt-report`, `--cobertura-xml-report` & `--html-report`
- pytest
- tomli # requirement of packaging/pep517_backend/
- types-setuptools # requirement of packaging/pep517_backend/
args:
- --show-error-codes
- --install-types
- --non-interactive
- --python-version=3.8
- --txt-report=.tox/.tmp/.mypy/python-3.8
- --cobertura-xml-report=.tox/.tmp/.mypy/python-3.8
- --html-report=.tox/.tmp/.mypy/python-3.8
- packaging/
- tests/
- frozenlist/
pass_filenames: false
- repo: https://github.com/rhysd/actionlint
rev: v1.6.26
hooks:
- id: actionlint-docker
args:
- -ignore
- >- # https://github.com/rhysd/actionlint/issues/384
^type of expression at "float number value" must be number
but found type string$
- -ignore
- 'SC2155:'
- -ignore
- 'SC2157:'
- -ignore
- 'SC2086:'
- -ignore
- 'SC1004:'
...