mirror of
https://codeberg.org/james-smith-za/git-tidy-python.git
synced 2026-01-15 19:29:25 +02:00
Initial commit.
This commit is contained in:
commit
6166b42b2e
6 changed files with 219 additions and 0 deletions
50
.pre-commit-config.yaml
Normal file
50
.pre-commit-config.yaml
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
default_language_version:
|
||||
python: python3.10
|
||||
|
||||
repos:
|
||||
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||
rev: v4.3.0
|
||||
hooks:
|
||||
- id: check-merge-conflict
|
||||
- id: check-shebang-scripts-are-executable
|
||||
- id: check-executables-have-shebangs
|
||||
- id: end-of-file-fixer
|
||||
- id: mixed-line-ending
|
||||
args: [--fix=lf]
|
||||
- id: no-commit-to-branch # without arguments, master/main will be protected.
|
||||
- id: trailing-whitespace
|
||||
- repo: https://github.com/psf/black
|
||||
rev: 22.10.0
|
||||
hooks:
|
||||
- id: black
|
||||
- repo: https://github.com/pycqa/isort
|
||||
rev: 5.10.1
|
||||
hooks:
|
||||
- id: isort
|
||||
name: isort
|
||||
- repo: https://github.com/PyCQA/flake8
|
||||
rev: 5.0.4
|
||||
hooks:
|
||||
- id: flake8
|
||||
additional_dependencies: [
|
||||
'flake8-bugbear==22.6.22',
|
||||
'pep8-naming==0.13.0'
|
||||
]
|
||||
- repo: https://github.com/pycqa/pydocstyle
|
||||
rev: 6.1.1
|
||||
hooks:
|
||||
- id: pydocstyle
|
||||
exclude: 'setup.py|scratch/' # Because complaining about docstrings here is annoying.
|
||||
- repo: https://github.com/pre-commit/mirrors-mypy
|
||||
rev: 'v0.991'
|
||||
hooks:
|
||||
- id: mypy
|
||||
# Passing filenames to mypy can do odd things. See
|
||||
# https://github.com/pre-commit/mirrors-mypy/issues/33.
|
||||
# mypy.ini determines the set of files that will actually be checked.
|
||||
pass_filenames: false
|
||||
# The pre-commit hook passes some options, but we set options in mypy.ini.
|
||||
args: []
|
||||
# The pre-commit hook only has python, not pyi.
|
||||
types: []
|
||||
types_or: [python, pyi]
|
||||
Loading…
Add table
Add a link
Reference in a new issue