/ .pre-commit-config.yaml
.pre-commit-config.yaml
 1  # SPDX-FileCopyrightText: 2020 Diego Elio Pettenò
 2  #
 3  # SPDX-License-Identifier: Unlicense
 4  
 5  repos:
 6    - repo: https://github.com/python/black
 7      rev: 22.3.0
 8      hooks:
 9        - id: black
10    - repo: https://github.com/pre-commit/pre-commit-hooks
11      rev: v4.2.0
12      hooks:
13        - id: check-yaml
14        - id: end-of-file-fixer
15        - id: trailing-whitespace
16    - repo: https://github.com/pycqa/pylint
17      rev: v2.15.5
18      hooks:
19        - id: pylint
20          name: pylint (library code)
21          types: [python]
22          args:
23            - --disable=consider-using-f-string
24          exclude: "^(docs/|examples/|tests/|setup.py$)"
25        - id: pylint
26          name: pylint (example code)
27          description: Run pylint rules on "examples/*.py" files
28          types: [python]
29          files: "^examples/"
30          args:
31            - --disable=missing-docstring,invalid-name,consider-using-f-string,duplicate-code
32        - id: pylint
33          name: pylint (test code)
34          description: Run pylint rules on "tests/*.py" files
35          types: [python]
36          files: "^tests/"
37          args:
38            - --disable=missing-docstring,consider-using-f-string,duplicate-code