|
| 1 | +ci: |
| 2 | + autoupdate_schedule: quarterly |
| 3 | + |
| 4 | +default_stages: [commit] |
| 5 | + |
| 6 | +default_install_hook_types: [pre-commit, commit-msg] |
| 7 | + |
| 8 | +# ignore generated doc and dependency lock files |
| 9 | +exclude: ^(docs/.+|.*lock.*)$ |
| 10 | + |
1 | 11 | repos:
|
2 |
| - - repo: https://github.com/ambv/black |
| 12 | + - repo: https://github.com/PyCQA/isort |
| 13 | + rev: 5.10.1 |
| 14 | + hooks: |
| 15 | + - id: isort |
| 16 | + |
| 17 | + - repo: https://github.com/psf/black |
3 | 18 | rev: 22.6.0
|
4 | 19 | hooks:
|
5 |
| - - id: black |
| 20 | + - id: black-jupyter |
| 21 | + |
| 22 | + - repo: https://github.com/PyCQA/flake8 |
| 23 | + rev: 4.0.1 |
| 24 | + hooks: |
| 25 | + - id: flake8 |
| 26 | + |
| 27 | + - repo: https://github.com/asottile/pyupgrade |
| 28 | + rev: v2.34.0 |
| 29 | + hooks: |
| 30 | + - id: pyupgrade |
| 31 | + args: [--py38-plus] |
| 32 | + |
| 33 | + - repo: https://github.com/pre-commit/mirrors-mypy |
| 34 | + rev: v0.961 |
| 35 | + hooks: |
| 36 | + - id: mypy |
| 37 | + |
| 38 | + - repo: https://github.com/pre-commit/pre-commit-hooks |
| 39 | + rev: v4.3.0 |
| 40 | + hooks: |
| 41 | + - id: check-case-conflict |
| 42 | + - id: check-symlinks |
| 43 | + - id: check-yaml |
| 44 | + - id: destroyed-symlinks |
| 45 | + - id: end-of-file-fixer |
| 46 | + exclude: ^assets/.+\.(svg|html)$ |
| 47 | + - id: mixed-line-ending |
| 48 | + - id: trailing-whitespace |
| 49 | + |
| 50 | + - repo: https://github.com/codespell-project/codespell |
| 51 | + rev: v2.1.0 |
| 52 | + hooks: |
| 53 | + - id: codespell |
| 54 | + stages: [commit, commit-msg] |
| 55 | + exclude_types: [csv, svg, html, yaml, jupyter] |
| 56 | + |
| 57 | + - repo: local |
| 58 | + hooks: |
| 59 | + - id: svg-assets |
| 60 | + name: SVG assets |
| 61 | + entry: Files under assets/* must end in .(svg|html) |
| 62 | + language: fail |
| 63 | + files: ^assets/.*(?<!\.svg)(?<!\.html)$ |
| 64 | + |
| 65 | + - repo: https://github.com/myint/autoflake |
| 66 | + rev: v1.4 |
| 67 | + hooks: |
| 68 | + - id: autoflake |
| 69 | + args: |
| 70 | + - --in-place |
| 71 | + - --remove-unused-variables |
| 72 | + - --remove-all-unused-imports |
| 73 | + - --expand-star-imports |
| 74 | + - --ignore-init-module-imports |
| 75 | + |
| 76 | + - repo: https://github.com/nbQA-dev/nbQA |
| 77 | + rev: 1.3.1 |
| 78 | + hooks: |
| 79 | + - id: nbqa-pyupgrade |
| 80 | + args: [--py38-plus] |
| 81 | + - id: nbqa-isort |
| 82 | + - id: nbqa-flake8 |
| 83 | + args: [--ignore=E402] |
0 commit comments